Changeset 677f8ac for BOOK/chroot


Ignore:
Timestamp:
Jul 14, 2014, 2:33:31 AM (10 years ago)
Author:
Chris Staub <chris@…>
Branches:
clfs-3.0.0-sysvinit, sysvinit
Children:
f1e6ec8
Parents:
624c544
git-author:
Chris Staub <chris@…> (07/14/14 02:29:19)
git-committer:
Chris Staub <chris@…> (07/14/14 02:33:31)
Message:

Updated file system mount commands for chroot

Conflicts:

BOOK/introduction/common/changelog.xml

Location:
BOOK/chroot
Files:
1 deleted
13 edited

Legend:

Unmodified
Added
Removed
  • BOOK/chroot/common/kernfs.xml

    r624c544 r677f8ac  
    2727  be mounted:</para>
    2828
    29 <screen><userinput>mkdir -pv ${CLFS}/{dev,proc,sys}</userinput></screen>
    30 
    31   <para>Now mount the file systems:</para>
    32 
    33 <screen><userinput>mount -vt proc proc ${CLFS}/proc
    34 mount -vt sysfs sysfs ${CLFS}/sys</userinput></screen>
    35 
    36   <para>Remember that if for any reason you stop working on the CLFS system
    37   and start again later, it is important to check that these file systems
    38   are mounted again before entering the chroot environment.</para>
     29<screen><userinput>mkdir -pv ${CLFS}/{dev,proc,run,sys}</userinput></screen>
    3930
    4031  <para>Two device nodes, <filename class="devicefile">/dev/console</filename>
    4132  and <filename class="devicefile">/dev/null</filename>, are required to be
    42   present on the filesystem. These are needed by the kernel even before
     33  present on the file system. These are needed by the kernel even before
    4334  starting Udev early in the boot process, so we create them here:</para>
    4435
     
    5041  <systemitem class="filesystem">devtmpfs</systemitem> file system. For now
    5142  though, we will just use the <quote>bind</quote> option in the mount command
    52   to make our host system's /dev structure appear in the new CLFS filesystem:</para>
     43  to make our host system's <filename class="directory">/dev</filename> structure appear in the new CLFS file system:</para>
    5344
    5445<screen><userinput>mount -v -o bind /dev ${CLFS}/dev</userinput></screen>
    5546
    56   <para>Additional file systems will soon be mounted from within the chroot
    57   environment. To keep the host up to date, perform a <quote>fake mount</quote>
    58   for each of these now:</para>
     47  <para>Now mount the remaining file systems:</para>
    5948
    60 <screen><userinput>if [ -h ${CLFS}/dev/shm ]; then
    61   link=$(readlink ${CLFS}/dev/shm)
    62   mkdir -p ${CLFS}/$link
    63   mount -f -vt tmpfs shm ${CLFS}/$link
    64   unset link
    65 else
    66   mount -f -vt tmpfs shm ${CLFS}/dev/shm
    67 fi
    68 mount -f -vt devpts -o gid=&gid-tty;,mode=620 devpts ${CLFS}/dev/pts</userinput></screen>
     49<screen><userinput>mount -vt devpts -o gid=&gid-tty;,mode=620 devpts ${CLFS}/dev/pts
     50mount -vt proc proc ${CLFS}/proc
     51mount -vt tmpfs tmpfs ${CLFS}/run
     52mount -vt sysfs sysfs ${CLFS}/sys</userinput></screen>
     53
     54  <para>On some host systems, <filename class="directory">/dev/shm</filename>
     55  is a symbolic link to <filename class="directory">/run/shm</filename>.
     56  If it is, create a directory in <filename class="directory">/run</filename>:</para>
     57
     58<screen><userinput>[ -h ${CLFS}/dev/shm ] &amp;&amp; mkdir -pv ${CLFS}/$(readlink ${CLFS}/dev/shm)</userinput></screen>
     59
     60  <para>Remember that if for any reason you stop working on the CLFS system
     61  and start again later, it is important to check that these file systems
     62  are mounted again before entering the chroot environment.</para>
    6963
    7064</sect1>
  • BOOK/chroot/mips-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/createfiles.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/mips64-64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="mips64-64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/mips64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="mips64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/ppc-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/createfiles.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/ppc64-64-chapter.xml

    r624c544 r677f8ac  
    1919  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="64/createfiles.xml"/>
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    21   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2221
    2322</chapter>
  • BOOK/chroot/ppc64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ppc64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/sparc-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/createfiles.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/sparc64-64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="sparc64-64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/sparc64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="sparc64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/x86-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/createfiles.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/x86_64-64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="x86_64-64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
  • BOOK/chroot/x86_64-chapter.xml

    r624c544 r677f8ac  
    2020  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="x86_64/flags.xml"/>
    2121  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/pwdgroup.xml"/>
    22   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="common/devices.xml"/>
    2322
    2423</chapter>
Note: See TracChangeset for help on using the changeset viewer.