Strange Permission Issue - Depending on How I Mount the Share

  • It has been a long time since I've set up an OMV server. Last time I did it was within a Windows environment. However, I'm now in a Linux environment and I've having strange issues with permissions.

    While on a Linux Mint machines, I can browse the network, find the share and mount it. Once mounted, I have full read/write permissions; this is the desired behavior. However, if I mount the share via the mount command, I seem to only have read permissions. Below, I'll show some examples.

    Mounted via the command line:

    sudo mount // /home/tome/omv1/ -o user=testuser


    When I check to see how it's mounted, it looks like it's mounted read/write:

    // on /home/tome/omv1 type cifs (rw,relatime,vers=default,cache=strict,username=testuser,domain=,uid=0,noforceuid,gid=0,noforcegid,addr=,file_mode=0755,dir_mode=0755,soft,nounix,serverino,mapposix,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1,user=testuser)

    However, when I mount it by just browsing the local network and drilling down to the share, I can create all I want:

    What am I missing?

  • My guess is because you’re mounting as root using sudo. If you drop to terminal to see the permissions in the mint client what does it show?

    I'm not entirely sure what you mean... I know if I browse the network and mount the share that way (the way in which I end up with r/w permissions), I can run the mount command after the fact (to see what all is mounted) but I don't see it in the list and cannot see the options (and possibly permissions?). It's only when I use the mount command to mount the share that I can see how it's mounted after the fact. Is that what you're after?

    I tried mounting the share via the mount command - without doing it as root (sudo) - but it won't mount. It chucks errors, nagging about how only root can use the options switch (-o) and how only root can use mount.

  • You have rw when you use the explorer because the process (running under your username) is mounting the share using gvfs.

    When you use sudo (root) the mount command is mapping the owner of the remote folder as root.

    Are you just asking because you’re curious or you definitely want to use the mount command as a desktop user ?

    If you want to use the mount command you need to add an extra options indicating the uid of the current user in the desktop workstation.

    sudo mount // /home/tome/omv1/ -o user=testuser,uid=1000,gid=100

    assuming 1000 is the tome user id. You can verify in the terminal with

    id tome

  • Are you just asking because you’re curious or you definitely want to use the mount command as a desktop user ?

    It all started when I tried to do some rsync work between an old Synology and the OMV server. I went to do the rsync command and found that, when I browsed to and mounted the OMV share via Nemo (When you said "explorer window" I'm guessing that's what you meant.), I could not use rsync with "smb://..." paths. If you look at the second screen-shot in my initial post, you'll see the address in the top of the window. Evidently, I need a mounted path local to the file system. So, I tried mounting it and stumbled upon the issue in my initial post.

    Side note:
    I would have just SSH'd into the OMV server and mounted the Synology's NFS share and ran rsync from there - skipping my Mint machine altogether - but I wasn't sure what path to use on the OMV server. I was guessing it was this one but wasn't sure and didn't want to mess up anything: /srv/c09aed70-0d42-46b7-8e96-b7efd949a906/media/...

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!