特殊:Badtitle/NS100:UbuntuLTSP/LTSPWithoutNFS

来自Ubuntu中文
Wikibot留言 | 贡献2010年5月20日 (四) 00:31的版本
(差异) ←上一版本 | 最后版本 (差异) | 下一版本→ (差异)
跳到导航跳到搜索

{{#ifexist: :UbuntuLTSP/LTSPWithoutNFS/zh | | {{#ifexist: UbuntuLTSP/LTSPWithoutNFS/zh | | {{#ifeq: {{#titleparts:UbuntuLTSP/LTSPWithoutNFS|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:UbuntuLTSP/LTSPWithoutNFS|1|-1|}} | zh | | }}

This page is specific to Ubuntu versions 7.10 + Up

If you find this information applicable to additional versions/releases, please edit this page and modify this header to reflect that. Please also include any necessary modifications for this information to apply to the additional versions.


This page describes the new changes we made to LTSP in the ubuntu gutsy release to speed up the boot process.

Things we dropped

  • NFS
  • bind/move mounting single dirs and files into a ramfs to make them writeable
  • detecting the Xorg configuration through debconf with the xserver-xorg maintainer scripts

Things we added instead

  • NBD
  • Instead of a readonly exported NFS root we now export a squashfs image via NBD
  • Using a squashfs we can now merge that together in a unionfs to get writeable access which is a lot faster during bootup
  • introduces a new tool called nbdrootd, started by inetd
  • forces the rebuilding of the squashfs if you made changes inside the chroot (for example adding packages or changing defaults) we added the tool ltsp-update-image for this.
  • X detection
  • Xorg 7.3 (used in gutsy) is well capable of running completely without config file so we dropped it in early stages of gutsy development.
  • the above brought up problems with mouse and keyboard configurations so we had to reintroduce some kind of config file but it was clear that we didnt want to use debconf for it as we did before.
  • a new script was introduced, calling Xorg -configure (which produces the exact same setup Xorg uses without config for driver and monitor) and replacing mouse and keyboard setup with the needed values. this method takes only about 10% of the time the old one did.
  • lts.conf
  • due to the squashfs image being static you would need to run ltsp-update-image after every change to the config file if it would reside inside the image (i.e. /opt/ltsp/i386/etc/lts.conf) indeed you can still do it that way if you prefer to but dont forget to rebuild the image ;).
  • we moved the lts.conf out of the image into the tftp root and read it from there during boot (/var/lib/tftpboot/ltsp/i386/lts.conf on i386 systems for example) if the file exists in the tftp dir, it will override anything inside the image.

More and minor changes in the gutsy release will be listed in the release notes of the final release, stay tuned :)

Reverting to NFS if you want to

If you are not concerned about bootspeed or want to use nfs for any other reason, its easy to revert to it: First, install NFS and configure it:

sudo apt-get install nfs-kernel-server
echo '/opt/ltsp/i386     *(ro,no_subtree_check,no_root_squash)' | sudo tee -a /etc/exports
sudo invoke-rc.d nfs-kernel-server restart

Second, apply the patch from https://bugs.launchpad.net/ubuntu/+source/mountall/+bug/485709. Third, change the /etc/init.d/umountfs and /etc/init.d/umountnfs.sh to not umount /cow and /rowfs on stop. You can do this by inserting /cow and /rowfs into the

/|/proc|/dev|/.dev|/dev/pts|/dev/shm|...

line.