OK thanks for your help with that :-)
On 8/3/62 14:56, Alpix wrote:
Hey Patrick,
thats my sync script.
#!/bin/bash DESTPATH="/var/www/mirror/centos/" RSYNC=/usr/bin/rsync LOCKFILE=/tmp/rsync-centos.lock synchronize() { $RSYNC -rltvHa --delete-after --delay-updates --safe-links eu-msync.centos.org::CentOS "$DESTPATH" } if [ ! -e "$LOCKFILE" ] then echo $$ >"$LOCKFILE" synchronize else PID=$(cat "$LOCKFILE") if kill -0 "$PID" >&/dev/null then echo "Rsync - Synchronization still running" exit 0 else echo $$ >"$LOCKFILE" echo "Warning: previous synchronization appears not to have finished correctly" synchronize fi fi rm -f "$LOCKFILE"
Greetings Alpix
Am Fr., 8. März 2019 um 08:47 Uhr schrieb Alpix <contact@alpix.eu mailto:contact@alpix.eu>:
Hello Patrick, i have one. I will send it in a few minutes. Greetings Patrick Shaw <patrick@shaw.co.th <mailto:patrick@shaw.co.th>> schrieb am Fr., 8. März 2019, 08:42: Hi, Does anyone have some examples of lock scripts/files for rsync? Due to slow international performance in this country I'm regularly seeing overlapping rsyncs, I need to get that locked down ASAP. Patrick _______________________________________________ CentOS-mirror mailing list CentOS-mirror@centos.org <mailto:CentOS-mirror@centos.org> https://lists.centos.org/mailman/listinfo/centos-mirror
CentOS-mirror mailing list CentOS-mirror@centos.org https://lists.centos.org/mailman/listinfo/centos-mirror