nix-community / nix-on-droid

Nix-enabled environment for your Android device. [maintainers=@t184256,@Gerschtli]
https://nix-on-droid.unboiled.info
MIT License
1.33k stars 74 forks source link

Store path file POSIX_V6_LP64_OFF64 Operation not permitted #194

Open 573 opened 2 years ago

573 commented 2 years ago

On different occasions got this exact file permission error when running garbage control commands:

10947 store paths deleted, 17178.82 MiB freed error: getting status of '/nix/store/sf5plsnxln8kv97l6n3vjq222v5qmy0k-glibc-2.34-210/libexec/getconf/POSIX_V6_LP64_OFF64': Operation not permitted

Gerschtli commented 2 years ago

Can you run ls -l on that file/directory?

573 commented 2 years ago

lrwxrwxrwx 1 nix-on-droid nix-on-droid 57 Aug 4 17:07 /nix/store/sf5plsnxln8kv97l6n3vjq222v5qmy0k-glibc-2.34-210/libexec/getconf/POSIX_V6_LP64_OFF64 -> /data/data/com.termux.nix/files/usr/.l2s/.l2s.getconf0001

Gerschtli commented 2 years ago

@t184256 do you know what this .l2s directory is? Looks strange to see a link from nix store to the outside. Maybe some incomplete bootstrapping of the app?

t184256 commented 2 years ago

That comes from proot's hardlink emulation (link2symlink option).

573 commented 2 years ago

@t184256 is there smth we should do about that ?

t184256 commented 2 years ago

Not sure.

Are fake hardlinks a result of /nix/store optimization?

Gerschtli commented 2 years ago

At least executing nix store optimise results in a similar error that it can't link because of permission denied. Maybe store optimise is currently just not working at all within proot