EXT3 system file.

zhaozj2021-02-16  56

The new generation of Linux operating system archives system, using the Journalling Filesystem log file system to replace the old traditional EXT2 archive system, has become an inevitable trend; currently known log style archives such as Red Hat EXT3, NSV's Reiserfs, IBM's JFS, and SGI's XFS, etc. .... The main essence of "log" is also the function of "log". Easy, Journal File System will first record the action records that will be executed before the system data is changed. If it is not normal shutdown or power interruption, it ensures that the information is not lost.

There are several main Linux Distribution, most of the reiserfs logging system, but Red Hat starts using EXT3 log file system from Red Hat Linux 7.2, EXT3 is like EXT2 only It is more log function; as for the log style system of Red Hat EXT3, nothing is based on the following reasons:

(1) EXT3 can be compatible with EXT2, and EXT2 can simply increase the log function in an existing archive system. If you want to restore EXT2, it is easy to easily; at the same time, as long as there is a new version of E2FSPROGS kit, EXT3 Archive system, no need to remove Journal, you can also mount EXT2 archive system.

(2) EXT3 not only gains the advantages of the file, but also has the advantage of certain EXT2, such as Htrees to make large catalogs more rapidly, and Extended property features can initiate access control lists.

(3) EXT3 uses Generic Journaling Layer (JBD), but not only the log file system, other devices such as NVRAM, you can also Journal

(4) EXT3 has a variety of log patterns, for example:

Data = journal: You can log all DATA and Metadata files

Data = Ordered: Only log metadata file, excluding DATA file, but data = Ordered will point Metadata to valid DATA

Data = Writeback:

Only log metadata files, without DATA files, but Data = Writeback will make the archive system consistent, but the system will appear in the file after the system is not turned off.

The feature of Writeback is speed efficiency, although the archive system can still maintain consistency, but Quality is not so high, mainly in the adjustment of performance, for example, when we convert to ext3 from EXT2, if you encounter the performance of the application, set DATA = Writeback is a good choice

System managers can use different log patterns for different considerations of access speed and archive data in a variety of log patterns.

(5) EXT3 has a cross-platform log capability of 32 Bit or 64 BIT architecture

(6) EXT3 is integrated into the Linux kernel

(7) EXT3 still pays the characteristics of errandability of E2FSck Code data

As for the actual use, it is briefly, as follows:

1. Download the EXT3 PATCH file (available in 2.2.x or 2.4.x),

# cp ext3-2.4-0.x.y.patch.gz / usr / src

# Gunzip ext3-2.4-0.x.y.patch.gz

# patch -p0

# CD / USR / SRC / Linux

# Make MrProper

# Make MenuConfig

Select EXT3 and JBD Debugging Support on the kernel menu

# Make Dep

# make clean

# Make Bzimage

# make install

# Make Modules

# Make Modules_Install

EXT3 can choose to compile into kernel or build into module, compile into Kernel, which can simplify FAIL, which is conducive to the collection of diagnostic information.

Secondly edit the LILO boot management program setting file /etc/lilo.conf or GRUB boot management program set file / boot/grub/Menu.lst's setting information. Finally update the MBR Boot Loader;

LILO boot management program: LILO □ V □ V -V under system prompt symbol

GRUB boot management program: Grub Command in the system prompt, enter GRUB MODE, reset MBR, setup (HD0), then leave GRUB MODE, then Reboot (or reboot into edit mode settings, please man GRUB usage)

2. Download the suite after Util-Linux version 2.11

Download URL: http://www.kernel.org/pub/linux/UTILS/UTIL-LINUX/

3. Download the suite after the E2FSProgs 1.25 version

Download URL: http://www.rpmfind.net/

Download URL: http://e2fsprogs.sourceforge.net/

4. Convert EXT2 archive system to ext3:

(1) Tune2fs -j / dev / hdxx

-j Farewell, early E2FSProgs suite is not supported; the above archive system can be mounted to EXT3 after this adjustment.

(2) Change the EXT2 of / etc / fstab / dev / hdxx to EXT3, for example:

/ dev / hda3 / ext2 defaults, errors = remount-ro 0 1

Change to

/ dev / hda3 / ext3 defaults, errors = remount-ro 0 1

(3) No need UMOUNT

5. Establish a new version of EXT3:

MKE2FS -J / DEV / HDXX

This can generate new EXT3 archive systems through MKE2FS

6. Close the preset period of the regular file system check

Tune2fs -i 0 -C 0 / dev / hdxx

The preset period of the general archive system check is the 12th Mount or every 180 days, and this setting will turn off the scheduled period during periodic archive system check.

-c refers to the total mount number of inspection intervals in the two archives systems. When set to 0, KERNEL will be considered not checked.

- I refers to INTERVAL when set to 0, it will turn off the preset period of each 180-day file system check.

7. Root FileSystem's Lilo Options Settings:

(1) overwriting the preset of EXT3

LILO: Linux rootfstype = ext2

(2) Use rootflags option to set

LILO: Linux rootflags = data = journal

8.I / o ELEVATOR Efficacy Adjustment Setting:

The large part of the Linux block equipment Driver rate uses adjustable Elevator operations to make the block I / O efficiency adjustment setting, compared to EXT2, EXT3 uses the ElvTune program only requires less Latency read and write, that is, The archive system of EXT2 is generally written for 30 seconds, and EXT3 is only 5 seconds, which is more conducive to the update of information on the hard disk.

Redhat is half-written by the Latency Preset from 8192 Read, 16384 Write to 4096 Read, 8192 Write, if we want to adjust the I / O Elevator effectiveness for a specific application, we can use the ELVTUNE to change Elevator on EXT3 Set, for example:

# ElvTune -r 1024 -W 2048 / DEV / SDA (Write's Latency is usually half of Read Latency)

If a boot is to make this adjustment, you can join a line ElvTune -R 1024 -W in the /etc/rc.d/rc.local file.

转载请注明原文地址:https://www.9cbs.com/read-19648.html

New Post(0)