- Timestamp:
- 05/20/2013 03:00:52 AM (11 years ago)
- Branches:
- 10.0, 10.0-rc1, 10.1, 10.1-rc1, 11.0, 11.0-rc1, 11.0-rc2, 11.0-rc3, 11.1, 11.1-rc1, 11.2, 11.2-rc1, 11.3, 11.3-rc1, 12.0, 12.0-rc1, 12.1, 12.1-rc1, 7.4, 7.5, 7.6, 7.7, 7.8, 7.9, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, arm, bdubbs/gcc13, ml-11.0, multilib, renodr/libudev-from-systemd, s6-init, trunk, xry111/arm64, xry111/arm64-12.0, xry111/clfs-ng, xry111/lfs-next, xry111/loongarch, xry111/loongarch-12.0, xry111/loongarch-12.1, xry111/mips64el, xry111/pip3, xry111/rust-wip-20221008, xry111/update-glibc
- Children:
- f873610
- Parents:
- 28c4c1e
- Location:
- chapter02
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
chapter02/creatingfilesystem.xml
r28c4c1e r4e7e16d 11 11 <title>Creating a File System on the Partition</title> 12 12 13 <para>Now that a blank partition has been set up, the file system can be created. 14 The most widely-used system in the Linux world is the second extended file 15 system (<systemitem class="filesystem">ext2</systemitem>), but with newer 16 high-capacity hard disks, journaling file systems are becoming increasingly 17 popular. The third extended filesystem (<systemitem 18 class="filesystem">ext3</systemitem>) is a widely used enhancement to 19 <systemitem class="filesystem">ext2</systemitem>, which adds journaling 20 capabilities and is compatible with the E2fsprogs utilities. 21 We will create an <systemitem class="filesystem">ext3</systemitem> 22 file system. Instructions for creating other file systems can be found at 23 <ulink url="&blfs-root;view/svn/postlfs/filesystems.html"/>.</para> 13 <para>Now that a blank partition has been set up, the file system can be 14 created. LFS can use any file system recognized by the Linux kernel, but the 15 most common types are ext3 and ext4. The choice of file system can be 16 complex and depends on the characteristics of the files and the size of 17 the partition. For example:</para> 24 18 25 <para>To create an <systemitem class="filesystem">ext3</systemitem> file 26 system on the LFS partition, run the following:</para> 19 <variablelist> 20 <varlistentry> 21 <term>ext2</term> 22 <listitem><para>is suitable for small partitions that are updated infrequently 23 such as /boot.</para> 24 </listitem> 25 </varlistentry> 26 <varlistentry> 27 <term>ext3</term> 28 <listitem><para>is an upgrade to ext2 that includes a journal 29 to help recover the partition's status in the case of an unclean 30 shutdown. It is commonly used as a general purpose file system. 31 </para> 32 </listitem> 33 </varlistentry> 34 <varlistentry> 35 <term>ext4</term> 36 <listitem><para>is the latest version of the ext file system family of 37 partition types. It provides several new capabilties including 38 nano-second timestamps, creation and use of very large files (16 TB), and 39 speed improvements.</para> 40 </listitem> 41 </varlistentry> 42 </variablelist> 27 43 28 <screen role="nodump"><userinput>mke2fs -jv /dev/<replaceable><xxx></replaceable></userinput></screen> 44 <para>Other file sytems, including FAT32, NTFS, ReiserFS, JFS, and XFS are 45 useful for specialized purposes. More information about these file systems 46 can be found at <ulink 47 url="http://en.wikipedia.org/wiki/Comparison_of_file_systems"/>.</para> 29 48 49 <para>LFS assumes that the root file system (/) is of type ext4. To create 50 an <systemitem class="filesystem">ext4</systemitem> file system on the LFS 51 partition, run the following:</para> 52 53 <screen role="nodump"><userinput>mkfs -v -t ext4 /dev/<replaceable><xxx></replaceable></userinput></screen> 54 55 <!-- 30 56 <para>Replace <replaceable><xxx></replaceable> with the name of the LFS 31 57 partition (<filename class="devicefile">sda5</filename> in our previous … … 62 88 rm -rfv e2fsprogs-&e2fsprogs-version;</userinput></screen> 63 89 </note> 64 90 --> 65 91 <para>If you are using an existing <systemitem class="filesystem">swap 66 92 </systemitem> partition, there is no need to format it. If a new -
chapter02/mounting.xml
r28c4c1e r4e7e16d 27 27 28 28 <screen role="nodump"><userinput>mkdir -pv $LFS 29 mount -v -t ext 3/dev/<replaceable><xxx></replaceable> $LFS</userinput></screen>29 mount -v -t ext4 /dev/<replaceable><xxx></replaceable> $LFS</userinput></screen> 30 30 31 31 <para>Replace <replaceable><xxx></replaceable> with the designation of the LFS … … 37 37 38 38 <screen role="nodump"><userinput>mkdir -pv $LFS 39 mount -v -t ext 3/dev/<replaceable><xxx></replaceable> $LFS39 mount -v -t ext4 /dev/<replaceable><xxx></replaceable> $LFS 40 40 mkdir -v $LFS/usr 41 mount -v -t ext 3/dev/<replaceable><yyy></replaceable> $LFS/usr</userinput></screen>41 mount -v -t ext4 /dev/<replaceable><yyy></replaceable> $LFS/usr</userinput></screen> 42 42 43 43 <para>Replace <replaceable><xxx></replaceable> and
Note:
See TracChangeset
for help on using the changeset viewer.