SDB:KIWI-LTSP How it works

Jump to: navigation, search

Set up

kiwi-ltsp -c configures services and files required to boot LTSP client based on the main configuration file /etc/sysconfig/kiwi-ltsp. Some of the tasks it does is as below:

  • It configures dnsmasq to give out IP to client, provide DNS service and TFTP for PXE booting.
  • It configures files in /srv/tftpboot/KIWI that are served to clients and /srv/tftpboot/pxelinux.cfg/default PXE boot menu.
  • It adds ssh keys to identify the server correctly from the client.
  • It sets up services required for AOE/NBD/NFS root as per selection made in /etc/sysconfig/kiwi-ltsp.
  • Sets up firewall, masquerading and IP forwarding so clients can connect to internet.

If you are creating your own image and not using prebuilt kiwi-image-ltsp packages from Tumbleweed repository then using kiwi-ltsp -s creates /srv/kiwi-ltsp-nfs-i386 chroot image and a squashfs image of that chroot in /srv/kiwi-ltsp/i386.img. The squashfs image is then served via AOE/NBD server and used by client.

If nfsroot is used /srv/kiwi-ltsp-nfs-i386 is exported read only which is mounted as / (nfs root) on client with all the rw required bits mounted using kiwi's split image feature.

See kiwi-ltsp -h for more information.

Boot process

KIWI-LTSP supports booting from PXE, live CD and USB clients.

In case of PXE booting, the client looks for DHCP server, the DHCP server provides the network configuration and hands over further booting to TFTP server.

The client then fetches "linux-ltsp" - kernel and "initrd-ltsp" - initial ram disk. Once the booting of the kernel and initrd completes, booting into the chroot image begins.

Upon booting, the clients runs /etc/init.d/ltsp-client.init

LTSP init scripts

ltsp-client.init is responsible for launching ldm (ltsp display manager) and fetching various variables from /etc/lts.conf, it also launches mounter script that mounts local devices into the user's session on the server.

Various services required by the client such as sound using PulseAudio, local devices using cdpinger and ltspfsd, printing using jetpipe are also set up by the ltsp-client.init.

LTSP Display Manager

LDM supports login to the server via ssh. LDM logs in user and starts Xsession over ssh, it also supports authentication via ssh and Xsession without encryption(LDM_DIRECTX). With variables in /srv/tftpboot/KIWI/lts.conf we can control many thin client parameters.

Here is a picture to show this process:

Kiwi-ltsp-boot.png

See Also

LTSP Theory on Ubuntu wiki