[finnix] Sneaky with PXE boot

Joel Stiller joelstiller at gmail.com
Fri Dec 4 13:21:51 PST 2009


I'm not sure what's up, but my messages keep getting blanked out or
chopped up. I'm new to this whole mailing list thing (I'm used to
forums), so pardon me for posting like a moron.

Leonid - Actually I got it working this morning. Turns out the syntax
in my pxe boot options file was incorrect. So let me go over what I
did, and hopefully it won't get obliterated.

Step one - You will need to mount the minirt image to get access to
it. Within that image create a director called 'image'.
Step two - Copy the contents of the 'FINNIX' directory on the iso to
'image' recursively.
Step three - modify the 'init' script located in the minirt image to
contain the following.

checkbootparam nodma && NODMA="yes"  #<- This is just a point of
reference, do not copy.
checkbootparam frominit && FROMINIT="yes" # Added this line.
ROOTWRITE="ro"  #<- This is just a point of reference, do not copy.

# We will need the busybox binaries during shutdown   #<- This is just
a point of reference, do not copy.
cp -a /bin/* /ramdisk/busybin/ #<- This is just a point of reference,
do not copy.
echo -n "done${CRE}" #<- This is just a point of reference, do not copy.

#COPY DISK TO /ramdisk/cdrom  #<Added from here
if [ -n "$FROMINIT" ];then
cp -af /image/* /ramdisk/cdrom/
fi   #<To here

if [ -n "${NODMA}" ]; then #<- This is just a point of reference, do not copy.

# START FROMINIT CODE #<-Added from here
if [ -n "${FROMINIT}" ]; then
 FOUND_FINNIX="yes"
 FINNIX_CLOOP="/dev/ram0"
fi <-To here

# BEGIN SQUASHROOT SKIP  #<- This is just a point of reference, do not copy.

This is part of the mountblindly() sub
 if [ -n "$FROMINIT" ]; then
    FOUND_FINNIX="yes"
   fi
  done  #<- This is just a point of reference, do not copy.
 } #<- This is just a point of reference, do not copy. End of mountblindly()


Step 4 - Repackage the minirt file. Here is the command executed from
within your mounted minirt
find . | cpio --verbose -o -H newc | gzip -9 >../minirt.pxe

Step 5 - Copy the "finnix" kernel and your minirt.pxe image to your
pxe boot server.

Step 6 - Boot! Below is a copy of my working config file.

default finnix
label finnix
   kernel finnix
   append initrd=minirt.pxe netwait=10 dhcptimeout=120 toram frominit quiet

-Joel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pxeboot.init
Type: application/octet-stream
Size: 21534 bytes
Desc: not available
URL: <http://lists.colobox.com/pipermail/finnix/attachments/20091204/3835078c/attachment.obj>


More information about the finnix mailing list