A few weeks ago, at the same time I bought that 2 GB memory key, I bought a Maxim “200 GB” drive. The 200 GB is in quotes because the drive formats out to exactly 196,907,134,976 bits, which is several bits short of a load even if you believe that 1 GB = 109 bytes. (Actually, of course, 1 GB = 230 bytes.)
So I have this big-but-not-200 GB drive that I want to a) install, b) reformat as an ext3 file system, and c) make my /home directory.
Installing the drive wasn't too much of a problem. It went into the second CD drive bay. Not where it was supposed to go, but then I didn't have a lot of choice. Ideally, the drive should go on the same cable as the original hard drive. Unfortunately, drive cables are only 18 inches, max, and the geometry of the situation is that the second drive would have to be duct-taped to the case to make that work. So instead of hooking up the second drive in series with the first drive, I'm hooking it up in series with the DVD-drive. I suspect that this could cause a performance hit when I'm writing DVDs and CDs. I also suspect that I've just voided the warranty on this Dell, but that's OK, because the machine is now almost four years old, and I think the warranty has long expired.
The other problem with doing things this way is that the drive and drive-bay screw holes are mismatched, so the drive can either be screwed in and lean at an angle, or just sit loosely on the shelf. Since this is a floor-based tower model, I just let the drive sit there. This may cause problems if we ever get an earthquake, but then there's still the duct-tape option.
Anyway, the drive is installed, however precariously. So how do I save it from its Windows formating and convert it into a real disk drive? Follow:
- First I have to find the thing, meaning, where does the computer think it is. Boot the system, and up comes the drive. Open an xterm, or go straight to the console, and issue the extremely useful command:
This gives you a complete description of your hardware. Examining the output, I see that there is a Maxtor 186 (real) GB hard disk at /dev/hdd. (If I'd hooked up the drive correctly it would have been at /dev/hdb.)
- I got the formating directions from Jeff Hunter. I'll just list the steps I took, and refer you to his page for more information:
$ su (become root)
# fdisk /dev/hdd (partition the disk. Use the defaults on Hunter's page)
# mkfs.ext3 -b 4096 /dev/hdd1 (create an ext3 file system)
- Now add a new line to /etc/fstab:
/dev/hdd1 /home2 ext3 defaults 0 2
- Create a mount point for it:
# mkdir /home2
- Mount it:
# mount /home2
- Copy the files from /home to /home2:
# cp -r /home/mike /home2
(do this for every user directory in /home)
- The owner of all the files you just copied is root. Fix that:
# chown -r mike:mike /home2/mike
(and repeat as needed)
- Now I want to perform a bit of magic. I want to make /home2 my /home directory. Since I'm not absolutely positively sure this will all work, I'll rename the old /home to /home2 for now. Later I'll delete those files and use that partition for scratch, or another Linux distribution (maybe a “real” one).
Right now my /etc/fstab file has the lines:
/dev/hda3 /home ext3 defaults 0 2 /dev/hdd1 /home2 ext3 defaults 0 2I'm going to edit this so it reads:
/dev/hda3 /home2 ext3 defaults 0 2 /dev/hdd1 /home ext3 defaults 0 2
- I suppose you could then do:
# umount /home
# umount /home2
# mount /home
# mount /home2
but I just hit Ctrl-Alt-Delete and rebooted to get the OS to read the new mount points.
So far no stability issues, no power problems, and a nice big drive.