Create cronjob
wget http://www.panticz.de/sites/default/files/scripts/updateUbuntuPxeFiles.cronjob -O /etc/cron.daily/updateUbuntuPxeFiles
chmod a+x /etc/cron.daily/updateUbuntuPxeFiles
#!/bin/sh echo "updateUbuntuPxeFiles $(date -I)" > /tmp/updateUbuntuPxeFiles.log wget --quiet http://www.panticz.de/sites/default/files/scripts/updateUbuntuPxeFiles.sh -O - | bash -
Update script
wget http://www.panticz.de/sites/default/files/scripts/updateUbuntuPxeFiles.sh -O - | bash -
#!/bin/bash
#MIRROR=http://archive.ubuntu.com/ubuntu/dists/SUITE-proposed/main/installer-ARCH/current/images/netboot/ubuntu-installer/ARCH
MIRROR=http://archive.ubuntu.com/ubuntu/dists/SUITE/main/installer-ARCH/current/images/netboot/ubuntu-installer/ARCH
TFTPDIR=/var/lib/tftpboot/ubuntu/SUITE/ARCH
download() {
SUITE=$1
ARCH=$2
FILE=$3
echo -n " - $3"
MIRROR1=${MIRROR//SUITE/$SUITE}
MIRROR_TMP=${MIRROR1//ARCH/$ARCH}
TFTPDIR1=${TFTPDIR//SUITE/$SUITE}
TFTPDIR_TMP=${TFTPDIR1//ARCH/$ARCH}
if [ ! -d $TFTPDIR_TMP ]; then
mkdir -p $TFTPDIR_TMP
fi
wget --quiet $MIRROR_TMP/$FILE -O $TFTPDIR_TMP/$FILE
if [ $? == 0 ]; then
printf "%20s\n" "OK"
else
printf "%20s\n" "ERROR"
echo "$MIRROR_TMP/$FILE"
fi
}
echo "Update Ubuntu netboot files:"
for SUITE in lucid natty oneiric; do
echo "+ $SUITE"
for ARCH in i386 amd64; do
echo " + $ARCH"
for FILE in linux initrd.gz; do
download $SUITE $ARCH $FILE
done
done
done
# download image wget http://konilope.linuxeries.org/hdt/hdt-0_3_4.c32 -P /var/lib/tftpboot/ # create pxe config file cat <<EOF> /var/lib/tftpboot/pxelinux.cfg/hdt.conf LABEL linux MENU LABEL Hardware Detection Tool kernel hdt-0_3_4.c32 EOF # add to pxe default config echo "MENU INCLUDE pxelinux.cfg/hdt.conf" >> /var/lib/tftpboot/pxelinux.cfg/default # Links http://www.hdt-project.org/
# server http://www.panticz.de/node/370 # client #echo "deb http://x2go.obviously-nice.de/deb/ lenny main" >>/opt/x2gothinclient/etc/apt/sources.list cat <<EOF> /etc/apt/sources.list.d/x2go.list deb http://x2go.obviously-nice.de/deb/ lenny main EOF apt-get update apt-get install -y --force-yes x2goclient-gtk # install and configure pxe server apt-get install -y tftpd-hpa syslinux openbsd-inetd nfs-kernel-server debootstrap # configure pxe envirement cp /usr/lib/syslinux/pxelinux.0 /var/lib/tftpboot/ cp /usr/lib/syslinux/vesamenu.c32 /var/lib/tftpboot/ cp /usr/lib/sysl
# OPTIONAL: create hdd lvcreate --name pxe-disk --size 4G vg01 # xen config cat <<EOF> /etc/xen/pxe kernel='/usr/lib/xen-default/boot/hvmloader' builder='hvm' memory='512' name='pxe' device_model='/usr/lib/xen-default/bin/qemu-dm' boot='nc' #disk=['phy:/dev/vg01/pxe-disk,ioemu:hda,w'] vnc=1 vncviewer=1 vncpasswd="pxe" vif=['type=ioemu,bridge=eth0,mac=00:00:aa:bb:44:ae'] usbdevice='tablet' vnclisten='0.0.0.0' EOF # start domU xm create pxe # connect to domU over VNC vinagre YOUR_DOMU_IP
#!/bin/bash # set domU name DOMAIN_NAME=srv # install vm xen-create-image --hostname=$DOMAIN_NAME --dhcp --mac=00:11:cc:ab:cd:ef \ --lvm=vg01 --dist=jaunty --mirror=http://archive.ubuntu.com/ubuntu/ --size=4Gb --memory=1Gb --swap=1Gb # rename config file mv /etc/xen/${DOMAIN_NAME}.cfg /etc/xen/${DOMAIN_NAME} # add to autostart ln -s /etc/xen/${DOMAIN_NAME} /etc/xen/auto # create lvm for home lvcreate --name ${DOMAIN_NAME}-media --size 200G vg01 mkfs.ext3 /dev/vg01/${DOMAIN_NAME}-media # configure domU vi /etc/xen/${DOMAIN_NAME} (add) 'phy:/dev/vg01/srv-media,xvda3,
#!/bin/bash URL=http://www.hitachigst.com/hdd/support/downloads/ftool_211_install.IMG # download dft image wget ${URL} -O /var/lib/tftpboot/hitachi_ftool.img # create config for pxe boot cat <<EOF> /var/lib/tftpboot/pxelinux.cfg/hitachi_ftool.cfg LABEL linux MENU LABEL Hitachi Feature Tool kernel memdisk append initrd=hitachi_ftool.img EOF # add config to default config echo "MENU INCLUDE pxelinux.cfg/hitachi_ftool.cfg" >> /var/lib/tftpboot/pxelinux.cfg/default # LINKS # http://www.hitachigst.com/hdd/support/download.htm
#!/bin/bash URL=http://www.hitachigst.com/hdd/support/downloads/dft32_v414_b00_install.IMG # download dft image wget ${URL} -O /var/lib/tftpboot/hitachi_dtf.img # create config for pxe boot cat <<EOF> /var/lib/tftpboot/pxelinux.cfg/hitachi_dtf.cfg LABEL linux MENU LABEL Hitachi Drive Fitness Test kernel memdisk append initrd=hitachi_dtf.img EOF # add config to default config echo "MENU INCLUDE pxelinux.cfg/hitachi_dtf.cfg" >> /var/lib/tftpboot/pxelinux.cfg/default # LINKS # http://www.hitachigst.com/hdd/support/download.htm
#!/bin/bash # last version # http://dl.dropbox.com/u/4170695/scripts/mkTSClient.sh # http://ubuntuforums.org/showpost.php?p=5175091&postcount=27 # version: 2009-09-09 # todo # configure locales # configure hostname # clean up "fglrx" # check install_lirc # umount all from chroot envirement, rm: Entfernen von Verzeichnis „$HOME/xbmc-XXX-livecd-hardy-i386/chroot/lib/modules/2.6.24-21-generic/volatile“ nicht möglich: Device or resource busy # parameter # architecture: i386, amd64 ARCH=i386 # distribution: hardy, intrepid, jaunty, karmic DISTRIB_CODENAME=karmic # chec
# install kvm sudo apt-get install -y qemu kvm ubuntu-vm-builder # install PXE boot ROM apt-get install kvm-pxe http://rom-o-matic.net/etherboot/etherboot-git/etherboot.git/contrib/rom-o-matic/ 1. NIC/ROM type: e1000:e1000-0x1026-82545gm-copper -- [8086,1026] 2. ROM output format: Binary ROM Image(.zrom) 3. Configure, ASK_BOOT: -1 4.