pxe

warning: Creating default object from empty value in /data/web/1/000/027/003/273448/htdocs/panticz.de/modules/taxonomy/taxonomy.pages.inc on line 33.

IpFire direct installation from network (iPXE)

iPXE command
chain http://mirror1.ipfire.org/releases/ipfire-boot/latest/undionly.kpxe
chain http://mirror1.ipfire.org/releases/ipfire-boot/latest/gpxe.kpxe

Links
http://wiki.ipfire.org/de/installation/pxe
http://mirror1.ipfire.org/releases/ipfire-boot/latest/
http://planet.ipfire.org/post/introduction-to-boot-ipfire-org

Update Ubuntu PXE files

Update pxe configuration
wget http://installit.googlecode.com/hg/preseed/preseed.squeeze.amd64.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.squeeze.amd64.conf
wget http://installit.googlecode.com/hg/preseed/preseed.wheezy.amd64.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.wheezy.amd64.conf
wget http://installit.googlecode.com/hg/preseed/preseed.precise.i386.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.precise.i386.conf
wget http://installit.googlecode.com/hg/preseed/preseed.precise.amd64.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.precise.amd64.conf

Auto update Ubuntu PXE files

Update script
wget https://raw.githubusercontent.com/panticz/preseed/master/pxe/scripts/update.ubuntu.pxe.files.sh -O - | bash -

#!/bin/bash

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 oneiric precise quantal; 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

Create cronjob
wget https://raw.githubusercontent.com/panticz/preseed/master/pxe/scripts/update.ubuntu.pxe.files.cronjob -O - /etc/cron.d/update.ubuntu.pxe.files.cronjob; chmod a+x update.ubuntu.pxe.files.cronjob

#!/bin/sh

echo "update.ubuntu.pxe.files.cronjob $(date -I)" > /var/log/update.ubuntu.pxe.files.log

wget --quiet https://raw.github.com/panticz/preseed/master/pxe/scripts/update.ubuntu.pxe.files.sh -O - | bash -

Configure PXE
wget https://installit.googlecode.com/hg/preseed/preseed.precise.i386.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.precise.i386.conf
wget https://installit.googlecode.com/hg/preseed/preseed.precise.amd64.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.precise.amd64.conf
wget https://installit.googlecode.com/hg/preseed/preseed.quantal.i386.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.quantal.i386.conf
wget https://installit.googlecode.com/hg/preseed/preseed.quantal.amd64.conf -O /var/lib/tftpboot/pxelinux.cfg/preseed.quantal.amd64.conf

vi /var/lib/tftpboot/default
MENU SEPARATOR
MENU BEGIN
MENU TITLE + Preseed
MENU INCLUDE pxelinux.cfg/preseed.oneiric.i386.conf
MENU INCLUDE pxelinux.cfg/preseed.oneiric.amd64.conf
MENU INCLUDE pxelinux.cfg/preseed.precise.i386.conf
MENU INCLUDE pxelinux.cfg/preseed.precise.amd64.conf
MENU INCLUDE pxelinux.cfg/preseed.quantal.i386.conf
MENU INCLUDE pxelinux.cfg/preseed.quantal.amd64.conf

MENU SEPARATOR
LABEL Back
MENU EXIT
MENU END

Hardware Detection Tool (PXE boot)

# 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/

Install x2go PXE

# 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

XEN HVM PXE boot domU

# 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'
# vncdisplay=1   # uncomment this line to run on port 5901
EOF
 
# start domU
xm create pxe
 
# connect to domU over VNC
vinagre YOUR_DOMU_IP

Fileserver (Samba and DHCP)

#!/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,

Hitachi Feature Tool over PXE

#!/bin/bash
 
URL=http://www.hitachigst.com/hdd/support/downloads/ftool_215_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

Hitachi Drive Fitness Test over PXE

#!/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

PXE Net Boot

http://www.netboot.me/ - Boot anything, anywhere, anytime
http://ipxe.org/cmd - iPXE Settings reference
Syndicate content