I've been trying to use sshfs to connect a notebook running in Colab Enterprise to my local machine (running an ssh server) and mount a local directory into the remote Runtime. But I get the error fuse: mount failed: Permission denied even before the SSH connection is even attempted.
I'm running as root, connecting to the SSH server as another user (i.e. sshfs someuser@ip ), and my mount point (in the notebook runtime) exists and is owned by root. What could be happening here ?
2 Answers 2
I tried GCSfuse and worked fine, please try SSHfs which should work as well.
Example:
!export GCSFUSE_REPO=gcsfuse-`lsb_release -c -s`
# This returns gcsfuse-jammy. Replace manually
!echo "deb https://packages.cloud.google.com/apt gcsfuse-jammy main" | sudo tee /etc/apt/sources.list.d/gcsfuse.list
!curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
!sudo apt-get update
!sudo apt-get install gcsfuse
# Create a local directory. Here you will mount GCSfuse. (GCS bucket is: $BUCKET_NAME)
!mkdir gcs-bucket-mount
!gcsfuse --implicit-dirs $BUCKET_NAME gcs-bucket-mount
{"time":"07/12/2023 12:05:39.597680","severity":"INFO","msg":"Start gcsfuse/1.2.1 (Go version go1.21.3) for app \"\" using mount point: /content/gcs-bucket-mount\n"}
Comments
There was an internal feature request to allow Mount of Fuse systems into Colab Runtime, I submitted the fix and will rollout to production next week. (By Friday 1st should be in all regions)
Comments
Explore related questions
See similar questions with these tags.
fuse: mount failed: Permission deniedsame issue with GCSfuse:{"time":"18/11/2023 11:18:06.744235","severity":"INFO","msg":"Start gcsfuse/1.2.1 (Go version go1.21.3) for app \"\" using mount point: /content/gcs-bucket-mount\n"} daemonize.Run: readFromProcess: sub-process: mountWithArgs: mountWithStorageHandle: Mount: mount: permission deniedI think it has to do with the way we start the Colab container in Colab runtime. Will test further and get back to you.