TurnKey Linux Virtual Appliance Library
Liraz Siri's picture

Usage scenarios

It shouldn't be difficult to build appliance images that can support PXE boot, but there are a lot of other features competing for our development time so when we get to that is a matter of priorities.

Can you describe your usage scenario? (That would be helpful)

s_digicom's picture

re: Usage scenario

I have 5-6 PC's - P III, 256 MB RAM, 10GB HDD, 10/100 LAN, no fdd, no cd, no usb boot - which I want to use for LAMP servers - 1 for home, 1 for work and etc. LAMP appliance is ideal for what I want. On CentOS 5.2 I have set a fully functional PXE enviroment and booting start normally, but stops when setup brings up LAN interface. Here is default file for PXE
default LAMP
timeout 50
prompt 0
ONERROR reboot

kernel images/TKLamp/casper/vmlinuz
append boot=casper initrd=images/TKLamp/casper/initrd.gz ramdisk_size=196000 ip=dhcp showmounts debug toram=196 netboot=nfs nfsroot= --

In log I can see that after interface is up, a new dhcp request is served, but after this moment there is no any other communication between PXE server and LAMP. I am not so experienced in Linux and it is quite possible to exists other simple solutions, but I want to use Turnkey LAMP, because your rails appliance is a great tool for me.
Liraz Siri's picture

A few resources...

We've never tested PXE booting our appliances, so you are in a highly experimental area and we have limited ability to help you (e.g., we don't even have a test environment setup for PXE just yet). However, before you give up, keep in mind that Ubuntu Live CDs have been made to boot via PXE before so it should be possible to do what you want:


We're very interested to hear more about your experience with this, especially if you manage to get it to work...

Good luck!

Liraz Siri's picture

Try disabling load to ram

Try removing toram=196 boot option...
s_digicom's picture

Confirmation: successfull installation

Dear Sir,
With this, I want to confirm that with your help, the LAMP appliance was successfully installed via PXE boot sequence.
I already use the resource, that you propose, but my errors was:
1. In configuration of PXE I used by mistake one more time /casper - which was already set from boot directive.
2. Removing toram= directive do the final job
Thank you very much.
Liraz Siri's picture

Thanks for sharing...

You're welcome, and thanks for sharing your experience!

One last thing, could you please post the exact configuration that worked so that other users have a known-good configuration to work with as reference?

s_digicom's picture

How to boot LAMP (any?) Turnkey appliance via PXE

I'll try to share my experience on how to boot/install the TurnKey LAMP appliance via PXE.

This is the first time I try to write something like this, plus I'm not a native English speaker, so please accept my apologies for any mistakes I make. I welcome any assistance to improve this material.

It is necessary to ensure working PXE and NFS servers. There is a lot of information online clarifying how can this be done.

Note that the PXE server and NFS server can actually be on different machines, but it's important they are both connected to the same network segment.

Create on your NFS server a shared folder. Ensure that the properties of this share are:

Extract the contents of .iso file in this share and check again that you have the following subdirectories:
Copy from the casper/ the vmlinuz and initrd.gz files into /tftpboot core directory.

If you have other systems you are booting with PXE, you can use an additional directory. For example:

For this to work you'll also need to set the correct paths in your configuration file:
kernel=OS_Images/LAMP/vmlinuz initrd=OS_Images/LAMP/initrd.gz
Here is the minimal configuration in /tftpboot/pxelinux.cfg/default file, which ensure correct environment for booting(installing) appliance:
default LAMP
prompt 0

        kernel vmlinuz
        append boot=casper initrd=initrd.gz ip=dhcp showmounts debug netboot=nfs nfsroot=xxx.xxx.xxx.xxx:/path/to/your/NFS/share --

Replace xxx.xxx.xxx.xxx with the real IP address of your NFS server and /path/to/your/NFS/share with your real shared folder.

With this configuration you will have live environment and you can use configuration console to take additional actions, like install.

If instead of a live environment you want to install, add the di-live noconfconsole
after boot options after the debug directive.

First, I used this configuration to install 2 LAMP servers, but now I find it very useful for live Rails development because it doesn't need to touch anything else on my laptop.

Once again I want to thank liraz for his advice and encouragement.

Liraz Siri's picture

This is great!

Thank you so much, this is very helpful!

I edited your post a bit to improve readability and we'll probably use your material later to create a new node in our community documentation section.

We'll also be looking into seeing if there is any way we can make setting up PXE boot of our appliances any easier from our end.

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)