Setting Up A PXE Install Server For Multiple Linux Distributions On Debian Lenny - Page 4

Want to support HowtoForge? Become a subscriber!
 
Submitted by falko (Contact Author) (Forums) on Sun, 2009-05-24 18:15. ::

10 Add Mandriva 2009.1 Netboot (i386 and x86_64)

Next we download the Mandriva 2009.1 netboot files and put them in /var/lib/tftpboot/mandriva/2009.1 like this:

cd /var/lib/tftpboot
mkdir -p mandriva/2009.1/i386
cd mandriva/2009.1/i386
wget http://ftp-stud.fht-esslingen.de/pub/Mirrors/Mandrivalinux/official/2009.1/i586/isolinux/alt0/vmlinuz
wget http://ftp-stud.fht-esslingen.de/pub/Mirrors/Mandrivalinux/official/2009.1/i586/isolinux/alt0/all.rdz

cd /var/lib/tftpboot
mkdir -p mandriva/2009.1/x86_64
cd mandriva/2009.1/x86_64
wget http://ftp-stud.fht-esslingen.de/pub/Mirrors/Mandrivalinux/official/2009.1/x86_64/isolinux/alt0/vmlinuz
wget http://ftp-stud.fht-esslingen.de/pub/Mirrors/Mandrivalinux/official/2009.1/x86_64/isolinux/alt0/all.rdz

(You can download the files from any other Mandriva mirror as well. Use one that is close to you.)

Then add two Mandriva 2009.1LABEL stanzas to /var/lib/tftpboot/pxelinux.cfg/default. The file should now look like this:

vi /var/lib/tftpboot/pxelinux.cfg/default

DISPLAY boot.txt

default lenny_i386_install

label lenny_i386_install
        menu label ^Install
        menu default
        kernel debian/lenny/i386/linux
        append vga=normal initrd=debian/lenny/i386/initrd.gz -- quiet
label lenny_i386_expert
        menu label ^Expert install
        kernel debian/lenny/i386/linux
        append priority=low vga=normal initrd=debian/lenny/i386/initrd.gz --
label lenny_i386_rescue
        menu label ^Rescue mode
        kernel debian/lenny/i386/linux
        append vga=normal initrd=debian/lenny/i386/initrd.gz rescue/enable=true -- quiet
label lenny_i386_auto
        menu label ^Automated install
        kernel debian/lenny/i386/linux
        append auto=true priority=critical vga=normal initrd=debian/lenny/i386/initrd.gz -- quiet
label lenny_amd64_install
        menu label ^Install
        menu default
        kernel debian/lenny/x86_64/linux
        append vga=normal initrd=debian/lenny/x86_64/initrd.gz -- quiet
label lenny_amd64_expert
        menu label ^Expert install
        kernel debian/lenny/x86_64/linux
        append priority=low vga=normal initrd=debian/lenny/x86_64/initrd.gz --
label lenny_amd64_rescue
        menu label ^Rescue mode
        kernel debian/lenny/x86_64/linux
        append vga=normal initrd=debian/lenny/x86_64/initrd.gz rescue/enable=true -- quiet
label lenny_amd64_auto
        menu label ^Automated install
        kernel debian/lenny/x86_64/linux
        append auto=true priority=critical vga=normal initrd=debian/lenny/x86_64/initrd.gz -- quiet

label jaunty_i386_install
        menu label ^Install
        menu default
        kernel ubuntu/jaunty/i386/linux
        append vga=normal initrd=ubuntu/jaunty/i386/initrd.gz -- quiet
label jaunty_i386_cli
        menu label ^Command-line install
        kernel ubuntu/jaunty/i386/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false vga=normal initrd=ubuntu/jaunty/i386/initrd.gz -- quiet
label jaunty_i386_expert
        menu label ^Expert install
        kernel ubuntu/jaunty/i386/linux
        append priority=low vga=normal initrd=ubuntu/jaunty/i386/initrd.gz --
label jaunty_i386_cli-expert
        menu label Command-^line expert install
        kernel ubuntu/jaunty/i386/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false priority=low vga=normal initrd=ubuntu/jaunty/i386/initrd.gz --
label jaunty_i386_rescue
        menu label ^Rescue mode
        kernel ubuntu/jaunty/i386/linux
        append vga=normal initrd=ubuntu/jaunty/i386/initrd.gz rescue/enable=true -- quiet
label jaunty_amd64_install
        menu label ^Install
        menu default
        kernel ubuntu/jaunty/x86_64/linux
        append vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz -- quiet
label jaunty_amd64_cli
        menu label ^Command-line install
        kernel ubuntu/jaunty/x86_64/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz -- quiet
label jaunty_amd64_expert
        menu label ^Expert install
        kernel ubuntu/jaunty/x86_64/linux
        append priority=low vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz --
label jaunty_amd64_cli-expert
        menu label Command-^line expert install
        kernel ubuntu/jaunty/x86_64/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false priority=low vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz --
label jaunty_amd64_rescue
        menu label ^Rescue mode
        kernel ubuntu/jaunty/x86_64/linux
        append vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz rescue/enable=true -- quiet

