How to install PNP LTSP on Ubuntu Mate 14.04 and all subsequent versions



Steve Cook - 16/008/2016)

How to install PNP LTSP on Ubuntu Mate

Since discovering Ubuntu Mate, I am reminded of why I came to Linux several years ago. For this reason, I am basing this instructional on Ubuntu Mate. Having said that, it will likely work for any other Ubuntu Variant. I should also say, I am a reasonablly knowledgable user of Linix, but am by no means a power user. Thus, the following tutorial has been written by me for people like me. There may well be other, more efficient (and certainly more knowledgable) methods of installation. But, this one works, and that's good enough for me and so I am putting it out there for anyone else who may find it useful.

What is LTSP?

Linux Terminal Server Project (LTSP) is a free and open source terminal server for Linux that allows many people to simultaneously use the same computer. Applications run on the server with a terminal known as a thin client (also known as an X terminal) handling input and output. However, it is also possible to run a client in “fat” mode. This is where, although the image is still stored on the server and is still fully served up to the client when the client boots up, much of the work of the client is then subsequently done by itself during a given user session. This leads to more efficient use of network resources and, in the case of a user wishing to experience high-quality, full-screen, streaming video on the client, a fat client set-up is essential.

The main advantages of LTSP over other forms of networking are both cost and administration. In terms of cost, it allows for the continued use of machines that would otherwise be deemed to be too old to run the latest software and/or operating systems (because, in the case of thin clients, the vast majority of the work in any given user sessions is carried out by the server). However, given the above, it should be obvious that the server needs to be as modern and powerful as budgetary constraints will allow for. In terms of administration, given that the client image is stored in a single location on the server, updating network software is vastly less cumbersome than having to update many copies of that image on each individual client machine's hard drive as would be the case with more conventional network set-ups.

As has already been alluded to, the traditional way of installing LTSP has been to create a client image on the server that stands quite independent of the server installation itself. That is to say, software can be installed on the LTSP image by a process called “chroot”. Thus leading to a client image which may be quite different in terms of functionality to the server image. If you know what you are doing, this is certainly a very versatile method of installation. I have included a link to Ubuntu's main LTSP page where you can follow the instructions and also the links contained therein for more details on this traditional LTSP set-up:

The above method is also, however, in my experience prone to many pitfalls unless you have a fairly high skill set in Linux administration generally and in Linux networking in particular. Although I have previously installed LTSP in the traditional way, for all of the reasons I have outlined, I have elected to make the following instructional for new version of LTSP, which is called PNP LTSP and which is now the only version of LTSP I use myself.

What is PNP LTSP?

PNP, in the context of this instructional stands for “plug n' play”. This method of installation and maintenance is vastly easier than the traditional method. But at some cost of versatility. Though, in my view that cost is minimal and is largely mitigatable in any event and so the benefits far outweigh the costs.

In terms of those costs, for example, unless you can guarantee that all clients will have 64 bit (amd64) architecture, you will need to install the 32 bit (i386) version of Ubuntu Mate on the server. The reason being that in PNP LTSP, the client image is directly built from the server installation. Thus, if you have a server that has a 64 bit physical architecture and is using the 64 bit version of Ubuntu Mate (and so any LTSP image that will be built from it will also be 64 bit), any client whose physical architecture is 32 bit will not load the image. On the other hand, all clients, whether their physical architecture be 64 bit or 32 bit, will load the 32 bit image. However, you should not be overly concerned about installing 32 bit Ubuntu Mate on a server whose physical architecture is 64 bit since the latest version of Ubuntu 32 bit is able to utilize RAM up to 64 Gb in any event. Also, a huge benefit of the image being directly derived from the server installation is when is comes to installation of software. That is to say, you only need to install it once on the server. Then, every time you update the client image, it simply copies whatever it finds on the server. Having said that, an administrator may wish to make some programs unavailable for client users. This is easily achieved via entries in a config file where disallowed program details are stored (more on this later), Thus, the client image will not include them in its build.

Another advantage of using PNP LTSP is that the use of fat clients/thin clients is done with a single image whereby if the client has enough resources of its own , the sever will automatically serve up a fat version of that image to it. But, if its resource are low, then the server will automatically detect this and serve up a thin version of the image instead. Furthermore, given that the image is directly derived from the server installation, administrators no longer have to go through the rigmarole of having to install a similar desktop environment on the client image as that which appears on the server (the traditional default desktop for an Ubuntu LTSP client image is Unity). Instead, the client image simply matches whatever the server has installed, including its desktop environment.

When I said this method of LTSP was easier than the traditional method, I wasn't joking!

Installation of PNP LTSP


