This is probably the most eternal question concerning rsync, but I'm really in doubt since I can't find the appropriate answer or solution anywhere for many months. I'm using rsync for simple daily back up data from one HD to another. It takes about 10 minutes daily under "nice -n 19". The problem is well-known as I see - several other services such as httpd or mysql begin responding slowly (up to 10 sec for mysql queries which usually processed in a small fraction of a second). The reason is pretty obvious, but still are there any general recommendations on how to solve or appreciably soften the situation? Best regards, Denis Solovyov
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Thu, Feb 16, 2006 at 07:49:03PM +0800, Denis Solovyov wrote:> I'm using rsync for simple daily back up data from one HD to another. It > takes about 10 minutes daily under "nice -n 19". The problem is > well-known as I see - several other services such as httpd or mysql > begin responding slowly (up to 10 sec for mysql queries which usually > processed in a small fraction of a second). > > The reason is pretty obvious, but still are there any general > recommendations on how to solve or appreciably soften the situation?I noticed this option in the man page which might be of help: --bwlimit=KBPS limit I/O bandwidth; KBytes per second - -- Philip Lowman -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFD9RG2L78avKCRU4wRAvgBAKC2MjLsTC5tvW/AQcAfXUvxLvr7cQCfa2H5 j+n1QBooqrpPyfY6tGbv5GU=dgAn -----END PGP SIGNATURE-----
>> > I'm using rsync for simple daily back up data from one HD to another. It >> > takes about 10 minutes daily under "nice -n 19". The problem is >> > well-known as I see - several other services such as httpd or mysql >> > begin responding slowly (up to 10 sec for mysql queries which usually >> > processed in a small fraction of a second). >> --bwlimit=KBPS limit I/O bandwidth; KBytes per secondMM> --bwlimit only limits the rate of transfer over the network. Vilius MM> Puidokas encountered the same problem and traced it to the scanning as MM> rsync generates the file list. He wrote a patch that adds a --slow-down MM> option that makes rsync wait a few microseconds in between scanning each MM> file. Find it here: MM> http://vilius.multiply.com/video/item/10 usleep(100) in that place of the source shown on the page really helps, but it dramatically increases the time of rsync'ing. I guess Vilius' supposition that usleep(100) for 10k of dirs is 10 sec is a bit wrong, it seems to be not a simple multiplication. Best regards, Denis Solovyov