LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 04-14-2004, 12:14 AM   #1
bally
Member
 
Registered: Jun 2001
Posts: 75

Rep: Reputation: 15
Tar Backup Log


Hi All

I am Taking sechduled backup of my samba server. For that i have put following commands in my crontab:-
##################################################
00 21 * * * /bin/mt -f /dev/st0 rewind
15 21 * * * /bin/tar -cvf /dev/st0 /home /etc /share
##################################################

But i want the log of the backup in some the file.
How should i proceed .

Kindly help.

Regards
Bally
 
Old 04-14-2004, 01:13 AM   #2
itsme86
Senior Member
 
Registered: Jan 2004
Location: Oregon, USA
Distribution: Slackware
Posts: 1,246

Rep: Reputation: 58
I'm not great at this kind of stuff, but here's an idea that might work.

Edit your cronttab so that it redirects stdout to a file (i.e. tar -cvf /def/st0 /home /etc /share > /backup.log) Then add a second tar command to the line that adds the backup.log file to the archive (man tar for this one).
 
Old 04-14-2004, 01:24 AM   #3
MS3FGX
Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
For my backup scripts, I add:

tar -tvf /dev/st0 > Backup_List

Not really a log, but it will show you what got backed up.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Tar backup TheRealDeal Linux - General 7 02-08-2005 04:25 PM
Using tar for backup. TheRealDeal Linux - General 2 08-11-2004 12:46 AM
tar as backup imsajjadali Red Hat 4 02-07-2004 04:46 PM
tar: How do I backup everything !! grantm Linux - Newbie 3 07-30-2003 03:41 PM
Do I have a viable tar backup? rdaves@earthlink.net Linux - General 4 08-30-2001 06:33 PM


All times are GMT -5. The time now is 09:30 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration