If you had purchased your harddisk from Linuxvillage as part of a computer package, it would have been partition for you. The following documents the preparation procedures we use to reproduce consistent installs on multiple machines.
We have choosen a semi-automatic install for flexibility purposes but there are fully automatic install solution available. Such as FAI , Mondo or Bootcd etc.
Normally, if you use the installation disk from Debian (Etch), it will step you thorough the partitioning and formatting. But occassionally, you may want to skip all the extra steps in a traditional install for recovery purposes or multiple install etc. Here is how...
All material presented are licensed under The GNU Free Documentation License.
Warning: The instructions in this section will destroy all data on the hard disk. Use this information to reinstall or reproduce original installation.
Updated: 2006-11-19
Back to top
Backup each partition image with this command. Assuming it is the 1st SATA/SCSI drive, replace ?
with partition id.
# partimage -z1 -db save /dev/sda? partimagefile
Updated: 2006-11-19
Back to topThe partitioning on your harddisk is done the same way regardless of type or size. e.g. PATA, SATA drive or 80GB to 500GB+.
Your harddisk is partitioned for security and convenience reasons. It is much easier for backup and recovery and more secure to have separate partitions than to have only one partition. e.g. If all your partitions can be restore from installation disks, you only have to backup your home partition.
| Harddisk Partition Table | ||||||||
|---|---|---|---|---|---|---|---|---|
| Partition | Id | Label | Cyclinders | Size | Format | |||
| Primary (bootable) | 1 | / | 89 | 732.5 MB | ext3 | |||
| Extended | ||||||||
| 5 | usr | 1094 | 8.7GB | reiserfs | ||||
| 6 | var | 365 | 2.9GB | ext3 | ||||
| 7 | swap | 255 | 2.0 GB | swap | ||||
| 8 | tmp | 73 | 600 MB | ext2 | ||||
| 9 | home | remaining | remaining | reiserfs | ||||
# sfdisk /dev/sda << EOF ,89,L,* ,,5 ,,0 ,,0 ,1094,L, ,365,L, ,255,S, ,73,L, ,,L, EOFor simiply use this partition.data file and issue the following command to the appropriate drive.
# sfdisk /dev/sda < partition.datawhere
sdais the target device name.
To dump the partition information to a file do the following:
# sfdisk -d /dev/sdawhere
sdais the device name.
Updated: 2006-11-19
Back to topNow, time to format. If it is the 1st SATA/SCSI drive and has the same id as above. i.e. sda1, sda5, sda6, etc. Run the following commands to format as journalled file system.
# mke2fs -j -L / /dev/sda1Run the following command to format as non-journalled file system.
# mke2fs -j -L /var /dev/sda6
# mke2fs -L /tmp /dev/sda8Run the following command to initialize the swap partition.
# mkswap /dev/sda7Run the following command to initialize the Reiserfs journalled file system.
# mkreiserfs -ql /usr /dev/sda5
# mkreiserfs -ql /home /dev/sda9
Alternatively, you can use a script file like formatfs.sh to do the formats.
Issue the following command with sda
as your target drive.
# sh formatfs.sh sda
Updated: 2006-11-19
Back to topOnce you have the partition and format completed, you can now put the boot loader onto the drive. We use Grub not lilo.
# mkdir /mnt/debinst
# mount /mnt/debinst /dev/sda1
# grub-install --root-directory=/mnt/debinst /dev/sda
Updated: 2006-11-19
Back to topRestore each partition image with this command.
# partimage restore -eb /dev/sda? partimagefile
Updated: 2006-11-19
Back to top|
|
Warning: The procedures outlined in this section will destroy existing data - use with caution. |
We will be using GParted to create the partition and format the usb harddisk.
Select Applications->System Tools->GParted to start the application. Then select the proper device on the upper right hand corner.
Press the <New> button, and specifiy the partition size and file system format.
Press <+Add> when done.
Press <Apply> and the changes will be written to the disks.
If there are no errors, mount the usbdisk.
Updated: 2007-04-04
Linuxvillage currently does not support SATA RAID on its products, but here are some external links for further reading.
Basically, there are hardware RAID, software RAID and fake RAID.:
Hardware RAID doesn't need much user space programs except to monitor failures. They are very fast and transparent but less flexible then software RAID, because they usually requires specialized hardware.
Software RAID are more flexible because they will work with many combination of hardware and software but requires a lot more work on setup. NVIDIA's build in raid is a BIOS raid, they are fake RAIDs and falls under software raid because they rely heavily on userspace programs.
There are a few popular programs on software raids: mdadm and dmraid. dmraid is a device mapper and will work with NVIDIA's raid. mdadm has been around for a long time, supports different combination of software/hardware and reportedly has decent performance. The only draw back is the level of difficulty on installation.
We will stop here and let you explore on your own. Make sure to backup before you begin.
Updated: 2007-04-14
Back to top