The following instructions are based on my own preferred set-up and should be easily replicated. It's assumed that you've installed Ubuntu Mate 14.04 LTS 32 bit without LTSP, e.g. using the desktop CD. Also, this installation of LTSP will only require one Ethernet card instead of two as is the case with a typical LTSP installation. This installation is also unusual in that it makes use of standard electrical network ring mains (your 240volt plug sockets are part of this ring). This ring mains, via the use of power line adapters (allowing the ring mains wires to be used as an Ethernet cable) will be used to both connect the server to the internet (via a router connected to the internet) and also provide the means by which to transmit the LTSP image to client machines. For clarity, this physical arrangement of network components should be as follows:

I have only shown one client on the above diagram. However, you may connect as may clients as your plug sockets and server capacity allows for. Also, you should note that the power line adapters will not work if straddled over two or more plug rings. That is to say, you will typically find that different floors of a building may utilise separate plug rings. In which case, you should utilise only the one ring for the LTSP network and extend it to the other floor in order to have clients on that other floor as well. However, you do not actually need to use power-line adapters (I just use them because I find them fantastically convenient). In which case, you would need to connect the components up in the following way using standard ethernet cabling, meaning you can simply site your clients where you wish with no other regard:

I should also note, there is no need to actually have any clients connected at installation (the server, of course, must be connected at installation). I have just included them in the diagram for completeness of understanding of the architecture of a working LTSP network. All clients will get their internet access directly from the internet router via the same wired connection they are using for the LTSP network. It is this direct internet connection , rather than having the internet served up second hand from the server, that makes for excellent, full-screen streaming media on the clients, as compared to more traditional methods of LTSP networking. Indeed, this is my primary reason for using PNP LTSP.

As suggested earlier, you should at this point install on your server any programs that you want to make available to your clients.


You will need to add a repository for this particular version of LTSP. Also, for the duration of the initial installation of the requisite LTSP software, you will need to temporarily disable the Ubuntu network manager. In order to do the above, execute the following commands in a terminal:

sudo service network-manager stop

sudo add-apt-repository --yes

Then, execute the following commands in the terminal:

sudo -i
apt-get update
apt-get --yes --install-recommends install dnsmasq ltsp-server-standalone ltsp-client ldm-ubuntu-theme
ltsp-config dnsmasq
echo 'IPAPPEND=3' >> /etc/ltsp/update-kernels.conf

Generating the client image

After the initial installation, and also any time that you have server updates (new software etc) that you want to push to your clients, you need to run the following command:

ltsp-update-image --cleanup /

As mentioned previously, if you need to, you can exclude some of your server files or directories from the generated image by editing “/etc/ltsp/ltsp-update-image.excludes”. You simply type in the name of the programs to exclude and they will be excluded the next time you update the image.

Editing lts.conf

An lts.conf file is necessary for the purpose of specifying running conditions of the clients. For example, when this file is generated, it contains a single entry “ LDM_DIRECTX=True”. This significantly increases thin client graphics performance at a security cost. If you don't want it, comment it out by prefixing it with the “#” symbol

To create an initial lts.conf, execute in a terminal:

ltsp-config lts.conf

To edit the file, execute in a terminal:

sudo pluma /var/lib/tftpboot/ltsp/i386/lts.conf

Finally, you need to activate something called the DNS server. There are several ways to do this, but I have found by far the simplest is to execute the following in a terminal. Don;t worry if you don't understand this. Neither do I! Just know that if you execute exactly what is below, it will work:

sudo -i
sed 's/^dns=dnsmasq/# Commented by ltsp-pnp: dns=dnsmasq/'
-i /etc/NetworkManager/NetworkManager.conf
sed 's/^port=0/# Commented by ltsp-pnp: port=0/' -i /etc/dnsmasq.d/ltsp-server-dnsmasq.conf
service network-manager restart
service dnsmasq restart

The next thing you will need to do is add a user on your server. This will give allow you to log into a client machine without having to use your own account (though you could, if you wished).

To do this, you need to go to System/administration/Users and Groups and follow the instruction for adding a user.

That's it for the initial installation of PNP LTSP. However, when you re-boot your server, you may find that if you try and fire up a client it will fail to boot. If this happens, go to a terminal and put in the following commands in turn:

sudo service network-manager restart

sudo service dnsmasq restart

Then, try and connect a client to the network (make sure you have gone into its BIOS and set to boot from network instead of from its local hard drive), you will find it now boots to the LTSP network. The two command, above, having been executed at the start of a session will be good for the rest of that session on the sever.

There is quite a bit of other stuff you would be well advised to use to maintain and your LTSP network efficiently and I will be writing further tutorials to that end shortly. But, for the moment, this tutorial will get you up and running.


Very detailed, thank you :sunglasses:

Thanks Martin. Quite a few more tutorials on this to come over the next few weeks.

