danilop / yas3fs

YAS3FS (Yet Another S3-backed File System) is a Filesystem in Userspace (FUSE) interface to Amazon S3. It was inspired by s3fs but rewritten from scratch to implement a distributed cache synchronized by Amazon SNS notifications. A web console is provided to easily monitor the nodes of a cluster.
http://danilop.github.io/yas3fs
MIT License
640 stars 98 forks source link

MacOSX 10.15.4 makes yas3fs read-only? #186

Open PenelopeFudd opened 4 years ago

PenelopeFudd commented 4 years ago

Hi;

Found out that using OSXFuse to mount things in the /tmp directory doesn't work:

While testing that, I found that if I mounted things in my home directory, they would work again.

...except for yas3fs:

$ cd $HOME

$ aws s3 mb s3://my-test-bucket
$ date | aws s3 cp - s3://my-test-bucket/testfile.txt
$ aws s3 cp s3://my-test-bucket/testfile.txt -
Sat 18 Apr 2020 21:29:03 PDT

$ yas3fs --debug -l logfile.txt s3://my-test-bucket my-test-bucket

$ ls -l my-test-bucket
total 4096
drwxr-xr-x@   1 root          wheel  4096 Apr 19  2020 ./
drwxr-xr-x+ 122 PenelopeFudd  staff  3904 Apr 18 21:58 ../
-rwxr-xr-x    1 PenelopeFudd  staff    29 Apr 19  2020 testfile.txt*

$ cd my-test-bucket
$ cat testfile.txt
Sat 18 Apr 2020 21:29:03 PDT
$ date > some-date.txt
-bash: some-date.txt: Permission denied
$ rm testfile.txt
rm: testfile.txt: Permission denied
$ cd ..
$ umount my-test-bucket

$ grep -m1 some-date.txt logfile.txt
Dummy-4 2020-04-18T22:33:28.081 DEBUG getattr -> '/some-date.txt' 'None'

$ grep ^Dummy-4 logfile.txt
Dummy-4 2020-04-18T22:33:26.087 DEBUG statfs '/'
Dummy-4 2020-04-18T22:33:26.220 DEBUG statfs '/'
Dummy-4 2020-04-18T22:33:26.967 DEBUG statfs '/'
Dummy-4 2020-04-18T22:33:27.206 DEBUG statfs '/'
Dummy-4 2020-04-18T22:33:28.081 DEBUG getattr -> '/some-date.txt' 'None'
Dummy-4 2020-04-18T22:33:28.082 DEBUG get_metadata -> '/some-date.txt' 'attr' 'None'
Dummy-4 2020-04-18T22:33:28.082 DEBUG get_key /some-date.txt
Dummy-4 2020-04-18T22:33:28.083 DEBUG get_key not on S3 '/some-date.txt'
Dummy-4 2020-04-18T22:33:28.083 DEBUG get_key no '/some-date.txt'
Dummy-4 2020-04-18T22:33:28.084 DEBUG folder_has_contents '/some-date.txt' 1
Dummy-4 2020-04-18T22:33:28.084 DEBUG has_element '<boto.s3.bucketlistresultset.BucketListResultSet object at 0x1475c7bd0>' 1
Dummy-4 2020-04-18T22:33:28.195 DEBUG has_element '<boto.s3.bucketlistresultset.BucketListResultSet object at 0x1475c7bd0>' KO
Dummy-4 2020-04-18T22:33:28.196 DEBUG get_metadata '/some-date.txt' 'attr' no S3 return None
Dummy-4 2020-04-18T22:33:28.197 DEBUG getattr <- '/some-date.txt' 'None' ENOENT

It looks like MacOSX has changed something (probably in the name of security), and broke yas3fs.

Sigh.

Hope this report helps!