creatingminlayout: Set the owner and permission of $LFS

The host distro may have an insane default for root_owner and/or
root_perms in /etc/mke2fs.conf, so let's make it sane on our own.  Note
that MKE2FS_CONFIG=/dev/null makes mke2fs refuse to run so we cannot
suppress the host mke2fs.conf.
This commit is contained in:
Xi Ruoyao 2025-01-11 23:31:54 +08:00
parent cacb470c97
commit 68b56a3c33
No known key found for this signature in database
GPG Key ID: ACAAD20E19E710E3

View File

@ -18,6 +18,15 @@
location. We do this so those temporary programs will be overwritten when
the final versions are built in <xref linkend="chapter-building-system"/>.</para>
<para>At first, set the owner and permission mode of the
<filename class='directory'>$LFS</filename> directory (i.e. the root
directory in the newly created file system for the LFS system) to
&root; and <literal>755</literal> in case the host distro has been
configured to use a different default for <command>mkfs</command>:</para>
<screen><userinput>chown root:root $LFS
chmod 755 $LFS</userinput></screen>
<para>Create the required directory layout by issuing the following commands as
<systemitem class="username">root</systemitem>:</para>