Results 1 to 4 of 4

Thread: PXE booting Backtrack 4

  1. #1
    Just burned his ISO
    Join Date
    Feb 2010
    Posts
    1

    Default PXE booting Backtrack 4

    Hi,

    I am going to assume that you have a working dhcp and tftp server, that is already pxe booting something, if not there are many guides on the net to explain how to do these things. I used Debian Lenny with tftpd-hpa, so I will be focusing on these but it should be easy enough to adapt to any other distribution.

    You will only need the bt4-final.iso file, mount it and copy the whole contents into a directory called bt4 in your PXE root.

    Code:
    mount -t iso9660 -o loop bt4-final.iso /mnt
    mkdir -p [PXEROOT]/bt4
    cp -r /mnt/* [PXEROOT]/bt4/
    Look through [PXEROOT]/bt4/boot/grub/menu.lst and decide which one you want to boot, you can boot all of them you will just need to create multiple entries in the next step. I chose the following:

    Code:
    title                Start BackTrack FrameBuffer (1024x768)
    kernel                /boot/vmlinuz BOOT=casper boot=casper nopersistent rw quiet vga=0x317
    initrd                /boot/initrd.gz
    I am asuming that you have a working PXE boot server already so you should have the file [PXEROOT]/pxelinux.cfg/default, in which case just add the following lines:

    Code:
    LABEL bt4
            KERNEL bt4/boot/vmlinuz
            APPEND initrd=bt4/boot/initrd.gz BOOT=casper boot=casper nopersistent rw quiet vga=0x317 netboot=nfs nfsroot=[SERVERIP]:[PXEROOT]/bt4
    Here is an example full [PXEROOT]/pxelinux.cfg/default file that only boots bt4:

    Code:
    TIMEOUT 100
    DEFAULT bt4
    PROMPT 1
    DISPLAY /isolinux.msg
    LABEL bt4
            KERNEL bt4/boot/vmlinuz
            APPEND initrd=bt4/boot/initrd.gz BOOT=casper boot=casper nopersistent rw quiet vga=0x317 netboot=nfs nfsroot=[SERVERIP]:[PXEROOT]/bt4
    The main thing to note here is we are only appending 'netboot=nfs nfsroot=[SERVERIP]:[PXEROOT]/bt4' to the original line in the grub configuration. Create the file [PXEROOT]/isolinux.msg and put something like 'type bt4 to boot Backtrack 4 Final' in it.

    Now on Debian type the following command to install nfs, if you are using a different distribution google will be able to tell you how to install nfs:

    Code:
    apt-get install nfs-common nfs-kernel-server portmap
    Edit /etc/exports and add the line:

    Code:
    [PXEROOT]/bt4   [LOCALSUBNET](sync,no_root_squash,ro,no_subtree_check)
    You can restrict it to a certain IP but I used the whole subnet for convenience. Lastly type 'exportfs -a' and you should be ready to go! Just boot up a pc, boot from the network card, type bt4 at the prompt and alas bt4 over the network!

    Happy Hacking!

  2. #2
    Just burned his ISO
    Join Date
    Mar 2010
    Posts
    1

    Default Re: PXE booting Backtrack 4

    Thanks, this works for me! But there is one little thing to note:
    in /etc/exports you might hat to add the parameter "insecure", which just makes nfsd listen on a non-common port, then the line should look like this:
    Code:
    [PXEROOT]/bt4 192.168.0.0/24(sync,insecure,no_root_squash,ro,no_subtree_check)
    after that, if you haven't already:
    Code:
    exportfs -a
    /etc/init.d/portmap restart
    [EDIT]
    There seems to be an issue with the backtrack kernel, squashfs v4.0.0 or nfs on Backtrack 4 final.
    I tried to boot BT4f over PXE with the same options as above, exept "persistent" instead of "nopersistent". The kernel keeps reporting "end_request: I/O error, dev fd0, sector 0" after squashfs comes up, which seems to be well known since squashfs v3.x. My box has no floppy drive. If someone has a solution for this, please post it here!
    Last edited by bong0; 03-07-2010 at 11:13 PM. Reason: typo

  3. #3
    Just burned his ISO
    Join Date
    Jan 2010
    Posts
    11

    Default Re: PXE booting Backtrack 4

    Hi,
    First of all thanks for the tutorial. However, I am having an issue exporting the BT4 directory.
    So far, have a DHCP and TFTP running on BT4.
    Have edited the /etc/exports file, and saved the configuration.
    When executing
    Code:
    exportfs -a
    I receive the following error message
    Code:
    exportfs: Warning: /tftpboot/bt4 does not support NFS export
    Any help would be greatly appreciated!
    Thanks

  4. #4
    Just burned his ISO
    Join Date
    Apr 2010
    Posts
    1

    Default Re: PXE booting Backtrack 4

    Is there any way to get persistent changes working by using the nfs server as the storage location? I've tried using changes={nfs}:/{dir}, but to no avail. Any ideas? It boots up off the server fine apart from that.

Similar Threads

  1. booting problems
    By thesparteN1177 in forum Beginners Forum
    Replies: 1
    Last Post: 02-20-2010, 06:37 AM
  2. Trouble booting
    By jacklancer in forum Beginners Forum
    Replies: 6
    Last Post: 02-18-2010, 11:08 PM
  3. Trouble Booting
    By espkia in forum Beginners Forum
    Replies: 1
    Last Post: 02-06-2010, 06:00 PM
  4. Backtrack 4 Final- Booting Issue
    By basic in forum Beginners Forum
    Replies: 4
    Last Post: 01-23-2010, 10:24 PM
  5. Booting keeps failing. Help me?
    By UnknownError in forum Beginners Forum
    Replies: 4
    Last Post: 01-17-2010, 07:51 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •