Re: [Nolug] Drive transfer advice wanted

From: Kevin Kreamer <kevin_at_kreamer.org>
Date: Fri, 11 Mar 2005 19:13:44 -0600
Message-ID: <42324248.60700@kreamer.org>

Alex McKenzie wrote:
> Ok here's my setup:
>
> Filesystem 1k-blocks Used Available Use% Mounted on
> /dev/hda2 8040280 7461496 578784 93% /
> /dev/hdb2 33494348 33490220 4128 100% /mnt/mp3
> /dev/hdb3 33558752 27204304 6354448 82% /mnt/backup
> /dev/hdb4 16506276 15443652 1062624 94% /mnt/crap
> /dev/hda3 23641648 19797980 3843668 84% /mnt/wine
> /dev/hdb1 33551520 33523456 28064 100% /mnt/newd
>
>
> hda needs to go away, and it's got / as you can see. I would like to
> transfer that as-is (with links intact, etc.) to hdb, into either
> /mnt/mp3 or /mnt/newd and have it be bootable, etc. What's the best way
> to do this? I don't trust cp as it's lost links and screws up the file
> times, which is important to keep as is. And I'm scared to use dd
> because I don't understand what it does from reading the man page :P

I'd think dd is much too low-level for this sort of thing. But, unless
I'm missing something, you are going to need another drive anyway,
because you don't seem to have enough space to copy into.

In any case, cp -a has generally worked for me. On the other hand, the
traditional Unix approach is something like:

tar / --one-file-system cf - | (cd /mnt/newdrive && tar xf -)

> Also I've been using lilo to do it's thing, so I need to get it onto
> hdb's bootblock. That would be the last thing, no?

Yes, that has to happen after you get the files copied. In my
experience, though, lilo doesn't handle renaming drives very well. I
think that the solution is to use a UUID to reference the drive, but
it's been a while since I've even used lilo. You might look into using
grub, instead.

> Finally, the machine has been hanging with no warnings, so this needs to
> be taken into account. Thanks in advance.

This is no good. I'd look into this first, before seeing about
switching around drives (unless this is the reason that hda needs to go
away).

Hope this helps,
Kevin

___________________
Nolug mailing list
nolug@nolug.org
Received on 03/12/05

This archive was generated by hypermail 2.2.0 : 12/19/08 EST