LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 05-22-2002, 08:42 PM   #1
medamnit
LQ Newbie
 
Registered: Apr 2002
Location: Australia
Distribution: RedHat
Posts: 16

Rep: Reputation: 0
cron job - backup


Hi,

I've been searching about cron jobs lately and trying to work out how to perform an automate of the backup.

like how would i automatically backup the '/root' every night (8pm)

any help or directions would be great.

Thanks
medamnit
 
Old 05-23-2002, 02:33 AM   #2
piranha
Member
 
Registered: Jan 2002
Distribution: Gentoo Linux 1.4
Posts: 52

Rep: Reputation: 15
Use webmin to create a cron job (System -> Scheduled Cron Jobs). It's very easy.
 
Old 05-23-2002, 11:38 AM   #3
medamnit
LQ Newbie
 
Registered: Apr 2002
Location: Australia
Distribution: RedHat
Posts: 16

Original Poster
Rep: Reputation: 0
cool, got the cron jobs down. but backup is little confusing.
read about basic command 'dump'.
any other options?

i'm trying to backup 2 files to floppy. any ideas?
also read recommend umount before backup. so would u umount your hd before backup?

thanks
medamnit

Last edited by medamnit; 05-23-2002 at 11:46 AM.
 
Old 05-23-2002, 11:55 AM   #4
hanzerik
Member
 
Registered: Jan 2002
Location: Cheyenne Wyoming
Distribution: Debian
Posts: 717

Rep: Reputation: 32
Well if its just 2 files that fit on a floppy:

make a script I'll call this floppy-bak containing:

#!/bin/bash
mount -t vfat /dev/fd0 /mnt/floppy
cd /root
cp filename1 filename2 /mnt/floppy
umount /dev/fd0

make it executable: chmod 744 floppy-bak

make a cron job to run the script
crontab -e
0 20 * * * /path/to/floppy-bak

you can put the script in /usr/sbin

You will need to have a floppy in the drive before this is run.

Last edited by hanzerik; 05-23-2002 at 12:02 PM.
 
Old 05-24-2002, 03:37 AM   #5
saavik
Member
 
Registered: Nov 2001
Location: NRW, Germany
Distribution: SLES11 / FC20/ OES / CentOS
Posts: 600

Rep: Reputation: 32
hello!

i woud not suggest to use webmin!
it is very much depending on what distrbution you are using.
And so i made the experience that somethimes everything in webmin looks find but isn`t really working.
 
  


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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cron Job petenyce Linux - Newbie 5 10-11-2005 04:03 PM
cron backup job not running dsschanze Linux - General 9 07-29-2005 08:47 PM
CRON Job tommytomato Fedora 12 09-13-2004 12:38 AM
Cron job rajasekarvr Linux - General 4 05-03-2004 05:35 PM
cron job thesnaggle Linux - Newbie 1 09-19-2003 10:47 AM


All times are GMT -5. The time now is 03:58 PM.

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