Linux Debian support - How to clone/replicate Ubuntu systems?

This is Interesting: Free IT Magazines  
Home > Archive > Linux Debian support > February 2006 > How to clone/replicate Ubuntu systems?





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author How to clone/replicate Ubuntu systems?
Alfred

2006-01-20, 5:48 pm

We are trying to clone an IBM kiosk (model # 4835-152) that has Ubuntu
5.10 on it. We have Ghost installed and were able to successfully make
an image and send it to the Ghost server. When I expand it on the
server, I see each directory and it all works well there. But when I
try to push this image to multiple kiosks we have tried (each, the same
model number), each new system reboots and looks like this when done:

GRUB
_


It's hung. My guess is kernel panic.

1) Do you know what we need to do in Ghost to get this to work?

2) If not, then can you suggest how to clone Ubuntu systems?

John Hasler

2006-01-20, 5:48 pm

Alfred writes:
> GRUB
> _



> It's hung. My guess is kernel panic.


Your guess is wrong. Ghost has garbled the Grub bootloader. Info grub.

> Do you know what we need to do in Ghost to get this to work?


Sounds like a question for Symantec support. Ghost doesn't run on Linux.

> If not, then can you suggest how to clone Ubuntu systems?


Google cloning+kiosk+linux.
--
John Hasler
Alfred

2006-01-20, 5:48 pm

John Hasler wrote:
> Google cloning+kiosk+linux.


I think I need to do this:

1) Use apt-get to install Apache web server.
2) Use some sort of combo of tar, gzip, and/or dd to save an image and
place it on the web server.
3) On the other system, install Linux so that I get to at least a
command prompt.
4) From this new system, use wget to retrieve the image from the web
server on the other system.
5) Use tar, gzip, and/or dd to restore the image over and on top the
other kiosk disk.

ray

2006-01-20, 5:48 pm

On Fri, 20 Jan 2006 10:40:43 -0800, Alfred wrote:

> John Hasler wrote:
>
> I think I need to do this:
>
> 1) Use apt-get to install Apache web server.
> 2) Use some sort of combo of tar, gzip, and/or dd to save an image and
> place it on the web server.
> 3) On the other system, install Linux so that I get to at least a
> command prompt.
> 4) From this new system, use wget to retrieve the image from the web
> server on the other system.
> 5) Use tar, gzip, and/or dd to restore the image over and on top the
> other kiosk disk.


From your description, I think it should be possible to take the systems
you have made, boot from a live CD and reinstall GRUB.

Michael Paoli

2006-01-22, 5:50 pm

Alfred wrote:
> We are trying to clone an IBM kiosk (model # 4835-152) that has Ubuntu
> 5.10 on it. We have Ghost installed and were able to successfully make
> an image and send it to the Ghost server. When I expand it on the
> server, I see each directory and it all works well there. But when I
> try to push this image to multiple kiosks we have tried (each, the same
> model number), each new system reboots and looks like this when done:
>
> GRUB
> _
>
>
> It's hung. My guess is kernel panic.
> 1) Do you know what we need to do in Ghost to get this to work?

I'd think you'd want alt.utilities.norton.ghost
> 2) If not, then can you suggest how to clone Ubuntu systems?


If you want quite identical cloning, you can use standard utilities
such as:
dd(1)
ssh(1)
gzip(1)
bzip2(1)

E.g.:
On the "master", for better compression/bandwidth results:
o null wipe free file system space (e.g:
for tmp in $filesystem_mountpoints
do
(
cd "$tmp" && {
dd if=/dev/zero of=.null.wipe.$$
bs=$filesystem_block_size
rm .null.wipe.$$
}
)
done; unset tmp
Then remount these file systems read-only (ro) or unmount them.
o Temporarily deactivate any swap (leave it configured so it will
activate at (re)boot, but don't use it presently), then null wipe it
(similar to above) then reformat it.
o Null wipe any unused disk space (don't clobber your MBR or partition
table).
o Boot from CD (or DVD or network), or boot from master hard drive(s)
but only with file systems only mounted ro and without activating
swap (this can generally be done with suitable boot options and
careful manual initialization).
o Initialize network, or make other suitable connection(s), then suck
the image via dd and compress it with gzip -9 or bzip2 -9, and save
it to as a "master image" file on some suitable server or media.
E.g:
dd if=/dev/hda bs=512 |
bzip2 -9 |
ssh -x -l $user $repository.server \
'umask 077 &&
cd '"$repository_directory"' &&
exec cat >4835-152.golden.'`date -I`.bz2
That should leave you a fairly well compressed tight little image.
You should also verify it, e.g. do md5sum and/or sha-1 hashes on it,
to make sure what you saved matches your disk image on the master,
e.g., on the master:
dd if=/dev/hda bs=512 | md5sum
and on the $repository.server:
bzip2 -d <$repository_file | md5sum
and make sure they match.
o To install, you essentially reverse the process - except the target
can't be using the local hard drive (must not be using file systems
or swap, etc., from there), so you'd typically boot it from network,
CD-ROM, etc. To install, on the repository server, or from wherever
you have that compressed image available (could even be presented
via NFS to the target):
bzip2 -d <$repository_file |
# and you pipe that to, on the target:
dd of=/dev/hda bs=512

That's basically it. You may want to tweak some things so they're not
too identical (e.g. change file system and volume identifiers, host
keys, wipe earlier log history, etc.) ... preferably you can work some
of those changes into your master image itself - and the remainder can
be done as a script to tweak things after the image is laid down.

Walter Mitty

2006-02-04, 8:45 pm

"John" risked the wrath of Usenet weenies mastering
mommies computer when he ventured forth on 2006-01-20, commmitted
his life to the whims of Google, and spluttered:

> Alfred writes:
>
>
>
> Your guess is wrong. Ghost has garbled the Grub bootloader. Info grub.
>
>
> Sounds like a question for Symantec support. Ghost doesn't run on Linux.
>
>
> Google cloning+kiosk+linux.


Interestingly enough the replies seemt to talk about Ghost (ms) and
the first result is "Linux Should Be Easier To Clone".

Which article would you recommend?

--
Snow White's dwarfs become gnomes
-- http://news.bbc.co.uk/1/hi/england/kent/4349726.stm
The world has gone mad.
SINNER

2006-02-06, 5:48 pm

* John Hasler wrote in alt.os.linux.debian:

> Alfred writes:
>
>
>
> Your guess is wrong. Ghost has garbled the Grub bootloader. Info grub.
>
>
> Sounds like a question for Symantec support. Ghost doesn't run on Linux.


Maybe not Symantec's Ghost, but Ghost For Linux runs fine.

http://freshmeat.net/projects/g4l

That said, while SYmantecs Ghost may not run on linux, it is certainly
compatible and can be used to accomplish this simple task.

http://service1.symantec.com/SUPPOR...=&osv=&osv_lvl=

--
David
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com