kernfs.xml 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
  4. <!ENTITY % general-entities SYSTEM "../general.ent">
  5. %general-entities;
  6. ]>
  7. <sect1 id="ch-system-kernfs">
  8. <?dbhtml filename="kernfs.html"?>
  9. <title>Mounting Virtual Kernel File Systems</title>
  10. <para>Various file systems exported by the kernel are used to communicate to and
  11. from the kernel itself. These file systems are virtual in that no disk space is
  12. used for them. The content of the file systems resides in memory.</para>
  13. <para>Begin by creating directories onto which the file systems will be
  14. mounted:</para>
  15. <screen><userinput>mkdir -pv $LFS/{proc,sys}</userinput></screen>
  16. <para>Now mount the file systems:</para>
  17. <screen><userinput>mount -vt proc proc $LFS/proc
  18. mount -vt sysfs sysfs $LFS/sys</userinput></screen>
  19. <para>Remember that if for any reason you stop working on the LFS
  20. system and start again later, it is important to check that these file
  21. systems are mounted again before entering the chroot
  22. environment.</para>
  23. <para>Additional file systems will soon be mounted from within the
  24. chroot environment. To keep the host up to date, perform a <quote>fake
  25. mount</quote> for each of these now:</para>
  26. <screen><userinput>mount -vft tmpfs tmpfs $LFS/dev
  27. mount -vft tmpfs tmpfs $LFS/dev/shm
  28. mount -vft devpts -o gid=4,mode=620 devpts $LFS/dev/pts</userinput></screen>
  29. </sect1>