LABEL fedora10_i386_linux
         kernel fedora/10/i386/vmlinuz
         append initrd=fedora/10/i386/initrd.img
LABEL fedora10_x86_64_linux
         kernel fedora/10/x86_64/vmlinuz
         append initrd=fedora/10/x86_64/initrd.img

LABEL centos5.3_i386_linux
         kernel centos/5.3/i386/vmlinuz
         append initrd=centos/5.3/i386/initrd.img
LABEL centos5.3_x86_64_linux
         kernel centos/5.3/x86_64/vmlinuz
         append initrd=centos/5.3/x86_64/initrd.img

LABEL mandriva2009.1_i386_linux
         kernel mandriva/2009.1/i386/vmlinuz
         append initrd=mandriva/2009.1/i386/all.rdz
LABEL mandriva2009.1_x86_64_linux
         kernel mandriva/2009.1/x86_64/vmlinuz
         append initrd=mandriva/2009.1/x86_64/all.rdz

prompt 1
timeout 0

Add the new installation options to /var/lib/tftpboot/boot.txt:

vi /var/lib/tftpboot/boot.txt

Available Boot Options:
=======================
lenny_i386_install     lenny_amd64_install      fedora10_i386_linux
lenny_i386_expert      lenny_amd64_expert       fedora10_x86_64_linux
lenny_i386_rescue      lenny_amd64_rescue       centos5.3_i386_linux
lenny_i386_auto        lenny_amd64_auto         centos5.3_x86_64_linux
jaunty_i386_install    jaunty_amd64_install     mandriva2009.1_i386_linux
jaunty_i386_cli        jaunty_amd64_cli         mandriva2009.1_x86_64_linux
jaunty_i386_expert     jaunty_amd64_expert
jaunty_i386_cli-expert jaunty_amd64_cli-expert
jaunty_i386_rescue     jaunty_amd64_rescue

When you install Mandriva 2009.1 over the network, the installer will ask you about the installation method. Select HTTP and then pick Mandriva 2009.1.

 

11 Add OpenSuSE 11.1 Netboot (i386 and x86_64)

Next we download the OpenSuSE 11.1 netboot files and put them in /var/lib/tftpboot/suse/11.1 like this:

cd /var/lib/tftpboot
mkdir -p suse/11.1/i386
cd suse/11.1/i386
wget http://ftp.uni-ulm.de/pub/mirrors/opensuse/distribution/11.1/repo/oss/boot/i386/loader/initrd
wget http://ftp.uni-ulm.de/pub/mirrors/opensuse/distribution/11.1/repo/oss/boot/i386/loader/linux

cd /var/lib/tftpboot
mkdir -p suse/11.1/x86_64
cd suse/11.1/x86_64
wget http://ftp.uni-ulm.de/pub/mirrors/opensuse/distribution/11.1/repo/oss/boot/x86_64/loader/initrd
wget http://ftp.uni-ulm.de/pub/mirrors/opensuse/distribution/11.1/repo/oss/boot/x86_64/loader/linux

(You can download the files from any other OpenSuSE mirror as well. Use one that is close to you.)

Then add two OpenSuSE 11.1LABEL stanzas to /var/lib/tftpboot/pxelinux.cfg/default. The file should now look like this:

vi /var/lib/tftpboot/pxelinux.cfg/default

DISPLAY boot.txt

default lenny_i386_install

label lenny_i386_install
        menu label ^Install
        menu default
        kernel debian/lenny/i386/linux
        append vga=normal initrd=debian/lenny/i386/initrd.gz -- quiet
label lenny_i386_expert
        menu label ^Expert install
        kernel debian/lenny/i386/linux
        append priority=low vga=normal initrd=debian/lenny/i386/initrd.gz --
label lenny_i386_rescue
        menu label ^Rescue mode
        kernel debian/lenny/i386/linux
        append vga=normal initrd=debian/lenny/i386/initrd.gz rescue/enable=true -- quiet
label lenny_i386_auto
        menu label ^Automated install
        kernel debian/lenny/i386/linux
        append auto=true priority=critical vga=normal initrd=debian/lenny/i386/initrd.gz -- quiet
label lenny_amd64_install
        menu label ^Install
        menu default
        kernel debian/lenny/x86_64/linux
        append vga=normal initrd=debian/lenny/x86_64/initrd.gz -- quiet
label lenny_amd64_expert
        menu label ^Expert install
        kernel debian/lenny/x86_64/linux
        append priority=low vga=normal initrd=debian/lenny/x86_64/initrd.gz --
label lenny_amd64_rescue
        menu label ^Rescue mode
        kernel debian/lenny/x86_64/linux
        append vga=normal initrd=debian/lenny/x86_64/initrd.gz rescue/enable=true -- quiet
label lenny_amd64_auto
        menu label ^Automated install
        kernel debian/lenny/x86_64/linux
        append auto=true priority=critical vga=normal initrd=debian/lenny/x86_64/initrd.gz -- quiet

label jaunty_i386_install
        menu label ^Install
        menu default
        kernel ubuntu/jaunty/i386/linux
        append vga=normal initrd=ubuntu/jaunty/i386/initrd.gz -- quiet
