-
Notifications
You must be signed in to change notification settings - Fork 61
I have problem with dbt_hook to write into logs permission denied #33
Comments
Hi @ravog, This operator just logs as all other Airflow tasks, and doesn't try to write any other logs in any other location. Are your other Airflow tasks writing logs ok? Is it just this task/operator? Regards, |
The author might be referring to the error message I've just run into when using
|
I had to update the value of |
Hi , I was able to fix the permission denied error as @Falydoor has suggested but i am getting readonly file system on writing partial parsing:
Please let me know if anyone has an answer for this. |
Hey @prakash260, Try updating the Maybe there is a better way rather than using a temp folder like disabling dbt logs/target generation. |
thanks @Falydoor i too disagree on temp usage too much but i will see whether it will work or not. |
ok i have tried replacing the location to /usr/local/airflow/dags/{dbt-directory} and everything is working now |
@prakash260 could you please elaborate more on {dbt_directory} ? but no success. Does MWAA has write access to /usr/local/airflow/dags/ ? |
hey @maker100, That particular location gets picked from S3 as part of MWAA hence i was forced stored the details in there. To be more precise your DBT project files need to be present in S3 location for this thing to work. |
so, what is the right approach? |
Hi @Gatsby-Lee , because of several issues with the direct use of dbt installed on MWAA like:
I decided to use separate environment and use dbt on AWS Batch service using ECR image. I recommend to use MWAA only as a scheduler and not to install dbt directly there. |
Hey @Gatsby-Lee, I agree with @maker100, you should avoid running heavy process like DBT directly on MWAA. My Airflow DAG triggers an ECS task that runs on Fargate to run my DBT code so I don't have to worry about resource allocation. |
@maker100 @Falydoor I have a following question. Thank you |
1: I used this operator to trigger my ECS task https://airflow.apache.org/docs/apache-airflow-providers-amazon/stable/operators/ecs.html |
@Falydoor |
Hello there @Falydoor , I have been running all the same steps along this conversation thread; and most of the errors mentioned in this thread have been happening to me. |
Hello @joaquimsage, Yes correct! The ECS Airflow operator can be used to run your task definition on your ECS cluster (use Fargate so you don't have to manage EC2s). One "small" drawback is that the task usually takes 1 minute to start so it delays a bit your DBT run. About MWAA, I don't think AWS will do any updates to fix the permission/read-only issues 😬. |
Hi all, if you want to run dbt directly on airflow: Please make these changes to the dbt_project.yml as only tmp directory has read-write permission in MWAA. packages-install-path: "/usr/local/airflow/tmp/dbt_packages"
|
No description provided.
The text was updated successfully, but these errors were encountered: