0

So a few drives are mounted to user home via fstab at boot.

UUID=XXXX-XXXX  /home/user/10TB exfat   defaults,uid=1000,umask=000 0 0

Then I ran this command for samba to access home directory:

sudo setsebool -P samba_enable_home_dirs=on

Which now with this smb conf section:

[home]
        comment = me-files
        path = /home/user
        writeable = yes
        browseable = yes
        public = yes
        create mask = 0644
        directory mask = 0755
        write list = user

I can connect to my PC and access everything except the contents of the drive mounted in ~/10TB.

I have heard of disabling SELINUX, but I don't think that is ideal. I have used samba with arch before and it worked just fine. What am I missing here?

System is Fedora 35 KDE spin.

EDIT: I added user_allow_other and allow_otherin fuse.conf

7
  • Can you add context=“user_home_t” to the mountpoint? The “exfat” filesystem doesn’t support SELinux.
    – jsbillings
    Mar 5 at 12:39
  • I did add that value to my fstab, machine will not boot upon start up. Had to go into emergency mode and edit it out in fstab. @jsbillings
    – Asmodean
    Mar 5 at 15:42
  • Just so you don’t have to mess with it again in emergency, also add “noauto,x-systemd.automount”. This will prevent it from interfering with boot and make it mount on demand
    – jsbillings
    Mar 5 at 16:49
  • But then there is no point to include the parameter if I am just going to bypas it with those options right? By the way it is an exfat fuse drive, I edited to add some options in the fuse conf. Maybe you will know something about that too. @jsbillings
    – Asmodean
    Mar 5 at 16:51
  • Adding the systemd option turns it into an automount, which means instead of mounting during boot, it is mounted on first access, so it won’t prevent the OS from booting.
    – jsbillings
    Mar 5 at 17:07

1 Answer 1

0

So I had to do this:

setsebool -P samba_share_fusefs 1

https://linux.die.net/man/8/samba_selinux

Then did this just for good measure:

setsebool -P samba_export_all_rw 1

Then you should be good for your fuse mounted drives!

No need to add samba type since that does not work with fuse mounts. Npr is there need to edit the fstab for context.

You can check with this:

ls -dZ /share

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.