How to create a virtual client (for convenience of testing) on your LTSP server.

The following tutorial explains how to install Virtualbox, a virtual machine manager. Also, how to install, within Virtualbox, a virtual LTSP client machine for testing purposes.

The first thing you will need to do is install virtual box.

However, the version of Virtualbox that is in the Ubuntu repositories, for reasons linked to PAE, will not boot your 32 bit client image. The way to get round this problem with Virtualbox is to install the latest deb of Virtualbox direct from the Virtualbox website. Once it has downloaded, Gdebi will pick it up and allow you to install it. From that point, follow the rest of the instructions below.

Before you fire up Virtual box, you should ensure you are a member of the Virtualbox user group. To do this, execute the following command in a terminal:

sudo adduser yourusername vboxusers

Where "yourusername" is you actual user name. Mine, for example, is "stephen".

Once Virtualbox has been installed, you should see it in the applications/accessories menu.

Click on the “new” button on the top left:

Type in the following name; “Ubuntu LTSP client”. Make sure it is set to 32 bit. Then click next:

Give it a memory size of around 1 gig. Then click next:

Make sure to select “do not add a virtual hard drive”. This is because this virtual machine is to be an LTSP client. And such clients do not need their own hard drive. Click Create:

You will get a warning dialogue regarding your lack of a hard drive on the machine. Just ignore this and click continue:

You should now see your virtual LTSP client machine in the main Virtualbox window. You need to apply a few settings changes to it. In order to do this, press the settings tab:

Change the boot order to only include “network” and also move this to the top if the list. Then pick the display tab:

Increase the video memory to as much as you wish, depending on what your server graphics card will allow. My server's GPU has lots to spare, and so I allowed 128mb for the Virtualbox client. Now click on the Network tab:

Change adapter 1 to “bridged adapter” and make sure the network interface name is set to the name of your ethernet card on the server. If you only have the one card installed, it should be “eth0”. However, even if you have two installed, it will still almost certainly be “eth0” that has been used for the LTSP network. If, by any chance, when you later fire up this Virtual machine and it does not boot to the LTSP network, the first thing you could try is to change your interface in the virtual machine settings to, perhaps “eth1”. But, as I said, the interface will almost certainly be eth0. Next, click on the advanced tab at the bottom of the network setting dialogue panel. Change the adapter type to “Pcnet-FAST III (Am79C973)”. Change the promiscuous mode to “allow all” and make sure the “cable connected” is checked.

At this point, you can click “OK” and leave the settings panel.

You can now start your VM LTSP client. However, on first boot, you will be met by the following dialogue box:

Just click “cancel” and the client should now boot to the LTSP network. Also, the next and all subsequent times you start your VM client, you wont get the above dialogue box and it will boot straight to LTSP.

That’s it, you can now conveniently use the VM LTSP client to test out any updates you have made to the LTSP image without having to fire up a bare-metal client elsewhere on your network.

1 Like

Thanks for writing this up. I’ve followed your instructions, however, I’ve run into an issue.

When I boot from the client, I get this error:

Trying to load: pxelinux.cfg/default                   ok
Could not find kernel image: vmlinuz

I can confirm that the folder in which I would expect to have vmlinuz does not actually have the file:

# ls var/lib/tftpboot/amd64/
gpxelinux.0   pxelinux.0   pxelinux.cfg

I followed the instructions on this post: to try to work around the issue. But, I’m wondering if you encoutered the above issue.


Hi there. I have not encountered this issue. However, sometime in the next several days, I am intending to do a full upgrade from 14.04 to 15.04 and, when I do, will be installing PNP LTSP again. At which point, I will look into this issue for you and see if I can find out what went wrong.

Ok, appreciate the fast response…

In the meantime, just try the following two commands. It’s a shot in the dark, but you never know:

sudo service network-manager restart

sudo service dnsmasq restart

Then try and boot a client

Actually, can I just check the following:

Is your server 32 bit?

If it isn’t (in other words, it is 64 bit), is your client also 64 bit?

So, a little more background which might help indicate where I diverged:

  1. I’ve installed Ubuntu 14.04.2 server edition. There’s no desktop or anything.
  2. I’ve followed your instructions.
  3. I get my bug…

Did you install anything else before you started on your instructions? The reason I ask is because I don’t have network-manager available at the moment.

My server and client are both 64 bit VMs. Anyway to personally message you?

My precise installation went as followed:

  1. Ubuntu Mate 14.04 32 bit standard desktop edition installation

  2. The instructions contained in this thread

That’s it.

The reason I used the full Ubuntu Mate desktop is because I wanted Ubuntu Mate to be the desktop on the clients and PNP LTSP simply copies whatever desktop is on the server for the client image. So, installing the full desktop on the sever made the whole process really simple and easy in terms of the client image generation. The reason i used 32 bit for the server is because, again, the client image is simply a copy of the server image and so, by having 32 bit, I could be sure all clients, whatever their architecture, would be able to load the consequent 32 bit client image.

