GoogleCloudPlatform / gcsfuse

A user-space file system for interacting with Google Cloud Storage
https://cloud.google.com/storage/docs/gcs-fuse
Apache License 2.0
2.05k stars 426 forks source link

Google Cloud FUSE with Cloud Run [Errno 5] Input/output error: '/database' but already granted Storage Object Admin access #576

Closed juliantcchu closed 2 years ago

juliantcchu commented 2 years ago

I am using GCP's Cloud FUSE together with Cloud Run, as outlined in this tutorial by google (https://cloud.google.com/run/docs/tutorials/network-filesystems-fuse#cloudrun_fs_code-python). However, after I deployed the app, the app is not able to access that folder but instead got this error in the log [Errno 5] Input/output error: '/database' , where 'database' is the folder name From what I read online, this is usually due to not having sufficient permission. However, I checked the dashboard at Cloud FUSE and I have already granted Storage Object Admin access to the service account of the app.

The app is written in python 3.9. I am not able to performos.listdir('/database'), and os.path.isdir('/database') returns false. However, when I used os.listdir('/'), 'database' is one of the items on the list.

lezh commented 2 years ago

usually due to not having sufficient permission

Recent changes have correct these errors to "permission denied" instead of "input/output error". The "input/output error" is somewhat an "unknown" error in this case. Can you add "--debug_gcs" flag to the command that mounts gcsfuse to get some internal logs?

Once you have the gcs logs, you can check the requests right before the failure. That might tell you the real issue.

avidullu commented 2 years ago

As mentioned, please provide us some logs so we can comprehend the issue better.

avidullu commented 2 years ago

Closing out due to inactivity.