You are not logged in.
Pages: 1
Crunchbang PXE Configuration
There are plenty of guides on setting up DHCP, TFTP, and NFS for booting linux with PXE. However, the documentation to write a pxelinux configuration for crunchbang is lacking. Here are hints for creating a pxelinux configuration file to boot Crunchbang with an NFS root. This is just information on the configuration file (pxelinux.cfg/default), not a howto for setting up pxelinux. I expect you have or can find out how to:
Setup a DHCP server and configure it to issue PXE TFTP info.
Setup a TFTP server to serve files.
Setup an NFS server to use as root.
In the following example, the tftp server and nfs server are the same host, established with this somewhat typical directory structure:
/tftpboot # base of TFTP server
/tftpboot/pxelinux.0 # boot file
/tftpboot/menu.c32 # com file for pretty menus
/tftpboot/pxelinux.cfg # configuration directory
/tftpboot/pxelinux.cfg/default # default configuration file
/tftpboot/crunchbang/statler # directory for statler
/tftpboot/crunchbang/statler/* # files extracted from install iso, same
# sub-directory structure
192.168.0.100:/tftpboot/crunchbang/statler
# NFS host ip and shared directory
Example pxelinux.cfg/default:
DEFAULT menu.c32
PROMPT 0
MENU TITLE PXE Boot
TIMEOUT 100
LABEL live
menu LABEL Crunchbang Statler Live
kernel crunchbang/statler/live/vmlinuz1
append initrd=crunchbang/statler/live/initrd1.img root=/dev/nfs netboot=nfs nfsroot=192.168.0.100:/tftpboot/crunchbang/statler ip=dhcp boot=live config quiet
The kernel and append directives are copied from the normal isolinux configuration. The file paths are changed to relative paths, and adjusted relative to /tftpboot. These kernel parameters are added:
root=/dev/nfs
netboot=nfs
nfsroot=192.168.0.100:/tftpboot/crunchbang/statler
ip=dhcp
To be accurate, "root=/dev/nfs" and "netboot=nfs" are old and new versions of the same argument for ubuntu. From unverified documentation, "root=/dev/nfs" is for ubuntu gutsy or older plus debian, and "netboot=nfs" is ubuntu hardy or newer. Lots of online examples include both. This is not a problem as the "wrong" specification gets ignored. All except "netboot" are documented at kernel.org, so should apply to *multiple* distros. Because I work with a lot of different distros, I choose to include both and not worry about remembering the distinction. Feel free to be more concise.
The nfsroot argument identifies the host and shared directory for NFS. The host MUST be an IP address, no host names, as the resolver is not running when root is mounted. NFS options can be tacked on the end using commas (and no spaces).
The directive ip=dhcp is a simplified network argument. There is long version if you need to assign an address, gateway, hostname, or use a specific interface or configuration method.
See http://www.kernel.org/doc/Documentation … fsroot.txt for the full details.
Hopefully, this can helps you pull together a pxelinux configuration to boot crunchbang.
Last edited by cpoakes (2012-05-19 23:35:59)
programming and administering unix since 1976 (BSD, System III, Xenix, System V, Linux)
Offline
I have bookmarked this. Thanks for posting it.
bootinfoscript - emacs primer - wireless problems- I ♥ #!
Offline
Pages: 1
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: acrobat