# First, setup your disks to your liking. You can use whatever you want here, # RAID, LVM, etc... Remember your disk configuration because you'll need it # to configure grub, menu.lst and fstab. Using RAID, LVM, or others will require # more configuration than this guide covers. To keep it simple I'm using a # single disk. An example: $ fdisk /dev/sda $ mount /dev/sda3 /target $ mkdir /target/boot $ mount /dev/sda1 /target/boot # Depending on the host OS you're using, you may need to initialize the rpm db # on the host OS $ rpm --initdb # Use the following command to install the packages. I'll be addressing this # command as $rpm. $ rpm --root /target -i # Use your shell's tab completion to complete the package filenames. I # deliberatly left out the versions so these instructions apply to a wide range # of versions # Let's install some basics $rpm setup basesystem filesystem # Install bash first, this is needed for post-install scripts $rpm bash glibc glibc-common termcap libgcc tzdata mktemp libtermcap # Install some dependencies (this is mainly to keep the next command smaller) $rpm grep pcre libstdc++ info ncurses zlib gawk sed ethtool # Install the bulk of the system $rpm coreutils libselinux libacl libattr pam audit-libs cracklib-dicts \ cracklib libsepol mcstrans libcap chkconfig python db4 openssl readline \ bzip2-libs gdbm findutils krb5-libs initscripts util-linux popt udev MAKEDEV \ centos-release shadow-utils keyutils-libs iproute sysfsutils SysVinit \ net-tools module-init-tools e2fsprogs e2fsprogs-libs glib2 mingetty \ device-mapper sysklogd psmisc centos-release-notes procps libsysfs iputils # Install package manager $rpm rpm beecrypt elfutils-libelf rpm-libs sqlite # Install YUM $rpm yum python-elementtree rpm-python yum-metadata-parser python-sqlite \ expat libxml2 python-urlgrabber m2crypto python-iniparse # You may also want to install your favorite editor $rpm nano # This provides /root with some defaults, like color highlighting on `ls` $rpm rootfiles # Right now you have system which you can chroot to, so we can start setting up # the basics # Mount directories for chroot operation $ mount --bind /dev /target/dev $ mount -t proc none /target/proc $ mount -t sysfs none /target/sysfs $ chroot /target # This constructs /etc/shadow $ pwconv # Configure fstab $ nano -w /etc/fstab # Installing the kernel. Do this back outside the chroot in the host OS system $ exit $rpm kernel mkinitrd cpio device-mapper-multipath dmraid gzip kpartx lvm2 nash \ tar less device-mapper-event # Install the bootloader, grub. $rpm grub diffutils redhat-logos # Let's chroot again to configure our bootloader $ chroot /target # We start by configuring the bootloader. Open /boot/grub/menu.lst, and put the # following there <<