Help with Rsync

    • OMV 4.x

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Help with Rsync

      Hi,

      I need some help with setting Rsync up please. I have my OMV box with RAID 1 setup, i have a few CIFS shares setup for windows. I am trying to sync a share for backup to a WD MyBookWorld NAS. I have created a share on the WD NAS and also created a NFS share using remote mount to point to WD NAS folder.

      I have setup an Rsync job to sync the OMV share 'Contracts' to WD NAS 'Contracts' but i get the following error when running job. Can anyone point me in the right direction please.

      Images
      • nfs.png

        170.77 kB, 1,920×1,080, viewed 78 times
      • share.png

        156.35 kB, 1,920×1,080, viewed 34 times

      The post was edited 1 time, last by bundersuk: Duplicate image ().

    • I'm not sure why you're using NFS mount points, however, Rsync'ing two SMB shares between two platforms works fine with Remote Mount.
      It's best to "pull" to OMV or use your World Book NAS to "pull" from OMV network shares. However, OMV will "push" to the WD NAS if the user + password supplied in the Remote Mount dialog has write access to the WD share.

      See this -> thread for some of the details and screen shots. The only real difference between a "pull" or a "push", in the Rsync job, would be which shared folder is the source and which is the destination. Check and recheck your source and destination, before running the job. I would advise against using the Delete switch in the Rsync job setup until you've confirmed that you have two full data copies on the WD and OMV.

      There's one exception in the thread that wouldn't apply if you "push" to the WD. You wouldn't add extra options in the Rsync job. (This would apply only if pulling data to OMV.) The WD will probably write permissions for files it receives based on the user + password provided in Remote Mount.

      _______________________________________________________

      The most common mistakes:
      - The Rsync Job type is "Local". (When using the Remote Mount plugin, the remote file system is, for all practical purposes "local" and mounted.)
      - When setting the remote mounted file system, as a shared folder, the mount point is / This will require manual editing of the dialog.
      (Both of the above are in the screen shots.)
      _______________________________________________________

      The post was edited 2 times, last by crashtest ().

    • Update...

      I have managed to get the CIFS mount created, had to change options to vers=1.0 to get it to work.



      I get an error while running.

      Please wait, syncing </srv/dev-disk-by-label-DataDrive/Contracts/> to </srv/59655d2c-2e44-4073-bdb3-7befa3bddbe5> ...

      sending incremental file list
      rsync: chgrp "/srv/59655d2c-2e44-4073-bdb3-7befa3bddbe5/." failed: Permission denied (13)

      I get this error for all folders in the Contracts share. I have ran it a few times it always happens. It also freezes at an excel spreadsheet file and I have to stop the backup to do anything.

      I am learning this, i take it, it is the admin account that is performing the backup, therefor it will have permissions to all files on OMV and the user acoount i used in creating remote mount was the details of the admin account of the NAS i am transferring to.

      Thanks all for taking the time to read this

      bundersuk
    • "Permission Denied", on the destination, which is the WD...

      A question:
      Where does the excel file reside, and is it open? Is it on OMV or is it on the WD? If you're pushing files to the WD, it makes sense to edit/create/delete files only in the OMV network share. (If the WD is to be a backup device.)

      In practice, to avoid file open/save conflicts, it would be best to run the Rsync Job after hours where it's unlikely that files would be open. If files are open, close them and try to run the job again.
      ____________________________________________

      On the permissions end of it:

      For the remote mount to appear in file systems, the username and password provided in the remote mount dialog must have at least read access.

      If you can access the WD network share from your Windows Workstation, and add/edit/delete files from there, you could try using the username + password that you use to login into your Windows machine, in the remote mount dialog.
      ____________________________________________

      BTW: To get past potential permissions issues between OMV and Windows access to OMV's shares; create a user in OMV that exactly matches the username + password (cap's and all) that you use to log into your Windows PC. You can do this under Access Rights Management, User.
      ____________________________________________

      For my info, what is your environment? Is this at home or in a small business?
    • Hi,

      Why did the remote share only work when i changed option to vers=1.0 when it was '_netdev,iocharset=utf8,vers=2.0,nofail' , i read that 1.0 has been depreciated.

      The excel file resides on OMV.

      I am pushing from OMV to WD NAS, I have restarted the WD NAS, would that not break any connection a PC might have to a file?

      The user account im remote mount is the admin account of WD NAS.

      This is a setup for a small business.

      Thanks again

      bundersuk

      The post was edited 1 time, last by bundersuk ().

    • bundersuk wrote:

      Why did the remote share only work when i changed option to vers=1.0 when it was '_netdev,iocharset=utf8,vers=2.0,nofail' , i read that 1.0 has been depreciated.
      SMB1 was depreciated by Microsoft but, apparently, not by WD. This parameter is for the remote host.

      bundersuk wrote:


      I am pushing from OMV to WD NAS, I have restarted the WD NAS, would that not break any connection a PC might have to a file?
      No it wouldn't. If the file is resident on one of OMV's shares (the Excel file for example), power cycling the WD would have no effect. You'd have to break that connection at OMV.
      On the other hand, if a client has a file open on the WD, that would be a problem. To over write an existing file, with a new version, the older version can't be locked.
      ______________________________________________________

      The admin user and password should be fine for remote mount, to access the WD.

      You can check for files open with smbstatus -L
      If files are open and locked, this command will break the connections. /etc/init.d/samba restart
      (*Note that connections broken in this way may result in losing edits to the file.*)

      So, you could power cycle the WD, run the command /etc/init.d/samba restart on OMV's CLI, and run the Rsync job to see what happens.
    • tkaiser has a legitimate point.

      Given the age of SMB1, I looked at the age of WD's World book. It seems to be approximately 10 years old. By extension, if it's been used even intermittently over the years, the drive(s) in it may be close to end-of-life.

      Since your OMV server is part of a business operation:
      You might consider getting another PC, or an SBC, and an appropriate sized drive for backup. If you have a used PC that could be re-purposed, this is a low cost option. If setup correctly, with OMV as the OS, the 2nd platform could serve for data backup and as a backup server.