[Gllug] Running TAR backup through Root's Cron

Richard Jones rich at annexia.org
Thu May 15 11:20:00 UTC 2003


On Thu, May 15, 2003 at 11:53:54AM +0100, Steven Bellamy wrote:
> Hi,
> 
> I'm having a problem running a backup through Cron.
> I've created a very simple backup script (using TAR and Crontab for the user
> Root) to run backups at 01h00 everyday to backup a Squid Proxy Server in a
> remote office.
> The problem is that the backup only seems to backup about 140MB of data and
> then stops, if I run the same script from the shell (as root), it backs up
> the entire server.
> I have looked through the cron logs and syslogs but can't find any error
> messages.
> 
> Anyone have any suggestions?

Not about your specific problem, but it's often helpful in your
crontab to have:

MAILTO="your at email.address"
0 1 * * * /path/to/the/script.sh

Add some debugging to the script too. For example, print the entire
environment at the start of the script using the 'printenv' command.
Echo commands, by putting 'set -x' at the top of the script.  Also
make sure any critical programs are running in verbose mode, eg using
the -v option to tar.

Rich.

-- 
Richard Jones, Red Hat Inc. (London) and Merjis Ltd. http://www.merjis.com/
http://www.annexia.org/ Freshmeat projects: http://freshmeat.net/users/rwmj
MAKE+ is a sane replacement for GNU autoconf/automake. One script compiles,
RPMs, pkgs etc. Linux, BSD, Solaris. http://www.annexia.org/freeware/makeplus/


-- 
Gllug mailing list  -  Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug




More information about the GLLUG mailing list