Ah, I see you are doing this with VM’s. In which case it would be helpful to see screen-shots of your VM network settings for the client and server.

Hi, in your tutorial, you’ve stated the following:

*sed ‘s/^dns=dnsmasq/# Commented by ltsp-pnp: dns=dnsmasq/’ *
-i /etc/NetworkManager/NetworkManager.conf

did not work for me; terminal spat out a message:

“No command ‘*sed’ found, did you mean:
Command ‘sed’ from package ‘sed’ (main)
Command ‘ssed’ from package ‘ssed’ (universe)
Command ‘psed’ from package ‘perl’ (main)
*sed: command not found”

So, I had to re do it as: sed ‘s/^dns=dnsmasq/# Commented by ltsp-pnp: dns=dnsmasq/’ -i /etc/NetworkManager/NetworkManager.conf

Now I have everything up and running, but there is no internet connection to the client, and every time I reboot my Virtualbox, my ip address changes although it is set to static ( It changes to and I cannot for the life of me pinpoint where the error is. I have to do the sed commands again everytime I reboot. I suspect it has to do with dnsmasq?

I have a different message on an actual machine but here’s what shows up on my virtual ltsp test machine when I reboot the server:

net0: gw
Booting from PXE menu
PXEBS (net0 type 128)... ok
Next server:
Filename: /ltsp/amd64/pxelinux.0
tftp:// Connection timed out (
No more network devices
FATAL: Could not read from the boot medium! System halted.

I’ll try to give you a message of one of the actual machines tomorrow, but for now, I can’t find any fixes to the problem.

Here is what I did to try to fix the problem to no avail:

  • Removed network-manager
  • Edited /etc/dnsmasq.d/ltsp-server-dnsmasq.conf
    -Commented enable-tftp just for experimentation; reverted back to original afterwards
    -Uncommented #bind-interfaces in hopes it would bind to /etc/network/interfaces; kept it uncommented for now
  • Edited /etc/ltsp/dhcp.conf to my preferences

That’s all I have for now. Thanks!


Hi Dave. sorry to hear you have had problems. I have to be honest with you here and simply reiterate my earlier comment that I don’t fully understand the above commands, but have simply laid them out based on the PNP tutorial on the main Ubuntu site (and on the basis of specific instructions given to me off the LTSP irc site from other users. On that basis they have always worked for me and so I don;t actually understand why they are not working for you so long as you have followed them, and the other instructions, to the letter.

Hopefully, there is someone more knowledgeable than myself who can come on here and shed some light on your problem.

Edit to add:

I’ve just taken a look at my original instructions and compared them to the site where I got them from ( and there appears to be a discrepancy! Though, I’ll be damned if I didn’t copy them exactly the first time!

Try the following instead (this is another copy I have just taken from the site):

sudo -i
sed ‘s/^dns=dnsmasq/# Commented by ltsp-pnp: dns=dnsmasq/’
-i /etc/NetworkManager/NetworkManager.conf
sed ‘s/^port=0/# Commented by ltsp-pnp: port=0/’ -i /etc/dnsmasq.d/ltsp-server-dnsmasq.conf
service network-manager restart
service dnsmasq restart

1 Like

I’ve figured out what went wrong.

The instructions were supposed to be in bold on here. But the stupid formatting of this board did not format the instructions properly and, instead, has left an asterisk at the beginning of some lines. In turn causing anyone copying them to copy the asterisk as well!

Thank you very much for flagging this up Dave. I have gone back and fixed it in the original instructions. Please accept my apologies for the inconvenience it has caused you

1 Like

Thank you for replying, Steve.

Hmm…upon entering the new commands caused failure for me; it would give me a socket error in my VM test environment and the boot image isn’t to be found (although it is there) on an actual machine.

I’ll look into it further and retrace some steps. Thanks again. :slight_smile:

Alright this time, I re-did the LTSP install verbatim. The problem with the changing IPs persist.

Although this might not do anything, but, do you have a static IP? Or did you leave it as-is and went with dynamic?

I left it as it was. I am honestly baffled as to why it’s not working for you.

My strong advice is to go on the LTSP IRC channel. The guy who devised the PNP LTSP is often on there and is usually very happy to take you through the steps and troubleshoot any problems you may have. He was invaluable to me.

1 Like

One other thing. Can I just check that your server is using a 32 bit Ubuntu installation, in turn causing the creation of a 32 bit client image?

Also, after initially booting the server, but before you try and boot your first client, run the following commands:

sudo service network-manager restart

sudo service dnsmasq restart

Then try and boot a client