Koozali.org: home of the SME Server

BACKUP / DISK CLONE to enlarge or test upgrade

aussie

BACKUP / DISK CLONE to enlarge or test upgrade
« on: March 11, 2004, 12:46:59 AM »
Gee Ive see soooo much on this topic in bits and pieces.
Ive been trying to get a 'system' together - Im gettting close so want to share and look for advice/help on the last couple of pieces.

(Should 6.0.1 incorporate something for this - I think so)

1. the problem
2. the solution in detail (a solution)
3. what else may need to be done

(sorry if this gets a bit long BUT it has saved me a lot of searching and is 'almost perfect/complete'.
Hopefully some will appreciate the infomation:if I get flamed for verbose posting 'ce la guerre' [pour les francaise!])

1. the problem:

1a I want an easy to recover backup of an SME disk (this solution results in a bootable CD, that simply 'nuke's a new drive).

1b. I want an easy way to clone a drive to test an upgrade and have a way backwards if needed (the bootable CD simply sets up a new drive)

1c. I want to be able to migrate to a larger disk when one gets too full (the bootable CD resizes filesystems onto the new larger drive - or smaller: it does this automatically or you can manually set them )

I hope by now to have the interest of those who like me have scanned, downloaded and messed around too long with too many things that do not quite work!

2. the solution

2a. Hugo Rankin et al have created a FABULOUS program called 'mondo' which is the engine of this solution, see http://www.microwerks.net/~hugo/about/about.html.
There is a big how-to at http://www.chem.vu.nl/~stol/Mondo-Rescue-Mindi-Linux-HOWTO.pdf if you want all the gory details BUT

2b. Tom Haynes has wrapped this all up into a SME contribution with both 5.6 and 6.0 versions. He includes a HOW-TO at http://mirror.contribs.org/smeserver/contribs/thaynes/E-Smith/mondoarchive/
(Dont you just LOVE it when these contribs 'simply work'!)

Thanks to Tom for his off-forum advice, and I have made some suggestions for his How-To....

- be sure you install ALL rpms (rpm -Uvh *.rpm did not work for me - maybe I had some env wrong)

- the resulting iso to be burned is in the /root area:
I would prefer it in an ibay to make it easier to get onto a PC to burn (change the directory in the -d of mondoarchive for this)

- I prefer to include the whole disk (so remove his suggestion of -E /home)

