Gentoo Setup

gentoo nox dolvm acpi=on psmouse.proto=imps
passwd
/etc/init.d/sshd start
/etc/init.d/ntp-client start

fdisk /dev/sda
vgscan
vgchange -a y
pvcreate /dev/???5
vgcreate vg /dev/???5

lvcreate -L2G -nccache vg
lvcreate -L1G -ndistfiles vg
lvcreate -L2G -nhome vg
lvcreate -L1G -nopt vg
lvcreate -L1G -npackages vg
lvcreate -L2G -ntmp vg
lvcreate -L5G -nusr vg
lvcreate -L2G -nvar vg

mkfs.ext3 /dev/sda1
mkfs.ext3 /dev/sda3

mkfs.ext3 /dev/vg/ccache
mkfs.ext3 /dev/vg/distfiles
#mkfs.ext3 /dev/vg/home
mkfs.ext3 /dev/vg/opt
mkfs.ext3 /dev/vg/packages
mkfs.ext3 /dev/vg/tmp
mkfs.ext3 /dev/vg/usr
mkfs.ext3 /dev/vg/var

mkswap /dev/sda2
swapon /dev/sda2

mount /dev/sda3 /mnt/gentoo/
cd /mnt/gentoo

mkdir boot ccache home opt tmp usr var

mount /dev/sda1 /mnt/gentoo/boot
mount /dev/vg/ccache /mnt/gentoo/ccache
mount /dev/vg/home /mnt/gentoo/home
mount /dev/vg/opt /mnt/gentoo/opt
mount /dev/vg/tmp /mnt/gentoo/tmp
mount /dev/vg/usr /mnt/gentoo/usr
mount /dev/vg/var /mnt/gentoo/var
chmod 1777 /mnt/gentoo/tmp

cd /mnt/gentoo
tar xvjpf /mnt/gentoo/home/stage3-i686-2008.0.tar.bz2
tar xvjf /mnt/gentoo/portage-latest.tar.bz2 -C /mnt/gentoo/usr

cp -L /etc/resolv.conf /mnt/gentoo/etc/
mount -t proc none /mnt/gentoo/proc
mount -o bind /dev /mnt/gentoo/dev

env -i HOME=$HOME TERM=$TERM chroot /mnt/gentoo /bin/bash
env-update
source /etc/profile
export PS1="(chroot) $PS1"

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License