From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Tue, 20 May 2003 18:59:16 +0300 From: Michael Shigorin To: sisyphus@altlinux.ru Message-ID: <20030520155915.GJ17823@osdn.org.ua> Mail-Followup-To: sisyphus@altlinux.ru References: <20030515113240.GB13734@new.solutions.lv> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Yb+qhiCg54lqZFXW" Content-Disposition: inline In-Reply-To: <20030515113240.GB13734@new.solutions.lv> User-Agent: Mutt/1.4.1i Subject: [sisyphus] Re: =?koi8-r?B?+sXSy8HMzw==?= Sender: sisyphus-admin@altlinux.ru Errors-To: sisyphus-admin@altlinux.ru X-BeenThere: sisyphus@altlinux.ru X-Mailman-Version: 2.0.9 Precedence: bulk Reply-To: sisyphus@altlinux.ru List-Unsubscribe: , List-Id: List-Post: List-Help: List-Subscribe: , List-Archive: Archived-At: List-Archive: --Yb+qhiCg54lqZFXW Content-Type: multipart/mixed; boundary="JwB53PgKC5A7+0Ej" Content-Disposition: inline Content-Transfer-Encoding: 8bit --JwB53PgKC5A7+0Ej Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: 8bit On Thu, May 15, 2003 at 02:32:40PM +0300, Dmitry Ivanov wrote: > 2) Где прочитать про технологию синхронизации? У меня это делает скрипт, помещенный в аттач. Тупой, но работает. Синхронизирует покомпонентно, выставляя файл-флажок (__SYNCING__) на время процесса. -- ---- WBR, Michael Shigorin ------ Linux.Kiev http://www.linux.kiev.ua/ --JwB53PgKC5A7+0Ej Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rsync-all.sh" #!/bin/sh RSYNC_RSH=rsh MAXATTEMPTS=5 TMOUT1=500 TMOUT2=15 SRCROOT=rsync://rsync.altlinux.ru/ALTLinux # 2003-04-15 #SRCROOT=rsync://ibiblio.org/Linux/distributions/altlinux # 2002-12-07 #SRCROOT=rsync://ftp.leo.org/ALTLinux # 2002-12-09 DESTROOT=~ftp/pub/Linux/ALT #LIST="updates Sisyphus OpenOffice Mozilla" LIST="updates Sisyphus OpenOffice Mozilla" #LIST="updates" RSYNC=/usr/bin/rsync RSYNCARGS="-rltgoDu --partial --timeout=$TMOUT1 --delete --delete-after" RSHOME=~/rsync MAINTAINER=mike@osdn.org.ua for mirror in $LIST; do OK= attempt=1 LOG=$RSHOME/rsync-$mirror.log LOCK=$RSHOME/lock.$mirror FLAG=$DESTROOT/$mirror/__SYNCING__ date >> $LOG [ -f $LOCK ] && { ps auxww | grep rsync | mail -s "OSDN: $mirror: lockfile exists" $MAINTAINER echo "Lockfile for $mirror exists, quitting" >> $LOG continue } trap "rm -f $LOCK; exit 1" INT touch $LOCK $FLAG while [ -z "$OK" -a $attempt -lt $MAXATTEMPTS ]; do $RSYNC $RSYNCARGS $* $SRCROOT/$mirror/ $DESTROOT/$mirror \ >> $LOG 2>&1 && OK=1 sleep $TMOUT2 attempt=$(($attempt+1)) done [ -z "$OK" ] && { tail $LOG | mail -s "OSDN: $mirror trouble" $MAINTAINER rm -f $LOCK } || { rm -f $LOCK $FLAG } date >> $LOG done --JwB53PgKC5A7+0Ej-- --Yb+qhiCg54lqZFXW Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) iD8DBQE+ylDTbsPDprYMm3IRAouHAKCNfS3jWs3fzcjo1DM3Csphus0FsACgxiM6 t2D5qfHhMVjkBR+PxoS3Tqc= =Zjqs -----END PGP SIGNATURE----- --Yb+qhiCg54lqZFXW--