- the -L option will use the much faster compression tool 'lzo' rather than bzip2: the resulting iso is a bit over twice as large but on a low-processor machine  it will generate quicker (I'm sticking with the default bzip2, as lzo on uses 1/2 my 2GHz celeron cpu time)

- the resulting iso for me is 280MB from 1320MB of disk (4.7:1 compression.
 
- this stuff DOES thrash around a while, but the result is GREAT: just burn the single file 1.iso!
(there are a bunch of other iso's generated too for boot floppy etc: I dont worry about them.)

- I tend to burn at 32x (40x often leads to the odd read problem for me)

- talking about burning, my old CD bunring software does not work with my new DVD burner (I need to burn CD not DVD as the sme server has a CD not a DVD!):
I found 'burnatonce' which installs in a flash and is really easy to use

- boot from the CD (dont forget bios settings to specify order of boot device: I use floopy/CD/disk),
and choose 'nuke' or interactive per the How-To and it makes a new drive !
as a recovery, clone or enlargement WOO HOO !

with DVD Burners becoming so cheap this will put something like 22GB onto 4.7GB media (but I think there is an issue of an iso above 2GB - which is still   a good 9GB of input files!)

3. what else needs to be done

3a. while this process runs, files are changing:
does someone know how to 'stop' sme for the duration?
(I suggest this should be a ceasing of all LAN activity - in or out: I see the mondoarchive running 1am so no worry about access - you want a PROPER backup)

3b. a panel to configure the runtime parameters of mondarchive, cron time etc. would be really cool:
if someone knows how to make the panel, Im happy to create the text, inputs etc required for it.

3c. at 4.7 compression, the 2gig file limit will not be an issue for most but will hit sooner or later:
what does one do about that ( I do not know).
I HAVE noticed mondo options to output direct to CD / DVD (either write-once or rewrite media - cool eh!, using the rewrite options does the delete files first).
I have not had time to play with this but will in due course.!

3d. something like this should be bundled into a new release as a priority: even if it is included with a proviso 'use at your risk', it would be a good step forward and something used by many - in my view).


Anyway back to work for me !
Ive had MY time and stress saved - I hope in this to pass that on.
 :pint: Rob

RonM

BACKUP / DISK CLONE to enlarge or test upgrade
« Reply #1 on: April 02, 2004, 02:32:54 AM »
Thanks for the How To, Aussie! and thanks for linking it to the Mondo contrib feedback.

See you around...

Anonymous

BACKUP / DISK CLONE to enlarge or test upgrade
« Reply #2 on: April 03, 2004, 04:56:08 PM »
Well,

I made a backup of my SME6.0 (Exept the /home directory)
All was OK.
I burned the iso file with Nero.
When i try to restore on another PC (PII 266 128Mo RAM Choosing the Nuke Option), the following message appears :
OK... Booting the Kernel and Noting appends , The only thing i can do is restart the PC

Any ideas ?

John

haynest

Boot problem
« Reply #3 on: April 05, 2004, 03:51:14 AM »
Are you moving from one type of architechure to another? The only time I have heard of a hang at boot is if you create the disk on a i686, and the kernel won't work on a Celeron, etc.

It might be a bad CD burn as well, but I haven't gotten a coaster in a while.

Also try

http://www.microwerks.net/~hugo/download/1.6x-howto/faq.html

To answer Aussie's concern about the backup size, it is possible to use a switch so you can fit them on cd:  -s 700m

gothlite

Re: BACKUP / DISK CLONE to enlarge or test upgrade
« Reply #4 on: May 06, 2005, 08:41:43 PM »
Quote from: "aussie"
Gee Ive see soooo much on this topic

Anyway back to work for me !
Ive had MY time and stress saved - I hope in this to pass that on.
 :pint: Rob

What command would i issue for a complete backup everything on my box ?
would this do the job #mondoarchive -Oi -d /root# ??
please help :-(

haynest

backup
« Reply #5 on: May 06, 2005, 10:09:07 PM »
mondoarchive -Oi -F -s 700m

should create isos in /root w/o a request for a floppy

The isos should be an appropriate size to burn on CD.

Have fun...   Tom

gothlite

Re: backup
« Reply #6 on: May 06, 2005, 11:19:39 PM »
Quote from: "haynest"
mondoarchive -Oi -F -s 700m

should create isos in /root w/o a request for a floppy

The isos should be an appropriate size to burn on CD.

Have fun...   Tom


Thx for the swift reply  :-D ....well it didnt work...
the boot cd nuked my drive and i got a error on the filesystem after a reboot, had to do a manual install.
Ended up using norton ghost and it worked fine with a little lilo tweaking...still wish that the mondo worked, it would be grand to put my Tweaked sme 6.0.1 on a bootable cd for mass installing/recovery.

haynest

Backup
« Reply #7 on: May 06, 2005, 11:23:38 PM »
Ouch...

I have had great success with Mondo. I wonder what the problem was?

Regards...   Tom

msilkjr

help
« Reply #8 on: January 22, 2006, 03:30:25 AM »
HELP .... i followed the howto and infi here but it doesnt work i get the folowing .....

[root@gateway /]# mondoarchive -Oi -F -s 700m
Initializing...
See /var/log/mondo-archive.log for details of backup run.
root is mounted at /dev/hda
I believe I am running on a live filesystem.
root is mounted at /dev/hda
I believe I am running on a live filesystem.
Checking sanity of your Linux distribution
Done.
Bad parameters. Type 'man mondoarchive' to see manual. Mondo will now exit.
Type 'less /var/log/mondo-archive.log' to see the output log
[root@gateway /]#

haynest

mondo problem
« Reply #9 on: January 22, 2006, 06:46:38 AM »
Hello...

what did the log file say?

I use Mondo as part of my daily backup routine, but I no longer have an SME installation. I'll bet I can help figure it out though.

Regards...   Tom

steel

modo backup
« Reply #10 on: January 22, 2006, 11:36:42 AM »
I had the same error a while back, it was a syntax error when I put in a "zero" and not a capital "O" or vice versa...

Also the full modo package can only NUKE install due to package problem, "newt-devel" i think was causing problems in the console. (it was in the help/howto) I wanted this so I could change to a RAID from a single drive but alas SME packages make it tricky ATM


Steve

msilkjr

mondo backup
« Reply #11 on: January 23, 2006, 09:44:28 PM »
here is the log file................. any help .........

-------------------- mount | grep cdrom | grep super --------------------
--------------------------------end of output------------------------------
...ran with errors.
------------------- mount | grep floppy | grep super -------------------
--------------------------------end of output------------------------------
...ran with errors.
Started sub
About to set g_boot_mountpt[0] to '\0'
Done. Great. Seeting command to something
Cool. Command = 'cat /etc/fstab | grep -v ":" | grep -vx "#.*" | grep -w "/boot" | tr -s ' ' '  ' | cut -f1 | head -n1'
tmp = 'LABEL=/boot1'
/boot is at LABEL=/boot1 according to /etc/fstab
...ignored cos it's a label :-)
Unmounting old ramdisks if necessary
-------- umount mount | grep shm | grep mondo | cut -d' ' -f3 --------
Usage: umount [-hV]
umount -a [-f] [-r] [-n] [-v] [-t vfstypes] [-O opts]
umount [-f] [-r] [-n] [-v] special | node...
--------------------------------end of output------------------------------
...ran with errors.
Mondo Archive v1.67 --- http://www.mondorescue.org
root is mounted at /dev/hda
I believe I am running on a live filesystem.
root is mounted at /dev/hda
I believe I am running on a live filesystem.
Checking sanity of your Linux distribution
Free space on given partition = 13849 MB
-------- umount mount | grep cdr | cut -d' ' -f3 | tr '
' ' ' --------
Usage: umount [-hV]
umount -a [-f] [-r] [-n] [-v] [-t vfstypes] [-O opts]
umount [-f] [-r] [-n] [-v] special | node...
--------------------------------end of output------------------------------
...ran with errors.
---------------------------- cat /etc/fstab ----------------------------
#------------------------------------------------------------
# BE CAREFUL WHEN MODIFYING THIS FILE! It is updated automatically
# by the SME server software. A few entries are updated during
# the template processing of the file and white space is removed,
# but otherwise changes to the file are preserved.
# For more information, see http://www.e-smith.org/custom/ and
# the template fragments in /etc/e-smith/templates/etc/fstab/.
#
# copyright (C) 2002 Mitel Networks Corporation
#------------------------------------------------------------
LABEL=/                 /                       ext3    usrquota,grpquota        1 1
LABEL=/boot1            /boot                   ext3    defaults        1 2
none                    /dev/pts                devpts  gid=5,mode=620  0 0
/dev/cdrom              /mnt/cdrom              iso9660 noauto,owner,ro 0 0
/dev/fd0                /mnt/floppy             auto    noauto,owner    0 0
none                    /proc                   proc    defaults        0 0
none                    /dev/shm                tmpfs   defaults        0 0
/dev/hda2               swap                    swap    defaults        0 0
--------------------------------end of output------------------------------
...ran just fine. :-)
--------------------------- cat /etc/raidtab ---------------------------
cat: /etc/raidtab: No such file or directory
--------------------------------end of output------------------------------
...ran with errors.
------------- mindi --makemountlist /tmp/mountlist.txt.test -------------
Your mountlist will look like this:-
Hang on...
/dev/hda3       /               ext3              19100
/dev/hda1       /boot           ext3                101
/dev/hda2       swap            swap                258
--------------------------------end of output------------------------------
...ran just fine. :-)
Done.
bkpinfo->tmpdir is being set to //tmp.mondo.5860
bkpinfo->scratchdir is being set to //mondo.scratch.26625
Invalid arg -- 700m
Switches:-
-O
-f -s
-i
--------------------------- cat /proc/cpuinfo ---------------------------
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model  : 8
model name : Pentium III (Coppermine)
stepping : 3
cpu MHz  : 596.928
cache size : 256 KB
physical id : 0
siblings : 1
fdiv_bug : no
hlt_bug  : no
f00f_bug : no
coma_bug : no
fpu  : yes
fpu_exception : yes
cpuid level : 2
wp  : yes
flags  : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr sse
bogomips : 1189.47
processor : 1
vendor_id : GenuineIntel
cpu family : 6
model  : 8
model name : Pentium III (Coppermine)
stepping : 3
cpu MHz  : 596.928
cache size : 256 KB
physical id : 0
siblings : 1
fdiv_bug : no
hlt_bug  : no
f00f_bug : no
coma_bug : no
fpu  : yes
fpu_exception : yes
cpuid level : 2
wp  : yes
flags  : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr sse
bogomips : 1192.75
--------------------------------end of output------------------------------
...ran just fine. :-)
------------------------------- uname -a -------------------------------
Linux gateway 2.4.20-18.7smp #1 SMP Thu May 29 07:49:23 EDT 2003 i686 unknown
--------------------------------end of output------------------------------
...ran just fine. :-)
--------------------------- cat /etc/*issue* ---------------------------
--------------------------------end of output------------------------------
...ran just fine. :-)
- rpm -q newt newt-devel slang slang-devel ncurses ncurses-devel glibc -
newt-0.50.18-04es
package newt-devel is not installed
slang-1.4.5-2
slang-devel-1.4.5-2
ncurses-5.2-26
package ncurses-devel is not installed
glibc-2.2.5-43
--------------------------------end of output------------------------------
...ran with errors.
Finished processing incoming params
Unregistering PID
--------------------------- umount /mnt/cdrom ---------------------------
umount: /mnt/cdrom: not mounted
--------------------------------end of output------------------------------
...ran with errors.