Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 11 of 11
  1. #1
    Member
    Join Date
    Sep 2006
    Posts
    144
    cPanel/Enkompass Access Level

    Website Owner

    Default rsync takes ages ...

    Hello for some days rsync takes ages (even do not do nothing) to move incremental backups to off-site server.


    root@server [~]# rsync -avze ssh /backups user@xxx.xx.xxx.xxx:folder
    user@xxx.xx.xxx.xxx's password:
    building file list ...



    and ... before all was very fast and worked.


    Any ideas ?
    Seems it is from remote (off-site) server cause to a different off-site server worked as before (fast)


    Any ideas what may be the reason ?


    Thanks.
    QHoster.com - Unlimited-Domain Web Hosting | Shared & Reseller with cPanel

  2. #2
    Member
    Join Date
    Mar 2002
    Posts
    175

    Default

    If the server is using maildir format, and there are a ton of mail files it will take ages. And it will take ages to transfer the files. It'd be nice if there was a way to automatically archive those into ONE file. I have one server that has hosted about 500 sites for 4 years. It had over 2 million spam emails sitting on it from users who don't take care of their mailboxes.

  3. #3
    Member
    Join Date
    Sep 2006
    Posts
    144
    cPanel/Enkompass Access Level

    Website Owner

    Default

    No it works great for 4 servers, now for 3 does not work and for 4th works. Got to be some explanation
    QHoster.com - Unlimited-Domain Web Hosting | Shared & Reseller with cPanel

  4. #4
    Member rikgarner's Avatar
    Join Date
    Mar 2006
    Location
    /dev/null
    Posts
    75

    Default

    Have you got any way to see whether it is fully utilising its bandwidth - ie, is the server sat there using 5% of its bandwith to the other server, whereas the server which works is maxing its connection?

    Im just thinking about what slows a tape backup down - things like locked files, databases etc...

    Maybe.. Its a stab in the dark!

    Rich
    Any views or opinions presented are solely those of the author and do not necessarily represent those of Computer Service Centre. Any advice is given soley on the assumption that it will be followed at your own risk.

  5. #5
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Personally, I'd try it without compression which has never been very reliable with rsync over the network, i.e. don't use z in -avze
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  6. #6
    Member
    Join Date
    Sep 2006
    Posts
    144
    cPanel/Enkompass Access Level

    Website Owner

    Default

    I have found the issue was the slow network (was a lot of collisions).



    Thanks.
    QHoster.com - Unlimited-Domain Web Hosting | Shared & Reseller with cPanel

  7. #7
    Member
    Join Date
    Oct 2002
    Posts
    751

    Default

    Quote Originally Posted by chirpy
    Personally, I'd try it without compression which has never been very reliable with rsync over the network, i.e. don't use z in -avze
    Unreliable as in resulting in non-functional backups?

    I haven't noticed any issues yet with -z, but if rsyncing without compression increases the reliability I guess I'll try that.

  8. #8
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Quote Originally Posted by jamesbond
    Unreliable as in resulting in non-functional backups?

    I haven't noticed any issues yet with -z, but if rsyncing without compression increases the reliability I guess I'll try that.
    In the past I've found that the rsync with compression can often fail to completely transfer the files. It also can consume considerable CPU. If you're copying full backups it is probably a complete waste of resources anyway since the tarballs are already compressed (with gzip).
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  9. #9
    Member twhiting9275's Avatar
    Join Date
    Sep 2002
    Posts
    359

    Default

    For the best usage of system resources, I have found (and recommend) that this works quite well:

    Back the server up onto an additional hard drive with NO compression (zip, etc). This will do two things to save your server CPU time

    Firstly, it won't compress everything (yay)
    Secondly, it won't copy everything, just the MODIFIED files. Again, this saves your server CPU time/load

    Once that's done, rsync it across to the backup server. Again, this saves the compression as stated above, and is just doing a compare, tossing only what's CHANGED over there.

    This provides the ultimate in backups, as you have OFF site backups, and ON site backups as well.

    As far as the speed, that's going to depend on how well network A talks to network B. It's always best when using rsync, if you CAN , with this much data to use something like vpn or private networking which will usually help out a great bit.
    Linux Tech Networks: Reliable Server Administration and Monitoring since 2002

  10. #10
    Member
    Join Date
    Jun 2002
    Posts
    130

    Default

    Quote Originally Posted by twhiting9275
    For the best usage of system resources, I have found (and recommend) that this works quite well:

    Back the server up onto an additional hard drive with NO compression (zip, etc). This will do two things to save your server CPU time

    Firstly, it won't compress everything (yay)
    Secondly, it won't copy everything, just the MODIFIED files. Again, this saves your server CPU time/load

    Once that's done, rsync it across to the backup server. Again, this saves the compression as stated above, and is just doing a compare, tossing only what's CHANGED over there.

    This provides the ultimate in backups, as you have OFF site backups, and ON site backups as well.

    As far as the speed, that's going to depend on how well network A talks to network B. It's always best when using rsync, if you CAN , with this much data to use something like vpn or private networking which will usually help out a great bit.
    I've been wanting to do this, but how do you set the the off-site backup to run after the on site backup finishes (so that they don't run at the same time)?

  11. #11
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    You can now create a script called /scripts/postcpbackup which will run after the cpbackup has completed and add your shell commands into it, e.g.:

    #cat /scripts/postcpbackup

    #!/bin/sh
    rsync --delete --stats -vae ssh /backup/cpbackup/daily remote@remote.server.com/backup/server
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

Similar Threads & Tags
Similar threads

  1. Replies: 2
    Last Post: 04-28-2011, 08:36 AM
  2. Cpanellogd takes ages to process log files...
    By driverC in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 08-17-2006, 10:56 PM
  3. rsync://rsync.cpanel.net broken?
    By Sinewy in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 10-26-2004, 07:08 AM
  4. Replies: 0
    Last Post: 01-25-2004, 05:02 PM
  5. Left Menu in cpanel takes ages to come up.
    By Domenico in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 09-03-2001, 07:39 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube