Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: rsync fails on NAS due to permissions

  1. #1
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Question rsync fails on NAS due to permissions

    I found out about a luckyBackup - back-up & sync program recently, tried it and I don't understand how I lived all these years without it. It's the best and easiest back up program I have seen so far (maybe there are others, I haven't researched this area yet), it does back-ups in no time without problems (it only writes file differences that's why it's so quick).

    But it has problems with syncing with my NAS. It syncs well with my desktop drives/folders, but it says it fails to sync to NAS due to permissions, something like "rsync chgrp operation not permitted(1) errors".

    I have a Seagate BlackArmor NAS 110 running NFS which is automounted on my desktop with autofs. The NAS has been set up with correct UID and GID which I belong to, and with read/write permissions for shared folders. I mean I can read/write to/from the NAS in Dolphin without problems, but the sync from luckyBackup fails for some reason, luckyBackup backup works fine though.

    I've checked the NAS file/folder properties, they're all none/nobody or something like that even though I specifically set them to belong to the UID & GID and I can't change that to anything else.

    I've unselected 'preserve permissions' and 'time' but it stil fails to sync with the NAS.

    Does anyone know what can be a problem? Thank you.
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

  2. #2
    Join Date
    Nov 2009
    Location
    West Virginia Sector 13
    Posts
    15,769

    Default Re: rsync fails on NAS due to permissions

    I just tried it. I agree very nice backup program with a simple user interface. Does not seem to like NFS file system. Of course this is the rsync backend that is choking.

    Did not like setting the destination as user (crashed) but accepted the destination ok if run as root.

    the rsync problem may have to do with the fact that NFS does not support permissions maybe??? Anyone know?

  3. #3
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Default Re: rsync fails on NAS due to permissions

    The backup part works with NFS just fine without any problems. It's the sync and NAS which don't want to talk.

    - Why does NAS have a 'nobody' group instead of the one I assigned to the shared folder?
    - Is this done for security?
    - Is using 'nobody' more secure than an assigned group?
    - Should I add myself to the 'nobody' group?
    - Or should I run the luckyBackup as root?
    - Does root belong to nobody? (I've disabled admin, i.e. root, access to the NAS NFS)
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

  4. #4
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: rsync fails on NAS due to permissions

    It's hard to say without knowing how the filesystem and exports on your NAS box are arranged by the vendor. It could be that it maps all registered uids to nobody so that any NFS user can access any file. Could you not tell rsync not to worry about preserving owner and group?

  5. #5
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Default Re: rsync fails on NAS due to permissions

    I have (in luckyBackup) and it keeps reverting back to preserving owner, group and time. maybe it's luckyBackup bug? this only happens with the sync option. with the backup option if I untick the preserving owner, group and time, it keeps them off.

    I've just realised the folder on NAS has been created when I was logged in as admin. this would probably explain why it was made as 'nobody' (for security?). I have to try to make a folder having logged in as a user and then to see if the folder has got the user owner and group permissions belonging to the user.
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

  6. #6
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: rsync fails on NAS due to permissions

    Yes, if you created a folder on a NFS as root, it would probably be mapped to nobody. Try creating a folder as yourself.

  7. #7
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Default Re: rsync fails on NAS due to permissions

    Linux definitely makes you use your brains some times
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

  8. #8
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: rsync fails on NAS due to permissions

    There is a reason why root is mapped to nobody on NFS shares unless specifically overriden by no_root_squash at the server end. Consider this scenario:

    1. A share is exported by a NFS server, call it Victim
    2. User has normal account on Victim
    3. User has root account on a machine, a NFS client, call it Evil
    4. On Evil, user creates a setuid root program, say bash, on the share that Victim exports
    5. User logins to Victim and runs the setuid root bash
    6. Voila, all your files on Victim are belong to us, bwahahahaha

    root_squash prevents step 4.

  9. #9
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Default Re: rsync fails on NAS due to permissions

    I knew all of that, I'm running an NFS server on my desktop. But for some reason I had a brain freeze and totally forgot/ignored that the NAS is running an embedded Linux and the same rules apply. I thought of it more like of an external storage rather than a Linux file server. wakey-wakey...
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

  10. #10
    Join Date
    Jun 2008
    Location
    Australia
    Posts
    399

    Default Re: rsync fails on NAS due to permissions

    I've just logged in NAS and it turns out a user can't create folders. ****!

    PS. Why is "d a m n" a forbidden word here? It's not a swear word as far as I know and the forum does not associate itself with any religious cult, does it?
    Desktop: openSUSE Leap 15 | KDE 5 | Intel i-7500 | Asus ROG STRIX Z270H GAMING | Asus EX-GTX1050TI-O4G nVidia
    Laptop Asus UL30A: openSUSE Leap 15 | KDE 5 | Intel SU7300

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •