I had another post and got some great advice, thank you to everyone who took the time, but I’ve learned so much over the last 2 days that I wanted to be more direct and clear since I’m still stuck. Mostly I just want to know if I’m on the right track, and if anyone had any advice. I don’t just want to get things working, I’d like to understand why. After a lot of digging, I feel like I might be close to getting it.

I have 4 secondary internal drives, and 2 external. They all mount as root 777, I can access things but I also use Emby server. Emby can see everything, but can’t write. So that said, here’s how it started to where I’m at, does this sound like I’m heading in the right direction?

  1. CachyOS mounts to /run/media/user (the user folder has a lock on it) and I had to password/mount all drives at every reboot. I read something about /run being a temp folder so I looked into auto-mounting after some advice.

  2. I learned how to set up auto mount with gnome disk utility, which writes to fstab. Great! fstab hurts my brain after filling it up the last 2 days. I set them to mount to /mnt/drivename, and they auto mount at boot. So far so good!

  3. I can now access my drives, so I began setting up my server. No problem this time! Emby sees the directories and scans them. Finally! However even though I can rw on the drives, Emby sees them as read only. Bummer.

  4. Checking permissions, the drives are all mounted as root, with 777 permissions (which I suppose is why I can write to them but I don’t get why Emby can’t, maybe because it’s a different user?).

  5. Time to get permissions! sudo chown does nothing. Still owned by root. Right click/permissions shows root:root, owner, group, other all can view and modify content, and it’s all greyed out. 'Cause it’s root, duh.

  6. More digging, the drives are NTFS! Apparently Arch mounts NTFS with root ownership, permanently. This makes sense! I think I found my problem! Maybe.

  7. Now I’m here, asking you wonderful nerds before I continue. I’m planning to change the mounts in gnome disk utility back to default (slider) and unmount and reboot. No idea if they’ll mount to /run or /mnt. Next, I have ntfs-3g installed and plan to run mount -t ntfs3 /dev/sdxY /mnt though I think I either need to create a drivename folder in /mnt or add mount -t ntfs3 /dev/sdxY /mnt/DRIVENAME the drive name to the end and it’ll create it maybe?

The other thing that’s bugging me is that gnome disk utility writes the mounts to fstab. I’m thinking if I do it this way, fstab will still have the old info and it’ll cause issues? Putting the slider back to default probably won’t just clear the fstab rules. That’d be too simple haha.

I’m totally not opposed to just reinstalling yet again and starting from scratch, if my plan will work. Any guidance is greatly appreciated!

EDIT: I think I got it! For anyone with the same issue, I added uid=1000,gid=1000 to the end of the options strings in gnome disk utility. I am now the owner of the drives, Emby can do what it needs to do, and the permissions stuck after a reboot! Now I just gotta look into why that worked haha.

EDIT 2: Spoke too soon. After a reboot they were ro for Emby again. I added rw to the drive options and it worked again. But after another reboot, no go again. Turns out after each reboot unmounting then remounting works. Not sure if there’s a way to make this work. Maybe they mount too soon? I dunno, but for now it’s functional.

  • FauxLiving@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    12 hours ago

    That fstab entry is correct (assuming the by-label path is valid), you could change auto to ntfs-3g but it is likely detecting the correct type so that isn’t needed.

    If you can put it in the ‘not working’ and also in the ‘working’ state you can compare how it is mounted with

    findmnt -t ntfs-3g
    

    That’ll show the options that the mounts are currently using, a quick thing that you can try unmounting and remounting

    sudo umount /mnt/Samsung
    sudo mount /mnt/Samsung
    

    That should mount it with the options in the fstab file, you can confirm with the findmnt command.

    If not, that doesn’t work try umounting and then mounting with the options set explicitly:

    sudo mount -t ntfs-3g -o uid=1000,gid=1000,rw /dev/disk/by-label/Samsung /mnt/Samsung
    

    and see if they show in findmnt.

    • Jack_Burton@lemmy.caOP
      link
      fedilink
      arrow-up
      1
      ·
      edit-2
      11 hours ago

      Awesome thank you so much. I was wondering about the auto option. I’ll try changing that to ntfs-3g in gnome disk. I’m guessing I could also open fstab and change it manually but I’m not quite there yet haha. I just tried findmnt -t ntfs-3g and there was nothing. I’m expecting to see something when I run it again after changing from auto.

      Edit: Changed one drive to ntfs-3g and rebooted. findmnt -t ntfs-3g is still nothing, but sudo nano /etc/fstab does show it’s ntfs-3g. Still had to remount for Emby to get write privileges. I then unmounted Samsung and ran sudo mount -t ntfs-3g -o uid=1000,gid=1000,rw /dev/disk/by-label/Samsung /mnt/Samsung. fstab still shows auto on that one.

      • FauxLiving@lemmy.world
        link
        fedilink
        arrow-up
        2
        ·
        8 hours ago

        ou’re Try just running findmnt, the type may be ntfs instead of ntfs-3g. The -t switch is saying to filter and only show ‘ntfs-3g’ mounts and it maybe called something else in your environment. The list will be a bit longer but you should be able to find the listing, it’ll be the directory where your drive is mounted.

        I then unmounted Samsung and ran sudo mount -t ntfs-3g -o uid=1000,gid=1000,rw /dev/disk/by-label/Samsung /mnt/Samsung

        Did Emby work after this? You said you had to remount, what did you use to do that?

        If you can get Emby to work, you can then look at findmnt to see how the working directory is mounted (which options/etc) and then you can update your fstab to have those options so that it will mount on startup.

        I’m guessing I could also open fstab and change it manually but I’m not quite there yet haha.

        Now’s a good time!

        Editing the fstab is the ‘correct’ Linux way of doing things, the GUIs can be convenient but they can also prevent you from learning how the system works (so when it later breaks, you have no idea where to start).

        fstab is just a text file, there are 6 fields: <file system/device> <directory where the device will be mounted> <filesystem type> <options> <dump> <pass>. The way it tells the fields apart is through white space(a tab or space character).

        /dev/sda1  (any amount of spaces or tabs)  /home/external-drive   options,seperated,by,comma    0(old way of marking a drive to be backed up)   2(fsck check order, 1 for your root directory, 2 for everything else, 0 if you don't want disk checking like for a swap device)
        

        If you’re worried about breaking anything you can just make a backup:

        sudo cp /etc/fstab /etc/fstab.bak
        

        If you break something, just restore it:

        sudo cp /etc/fstab.bak /etc/fstab
        
        • Jack_Burton@lemmy.caOP
          link
          fedilink
          arrow-up
          1
          ·
          edit-2
          8 hours ago

          Wow, that fstab info is great thanks! I’ve added it to my notes.

          Did Emby work after this? You said you had to remount, what did you use to do that?

          If you can get Emby to work, you can then look at findmnt to see how the working directory is mounted (which options/etc) and then you can update your fstab to have those options so that it will mount on startup.

          Yes, it works as it should. I’ve done it twice, and remounted once with gnome disk and once in Dolphin. However, I’m wondering if it’s an issue with installing Emby itself. Emby can access everything it should after remounting the drives, but the drive permissions are all user:user with 777 (which is probably why Emby can access it, it’s permission is other?) There’s nothing with permissions for user:emby like it should be, and sudo chown doesn’t change the group. There’s also no emby group option in the pulldown menu (when I was on Ubuntu I just used the pulldown to change the group permission). I went to make sure and ran groupadd emby but it said there’s already a group emby.

          As it is right now it all works after remounting, that said the drives that should say ntfs-3g in findmnt say fuseblk, in fact all the NTFS drives are fuseblk.