LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 10-13-2005, 11:44 AM   #1
RodWC
Member
 
Registered: Oct 2005
Distribution: SolydK, Linux Mint KDE, Debian
Posts: 180

Rep: Reputation: 30
How to clone or backup Linux boot drive?


Hello all, newbie here. I can't seem to find the information I want, anywhere, on this subject.

What I'd really like to do is be able to make an image file of my Linux drive (Debian Sarge) and store it on an offline drive for backup. I tried doing this with Norton Ghost 2003, but when I restored the image to a different drive to make sure the copy would boot, it didn't work. I re-installed GRUB (since Ghost doesn't support GRUB), and it starts to boot, but ends with the message "Kernel panic: Attempted to kill init!"

I also tried using Ghost for Linux (g4l), with almost the same results. How do you all back up your boot drives? I'm getting very frustrated! If I ever want to clone my current drive to a larger one, it looks like I'm sunk! Being that the current one is 2.5gb, that's a tough place to be in.

A little help would be very appreciated.
 
Old 10-13-2005, 12:36 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,542
Blog Entries: 15

Rep: Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491
You could just configure Linux software RAID and make your second drive a mirror (RAID 1). This has the benefit of being instantly bootable in the event the first drive has a hardware fault. The downside being if the problem is software (somebody deleted the wrong file for example) the problem would exist on the mirror as well. For most purposes however having a mirror then doing backup to tape works well enough for restoring missing files.

It may be possible to simply to configure the drive as a mirror and break the mirror so that it no longer is automatically updated. This is common in other things I've worked with but I've not done it in Linux.

You can copy a drive with "dd" but it won't do the boot sector. Doing a google for copying linux boot sector may point you to what you need.
 
Old 10-13-2005, 12:49 PM   #3
WhatsHisName
Senior Member
 
Registered: Oct 2003
Location: /earth/usa/nj (UTC-5)
Distribution: RHL9;F1-10; CentOS4-5; DebianSarge-Squeeze
Posts: 1,151

Rep: Reputation: 46
Re: How to clone or backup Linux boot drive?

Quote:
Originally posted by RodWC
...I re-installed GRUB (since Ghost doesn't support GRUB), and it starts to boot, but ends with the message "Kernel panic: Attempted to kill init!"...
Were /boot/grub/menu.lst and /etc/fstab pointing to the correct partition(s)? If not, you get kernel panic.
 
Old 10-13-2005, 01:27 PM   #4
NoStop
Member
 
Registered: Feb 2005
Location: Canada
Distribution: Debian Etch - Enlightenment E17
Posts: 116

Rep: Reputation: 15
Re: How to clone or backup Linux boot drive?

Quote:
Originally posted by RodWC
Hello all, newbie here. I can't seem to find the information I want, anywhere, on this subject.

What I'd really like to do is be able to make an image file of my Linux drive (Debian Sarge) and store it on an offline drive for backup. I tried doing this with Norton Ghost 2003, but when I restored the image to a different drive to make sure the copy would boot, it didn't work. I re-installed GRUB (since Ghost doesn't support GRUB), and it starts to boot, but ends with the message "Kernel panic: Attempted to kill init!"

I also tried using Ghost for Linux (g4l), with almost the same results. How do you all back up your boot drives? I'm getting very frustrated! If I ever want to clone my current drive to a larger one, it looks like I'm sunk! Being that the current one is 2.5gb, that's a tough place to be in.

A little help would be very appreciated.
I've been using Acronis True Image 8 for sometime now and it hasn't failed me yet. Constantly making images of Linux boxes and restoring them without a problem. Doesn't matter if they boot with lilo or grub, it just works.

Cheers.
 
Old 10-13-2005, 08:00 PM   #5
RodWC
Member
 
Registered: Oct 2005
Distribution: SolydK, Linux Mint KDE, Debian
Posts: 180

Original Poster
Rep: Reputation: 30
Re: Re: How to clone or backup Linux boot drive?

Quote:
Originally posted by WhatsHisName
Were /boot/grub/menu.lst and /etc/fstab pointing to the correct partition(s)? If not, you get kernel panic.
They should be, as the only thing that changed was the size of the partitions.

Don't know if I'm ready to try RAID yet, but sometime I might want to.

Perhaps I should give Acronis a try.
 
Old 10-14-2005, 09:45 AM   #6
RodWC
Member
 
Registered: Oct 2005
Distribution: SolydK, Linux Mint KDE, Debian
Posts: 180

Original Poster
Rep: Reputation: 30
Okay I checked fstab and "fdisk -l" to see if there is anything wrong. I can't tell on the fstab, but I noticed that fdisk reported the same number of blocks on a much larger drive. Is this the clue?

fstab:

# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
/dev/hda1 / ext3 defaults,errors=remount-ro 0 1
/dev/hda5 none swap sw 0 0
/dev/hdc /media/cdrom0 iso9660 ro,user,noauto 0 0



fdisk -l reports (note the difference in drive sizes and yet the exact same number of blocks. Is this supposed to happen? I really know nothing. lol):

Disk /dev/hda: 6007 MB, 6007357440 bytes
255 heads, 63 sectors/track, 730 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 696 5590588+ 83 Linux
/dev/hda2 697 730 273105 5 Extended
/dev/hda5 697 730 273073+ 82 Linux swap / Solaris

Disk /dev/hdd: 60.0 GB, 60022480896 bytes
255 heads, 63 sectors/track, 7297 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdd1 * 1 696 5590588+ 83 Linux
/dev/hdd2 697 730 273105 5 Extended
/dev/hdd5 697 730 273073+ 82 Linux swap / Solaris
CPX:/home/rodney/Desktop/temp/etc# Mutex destroy failure: Device or resource busy
ICE default IO error handler doing an exit(), pid = 4822, errno = 0
 
Old 10-23-2005, 12:05 PM   #7
Lunar
Member
 
Registered: Feb 2005
Location: Texas, USA
Distribution: opensuse
Posts: 100

Rep: Reputation: 7
Re: Re: How to clone or backup Linux boot drive?

Quote:
Originally posted by NoStop
I've been using Acronis True Image 8 for sometime now and it hasn't failed me yet. Constantly making images of Linux boxes and restoring them without a problem. Doesn't matter if they boot with lilo or grub, it just works.

Cheers.
Thanks for the heads up on Acronis. I've reviewed it and am purchasing it.. Sounds spot on.

Also, I Really like your signature "... Viruses.. small and efficient."... LOL. good one.

Lanids.

Last edited by Lunar; 10-23-2005 at 12:08 PM.
 
Old 11-13-2005, 01:23 AM   #8
under
LQ Newbie
 
Registered: Oct 2003
Location: Bucharest, Romania
Distribution: OpenSuse
Posts: 13

Rep: Reputation: 0
Anybody knows a linux application for this kind of job? I personally would need a solution i could run it from a live cd/dvd... and eventually write the image of my entire linux installation to a dvd. And, preferably, after that be able to restore/write that image on different systems.

# i suppose one of the problems would be the fact that for booting grub needs the
# exact coordinates of the /boot and root partition, so if either one changes, the restore would be
# impossible or at least time consuming.

Is there anything like that on linux?

Thanks.

Last edited by under; 11-13-2005 at 01:54 AM.
 
Old 11-13-2005, 10:00 AM   #9
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,542
Blog Entries: 15

Rep: Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491Reputation: 1491
Quote:
Make it simple stupid!

M.I.S.S.? I always thought it was K(eep).I.S.S.
 
  


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
dual boot Linux/Win HD clone rdrs Linux - Software 2 08-22-2005 10:50 PM
Clone Backup plz Help neos Linux - Newbie 4 02-11-2005 03:33 AM
Easy way to clone linux installed hard drive mobassir Linux - Software 6 01-12-2004 06:34 PM
Backup Boot drive question... Spec Linux - General 5 09-17-2002 10:56 AM
Alternate boot hard drive for backup irishb3 Linux - General 1 08-24-2001 03:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration