New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Operation not permitted" error when chmod on log folder #29112
Comments
Thanks for opening your first issue here! Be sure to follow the issue template! |
I guess it is regression of #28477 |
Should be easy fix but it is likely another candidate to speed up 2.5.2 cc: @pierrejeambrun @ephraimbuddy |
@pingzh do you want to take a look at it? |
I have the same issue with image based on |
You can upgrade MySQL provider and build your image @nsphung if you do not want to wait for the 2.5.2 to release. |
I don't need the provider so for now. I've just uninstalled it in my airflow instances. It's just the Dependabot alerts that is annoying me for this when it sees Airflow < 2.5.1 at the moment. |
@denskh Did wind up with a workaround for this? I'm having the same issue, would like to use the shared logs, but I can disable them until we can upgrade to the 2.5.2 version when that's released |
Nope, still on 2.5.0 which doesn't have this issue, hope it gets fixed soon. |
I have been trying to replicate this issue this morning, here's what I did:
So I think that it must be an issue of the access / fsGroup on your volume, and might be related to the CSI? If anyone has any other suggestions, I am happy to work on a fix, but would like to replicate the issue first. Update: I wasn't using impersonation 🤦 once I set |
Apparently there are cases where changing the permission is impossible. We should ignore the error rather than fail the log file creation in such cases (as it is anyhow only needed to handle a very specific subdag issue). |
In some circumstances, changing the permission of a parent folder for the log might not be possible - for example when it was created by another user (with impersonation) or when the filesystem does not allow for permission change. Fixes: apache#29112
In some circumstances, changing the permission of a parent folder for the log might not be possible - for example when it was created by another user (with impersonation) or when the filesystem does not allow for permission change. Fixes: #29112
@potiuk I am still seeing many users report errors in airflow 2.5.3 as the fix in PR #30123 was not back-ported. The error is always associated with this line Alternatively, can we revert #28477 which is the cause of this problem? |
Official Helm Chart version
1.7.0 (latest released)
Apache Airflow version
2.5.1
Kubernetes Version
1.24.6
Helm Chart configuration
executor: "KubernetesExecutor" # however same issue happens with LocalExecutor
logs:
persistence:
enabled: true
size: 50Gi
storageClassName: azurefile-csi
Docker Image customizations
Using airflow-2.5.1-python3.10 as a base image.
Copy custom shared libraries into folder under /opt/airflow/company
Copy DAGs /opt/airflow/dags
What happened
What you think should happen instead
Seem like airflow attempts to set change log folder permissions and not permissioned to do it.
Getting same error when executing command manually (confirmed folder path exists): chmod 511 '/opt/airflow/logs/dag_id=/run_id=manual__2023-01-22T02:59:43.752407+00:00/task_id='
chmod: changing permissions of '/opt/airflow/logs/dag_id=/run_id=scheduled__2023-01-23T15:30:00+00:00/task_id=': Operation not permitted
How to reproduce
My understanding is that this error happens before any custom code is executed.
Anything else
Error happens every time, unable to start any DAG while using airflow 2.5.1. Exactly same configuration works with 2.5.0 and 2.4.3.
Same image and configuration works fine while running locally using docker-composer.
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: