fdisk /dev/hda
mkfs.ext2 /dev/hda1
mkswap /dev/hda2
mkfs.ext3 /dev/hda3
mount -o rw,suid,dev /dev/hda3 /mnt
mkdir /mnt/boot
mount -o rw,suid,dev /dev/hda1 /mnt/boot
##############
mount /dev/hda3 /mnt/
mount /dev/hda1 /mnt/boot/
##################
debootstrap --exclude=dhcp3-client,dhcp3-common,ed,laptop-detect,libusb-0.1-4 --include=openssh-client,openssh-server,ssh,bzip2 etch /mnt http://ftp.de.debian.org/debian/
################
LANG=C chroot /mnt /bin/bash
mount -t proc proc /proc
cd /dev && MAKEDEV generic # create default devices
cat >> /etc/apt/sources.list << EOF
deb http://security.debian.org/ etch/updates main
deb http://ftp.de.debian.org/debian etch main non-free contrib
EOF
apt-get update
apt-get install chkrootkit console-common console-data console-tools debootstrap doc-debian doc-linux-text exim4 exim4-base exim4-config exim4-daemon-light ipopd iptables lynx net-tools nmap openssl mysql-server mysql-common mysql-client tcpdump unrar unzip time whois psmisc vim less lsof mailx libmail-spf-query-perl ftp
dpkg-reconfigure locales console-data # adjust locales to your needs
#apt-get install linux-headers-2.6-k7 linux-image-2.6-k7 lilo # install current kernel
#apt-get install apache2 apache2-doc apache2-utils apachetop apache2-mpm-worker apache2.2-common
#apt-get install lighttpd lighttpd-doc lighttpd-mod-cml lighttpd-mod-magnet lighttpd-mod-webdav
#apt-get install libmysql-java sun-java5-jdk java-common
/usr/share/doc/exim4-base/examples/exim-gencert
cat >> /etc/modules <<EOF
# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
#via-rhine #<- meine Netzwerkkarte
EOF
#########################
#Netzwerk
cat >> /etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain
# deine hosteinstellungen
EOF
cat >> /etc/resolv.conf <<EOF
nameserver 85.25.128.10
nameserver 217.172.191.10
nameserver 85.25.255.10
nameserver 217.172.164.64
EOF
echo hornox.net >/etc/hostname
cat >> /etc/network/interfaces << EOF
# Used by ifup(8) and ifdown(8). See the interfaces(5) manpage or
# /usr/share/doc/ifupdown/examples for more information.
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 217.172.188.219
netmask 255.255.255.0
network 217.172.188.0
broadcast 217.172.188.255
gateway 217.172.188.1
# up /sbin/route delete -net 217.172.188.0/24
EOF
tzconfig
cat >> /etc/fstab << EOF
/dev/hda1 /boot ext2 rw,nosuid,nodev 0 2
/dev/hda2 none swap sw 0 0
/dev/hda3 / ext3 errors=remount-ro 0 1
proc /proc proc defaults 0 0
EOF
passwd # set password of user root
update-initramfs -u -k `uname -r`
cat >> /etc/lilo.conf <<EOF
boot=/dev/hda1
root=/dev/hda3
delay=1
lba32
default=Etch
image=/boot/vmlinuz
label=Etch
initrd=/boot/initrd.img
append="noapic"
EOF
lilo.real -v -b /dev/hda
passwd
umount -a
exit
reboot