label jaunty_i386_cli
        menu label ^Command-line install
        kernel ubuntu/jaunty/i386/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false vga=normal initrd=ubuntu/jaunty/i386/initrd.gz -- quiet
label jaunty_i386_expert
        menu label ^Expert install
        kernel ubuntu/jaunty/i386/linux
        append priority=low vga=normal initrd=ubuntu/jaunty/i386/initrd.gz --
label jaunty_i386_cli-expert
        menu label Command-^line expert install
        kernel ubuntu/jaunty/i386/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false priority=low vga=normal initrd=ubuntu/jaunty/i386/initrd.gz --
label jaunty_i386_rescue
        menu label ^Rescue mode
        kernel ubuntu/jaunty/i386/linux
        append vga=normal initrd=ubuntu/jaunty/i386/initrd.gz rescue/enable=true -- quiet
label jaunty_amd64_install
        menu label ^Install
        menu default
        kernel ubuntu/jaunty/x86_64/linux
        append vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz -- quiet
label jaunty_amd64_cli
        menu label ^Command-line install
        kernel ubuntu/jaunty/x86_64/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz -- quiet
label jaunty_amd64_expert
        menu label ^Expert install
        kernel ubuntu/jaunty/x86_64/linux
        append priority=low vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz --
label jaunty_amd64_cli-expert
        menu label Command-^line expert install
        kernel ubuntu/jaunty/x86_64/linux
        append tasks=standard pkgsel/language-pack-patterns= pkgsel/install-language-support=false priority=low vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz --
label jaunty_amd64_rescue
        menu label ^Rescue mode
        kernel ubuntu/jaunty/x86_64/linux
        append vga=normal initrd=ubuntu/jaunty/x86_64/initrd.gz rescue/enable=true -- quiet

LABEL fedora10_i386_linux
         kernel fedora/10/i386/vmlinuz
         append initrd=fedora/10/i386/initrd.img
LABEL fedora10_x86_64_linux
         kernel fedora/10/x86_64/vmlinuz
         append initrd=fedora/10/x86_64/initrd.img

LABEL centos5.3_i386_linux
         kernel centos/5.3/i386/vmlinuz
         append initrd=centos/5.3/i386/initrd.img
LABEL centos5.3_x86_64_linux
         kernel centos/5.3/x86_64/vmlinuz
         append initrd=centos/5.3/x86_64/initrd.img

LABEL mandriva2009.1_i386_linux
         kernel mandriva/2009.1/i386/vmlinuz
         append initrd=mandriva/2009.1/i386/all.rdz
LABEL mandriva2009.1_x86_64_linux
         kernel mandriva/2009.1/x86_64/vmlinuz
         append initrd=mandriva/2009.1/x86_64/all.rdz

LABEL suse11.1_i386_linux
         kernel suse/11.1/i386/linux
         append initrd=suse/11.1/i386/initrd splash=silent showopts
LABEL suse11.1_x86_64_linux
         kernel suse/11.1/x86_64/linux
         append initrd=suse/11.1/x86_64/initrd splash=silent showopts

prompt 1
timeout 0

Add the new installation options to /var/lib/tftpboot/boot.txt:

vi /var/lib/tftpboot/boot.txt

Available Boot Options:
=======================
lenny_i386_install     lenny_amd64_install      fedora10_i386_linux
lenny_i386_expert      lenny_amd64_expert       fedora10_x86_64_linux
lenny_i386_rescue      lenny_amd64_rescue       centos5.3_i386_linux
lenny_i386_auto        lenny_amd64_auto         centos5.3_x86_64_linux
jaunty_i386_install    jaunty_amd64_install     mandriva2009.1_i386_linux
jaunty_i386_cli        jaunty_amd64_cli         mandriva2009.1_x86_64_linux
jaunty_i386_expert     jaunty_amd64_expert      suse11.1_i386_linux
jaunty_i386_cli-expert jaunty_amd64_cli-expert  suse11.1_x86_64_linux
jaunty_i386_rescue     jaunty_amd64_rescue

When you install OpenSuSE 11.1 over the network, the installer will ask you if CD 1 (?) is in the CD drive. As the purpose of our PXE server is not to use any CDs, select Back. As installation method, select HTTP and enter ftp.uni-ulm.de as the host, pub/mirrors/opensuse/distribution/11.1/repo/oss as the directory. Of course, you can use any other OpenSuSE mirror as well; use one that is close to you.

 

12 Boot Menu On The PXE Client

Now when you boot a computer from PXE, you should see the following boot menu:

Just type in the name of the distribution that you want to install (e.g. lenny_amd64_install).

 

13 Links


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by aclhkaclhk (registered user) on Wed, 2010-09-08 08:05.
the installation is via debian mirror site. could we setup a mirror using the download dvd image? i do not want to have large traffic via WAN or setup a real mirror site.
Submitted by Anonymous (not registered) on Tue, 2009-05-26 13:39.

This is great, but I don't see why anyone would maintain a PXE setup and mirror distros manually when rather sophisticated tools like mrepo and cobbler can do it for you, while also adding a host of neat features like automatic updates and inclusion of 3rd party software channels, etc?