On Sunday 21 Aug 2011 10:49:37 Rob MacGregor wrote:
On Sun, Aug 21, 2011 at 10:21, Bob Williams <linux < at > barrowhillfarm.org.uk>
wrote:
I've used rsnapshot for many years with no problem, but suddenly I've
started getting the following errors:
-------------------------------------------------------------------------
--- rsnapshot encountered an error! The program was invoked with these
options: /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly
-------------------------------------------------------------------------
--- ERROR: Lockfile /var/run/rsnapshot2.pid exists and so does its
process, can not continue
I've looked in /var/run and cannot find the rsnapshot2.pid referred to
above. I run rsnapshot with a variety of different conf files, but they
are all behaving the same way.
I've also looked for a running rsnapshot or rsync process in top, but
there is none.
Apart from reading my crontab a day or two ago (not writing/editing it) I
cannot think of anything I might have done to trigger this behaviour.
What does your rsnapshot log file show about the previous run? Had it
completed by then or has an increase in data to be backed up resulted
in it over-running the next interval?
This is the log of the latest hourly run:
[21/Aug/2011:10:00:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
started
[21/Aug/2011:10:00:01] echo 27177 > /var/run/rsnapshot2.pid
[21/Aug/2011:10:00:01] /bin/rm -rf /castor/Snapshots/hourly.5/
[21/Aug/2011:10:00:02] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
started
[21/Aug/2011:10:00:02] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
ERROR: Lockfile /var/run/rsnapshot2.pid exists and so does its process, can
not continue
[21/Aug/2011:10:00:12] mv /castor/Snapshots/hourly.4/
/castor/Snapshots/hourly.5/
[21/Aug/2011:10:00:12] mv /castor/Snapshots/hourly.3/
/castor/Snapshots/hourly.4/
[21/Aug/2011:10:00:12] mv /castor/Snapshots/hourly.2/
/castor/Snapshots/hourly.3/
[21/Aug/2011:10:00:12] mv /castor/Snapshots/hourly.1/
/castor/Snapshots/hourly.2/
[21/Aug/2011:10:00:12] mv /castor/Snapshots/hourly.0/
/castor/Snapshots/hourly.1/
[21/Aug/2011:10:00:12] mkdir -m 0755 -p /castor/Snapshots/hourly.0/
[21/Aug/2011:10:00:12] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /home
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:39] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /etc
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:40] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /srv
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:40] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /usr/share/fonts
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:41] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /var/lib/mysql
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:41] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /var/log
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:10:01:42] touch /castor/Snapshots/hourly.0/
[21/Aug/2011:10:01:42] rm -f /var/run/rsnapshot2.pid
[21/Aug/2011:10:01:42] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
completed successfully
and this is the log of last night's run, where hourly.5 gets moved to daily.0
[20/Aug/2011:22:02:13] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
completed successfully
[21/Aug/2011:01:50:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 daily:
started
[21/Aug/2011:01:50:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 daily:
started
[21/Aug/2011:01:50:01] echo 31290 > /var/run/rsnapshot2.pid
[21/Aug/2011:01:50:01] echo 31291 > /var/run/rsnapshot2.pid
[21/Aug/2011:01:50:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 daily:
ERROR: Could not write lockfile /var/run/rsnapshot2.pid: File exists
[21/Aug/2011:01:50:02] /bin/rm -rf /castor/Snapshots/daily.6/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.5/
/castor/Snapshots/daily.6/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.4/
/castor/Snapshots/daily.5/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.3/
/castor/Snapshots/daily.4/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.2/
/castor/Snapshots/daily.3/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.1/
/castor/Snapshots/daily.2/
[21/Aug/2011:01:50:29] mv /castor/Snapshots/daily.0/
/castor/Snapshots/daily.1/
[21/Aug/2011:01:50:30] mv /castor/Snapshots/hourly.5/
/castor/Snapshots/daily.0/
[21/Aug/2011:01:50:30] rm -f /var/run/rsnapshot2.pid
[21/Aug/2011:01:50:30] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 daily:
completed successfully
[21/Aug/2011:02:00:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
started
[21/Aug/2011:02:00:01] echo 31865 > /var/run/rsnapshot2.pid
[21/Aug/2011:02:00:01] mv /castor/Snapshots/hourly.4/
/castor/Snapshots/hourly.5/
[21/Aug/2011:02:00:01] mv /castor/Snapshots/hourly.3/
/castor/Snapshots/hourly.4/
[21/Aug/2011:02:00:01] mv /castor/Snapshots/hourly.2/
/castor/Snapshots/hourly.3/
[21/Aug/2011:02:00:01] mv /castor/Snapshots/hourly.1/
/castor/Snapshots/hourly.2/
[21/Aug/2011:02:00:01] mv /castor/Snapshots/hourly.0/
/castor/Snapshots/hourly.1/
[21/Aug/2011:02:00:01] mkdir -m 0755 -p /castor/Snapshots/hourly.0/
[21/Aug/2011:02:00:01] /usr/bin/rsync -a --delete --numeric-ids --relative --
delete-excluded --exclude-from=/home/bob/bin/excludedfiles --link-
dest=/castor/Snapshots/hourly.1/localhost/ /home
/castor/Snapshots/hourly.0/localhost/
[21/Aug/2011:02:00:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
started
[21/Aug/2011:02:00:01] /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly:
ERROR: Lockfile /var/run/rsnapshot2.pid exists and so does its process, can
not continue
I'm not sure whether these logs are helpful, but will try increasing the
interval between jobs in crontab, and see if that fixes the problem. So, here
is my new crontab entry, increasing the intervals between hourly, daily,
weekly and monthly from 10 minutes to 20 minutes:
# Backup schedule to /castor every 4 hours:
0 2,6,10,14,18,22 * * * root /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 hourly
40 1 * * * root /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 daily
20 1 * * 6 root /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 weekly
0 1 1 * * root /usr/bin/rsnapshot -c /etc/rsnapshot.conf2 monthly
Thanks,
Bob
--
Registered Linux User #463880 FSFE Member #1300
GPG-FP: A6C1 457C 6DBA B13E 5524 F703 D12A FB79 926B 994E
openSUSE 11.4 64-bit, Kernel 2.6.37.6-0.5-desktop, KDE 4.6.5
Intel Core2 Quad Q9400 2.66GHz, 8GB DDR RAM, nVidia GeForce 9600GT
------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system,
user administration capabilities and model configuration. Take
the hassle out of deploying and managing Subversion and the
tools developers use with it.
http://p.sf.net/sfu/wandisco-d2d-2
_______________________________________________
rsnapshot-discuss mailing list
rsnapshot-discuss < at > lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rsnapshot-discuss