Re: hd to hd copy?

1999-09-28 Thread Greg Starkes
Peter S Galbraith wrote:
 
 Andrew Hately wrote:
 
  Then from /mnt try something like
  # ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -
 
 Use the -p option on tar, or be prepared for lots of directories
 and files with improper permissions (mail problems, etc).

I just used cp -a instead of tar (less typing!) It's worked for me twice
so far, including last saturday. It's just too bad that I forgot to edit
/etc/lilo.conf before I wiped the old disk. ;) Rescue disks really come
in handy!

---
Greg Tower Starkes ([EMAIL PROTECTED])
Webmaster, Linuxberg (http://www.linuxberg.com/)

You can twist perceptions, reality won't budge.
-Neil Peart, Rush, Show Don't Tell


Re: hd to hd copy?

1999-09-28 Thread Andrew Hately
Seth R Arnold wrote:
 
 On Mon, Sep 27, 1999 at 10:27:31AM +0200, Andrew Hately wrote:
  # ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -
 xfp -

I forgot etc in the list.

Andrew
-- 
http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=45690


Re: hd to hd copy?

1999-09-28 Thread Will Lowe
  On Mon, Sep 27, 1999 at 10:27:31AM +0200, Andrew Hately wrote:
   # ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -
  xfp -
 
 I forgot etc in the list.

better:

rsync -av / target --exclude=/proc --exclude=anything else you don't
want to copy

Will

__
|Ever wonder why Windows doesn't come with the `uptime` command? |
--
|   [EMAIL PROTECTED] [EMAIL PROTECTED] [EMAIL PROTECTED] [EMAIL PROTECTED]  |
|   http://www.cis.udel.edu/~lowe/   |
|PGP Public Key:  http://www.cis.udel.edu/~lowe/index.html#pgpkey|
--



Re: hd to hd copy?

1999-09-27 Thread Andrew Hately
tf wrote:
 
 hey guys,
 
 I might put in a 6 gig drive in place of the 1.6 gig drive I'm using
 now.  My current installation works fine (its me thats broken!). is
 there a way that I can copy this hd to the new one?  I only have a swap
 and a root partition on this drive, and will probably want to partion
 the 6 gig drive further...
 
 or should I just bite the bullet, and do a fresh install?  (I am getting
 some good practice)

I was surprised by all the responses to this - I've done it a few times
without problems.

Get your rescue floppy disk out and keep it handy. Connect the new hard disk
somewhere on your machine somwhere other than /dev/hda. Run fdisk on it and
create the partition structure you want. Make the appropriate partition
bootable (first, generally). Reboot - its safer to always reboot after
running fdisk. Make the file systems. If any are large, make the swaps first
and swapon by hand as mke2fs eats memory. Mount your nominated root
partiton as /mnt. Go there. Create any directories where you will mount
other partitions on the same drive. Mount those other partitions. Create the
proc, mnt, tmp and cdrom directories too. Then from /mnt try something like
# ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -
This takes a while.
(If your linux image is lying around in / instead of being in /boot, you
need to copy that too.)
Change your future /etc/fstab (currently /mnt/etc/fstab) to mention your new
partitions, all relative to /dev/hda. Shut down. Reconnect the new disk as
/dev/hda, boot using the rescue floppy; rescue root=/dev/hda, run lilo,
shutdown, eject the floppy, boot.

However, a reinstall will probably bring less crud with it.

Andrew

http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=45690


Re: hd to hd copy?

1999-09-27 Thread Peter S Galbraith

Andrew Hately wrote:

 Then from /mnt try something like
 # ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -

Use the -p option on tar, or be prepared for lots of directories
and files with improper permissions (mail problems, etc).


Re: hd to hd copy?

1999-09-27 Thread Seth R Arnold
On Mon, Sep 27, 1999 at 10:27:31AM +0200, Andrew Hately wrote:
 # ( cd / ; tar cf - bin boot dev lib sbin usr var ) | tar xf -
xfp -

-- 
Seth Arnold | http://www.willamette.edu/~sarnold/
Hate spam? See http://maps.vix.com/rbl/ for help
Hi! I'm a .signature virus! Copy me into
your ~/.signature to help me spread!


hd to hd copy?

1999-09-26 Thread tf
hey guys,

I might put in a 6 gig drive in place of the 1.6 gig drive I'm using
now.  My current installation works fine (its me thats broken!). is
there a way that I can copy this hd to the new one?  I only have a swap
and a root partition on this drive, and will probably want to partion
the 6 gig drive further...

or should I just bite the bullet, and do a fresh install?  (I am getting
some good practice)
-- 


-t


Re: hd to hd copy?

1999-09-26 Thread Tom Pfeifer
The mini-HOWTO for hard drive upgrades covers this pretty well. You can
find it here:

http://metalab.unc.edu/mdw/HOWTO/mini/Hard-Disk-Upgrade.html

Tom


tf wrote:
 
 hey guys,
 
 I might put in a 6 gig drive in place of the 1.6 gig drive I'm using
 now.  My current installation works fine (its me thats broken!). is
 there a way that I can copy this hd to the new one?  I only have a swap
 and a root partition on this drive, and will probably want to partion
 the 6 gig drive further...
 
 or should I just bite the bullet, and do a fresh install?  (I am getting
 some good practice)
 --


Re: hd to hd copy?

1999-09-26 Thread Eric G . Miller
  There's been some discussion recently of how to move partitions
  around.  You might search the archives.  A fresh install is not
  required! One of the biggest gotchas to moving around your partitions
  will be modifying your /etc/fstab and LILO so you can reboot properly.
  First, you'll want to decide how to partition the new drive. Then do
  so. Then mount each partition in turn that you want to use and do
  something like the following (other methods work as well)
  
  $ mount -t ext2 /dev/hdb1 /mnt
  $ cd /var # for instance
  $ tar cf - . | (cd /mnt; tar xvpf -)
  
  Then edit your /etc/fstab to add something like:
  /dev/hdb1 /varext2defaults0   0

  If you move your / and /boot around you'll have to update your lilo
  configuration and then run /sbin/lilo.

  Suggested reading: mount, tar (or cpio), fstab, lilo, lilo.conf,
  fdisk, http://www.pathname.com/fhs

  You should probably do this in single user mode. Also, you might make
  your changes incrementally. For instance, try moving something
  non-critical like /usr/local and then make sure everything is working
  okay. Note, you need to maintain empty directories under / as your
  mount points.
-- 
+---++-+---++-+---++-+
|   YOUR AD HERE1.900.FOO.BARZ   |
+-+---++-+---++-+---++