We often encounter many system failures when using Windows, so many people start to apply the Linux operating system. However, there are also some system faults in the Linux operating system, the following describes the Linux system fault diagnosis. I hope you can understand these Linux system faults.
Linux System Fault Diagnosis
1. startup fault
This is a common problem in Linux. The main reasons for the system failure include: during Linux operating system installation, LILO configuration information is incorrect, resulting in the system failure to start after the installation is complete; reinstall other operating systems, also, the original Linux cannot be started. Because these newly installed operating systems are no other operating systems in the computer by default, the Master Boot Record MBR of the hard disk is rewritten), which overwrites the LILO system boot program in the Linux operating system, the LILO cannot be started at last. During linux operating, the system restarts due to an incorrect Linux Command.
Solution:
If you have created an emergency boot disk group for the Linux system during or after the installation of the Linux operating system, use the First Aid disk to start the system and then access the system, configuration can solve the problem. If the First Aid boot disk group is not created, the Linux system cannot start. What should I do? Three solutions are described below:
1) enter the single-user mode of the Linux operating system. After the boot prompt, enter: linux single. In this mode, start Linux. The LILO configuration and network configuration information are not loaded during the startup process.
2) boot the hard disk with the first boot disc to install the Linux operating system) boot the hard disk Linux system, set the boot disc in the BIOS of the motherboard, after restarting the machine, boot: enter:
Vmlinuz root =/dev/linuxrootpartition noinitrd
Enter the Partition Number of your Linux root partition, that is, the hard disk partition location of the root file system of the Linux system, for example, vmlinuz root =/dev/hda3 noinitrd. After you press enter, you can enter the Linux system. To recover the corrupted LILO boot program, edit/etc/lilo. conf and run/sbin/lilo. This method is also suitable for other causes of damage to the Linux operating system. Note: The process of starting the operating system on a floppy disk is also the same as that on the operating system ).
3) run the loadlin program in DOS to start the system. When a personal computer uses a Linux system, it usually coexist with Windows 9x or Windows 2000. If you know the exact installation partition of the Linux system on the hard disk, And the loadlin program exists in the dosutil directory of the Red Hat Linux CD, you can also start the Linux system. Loadlin is a program in the dossystem. You can run it to directly start the Linux system from the dossystem and quickly enter the Linux environment. In addition to the loadlin program, you also need a Linux Startup kernel image file vmlinuz, which is available in the images directory of the Red Hat linux CD. For example, if you enter the DOS command mode under Windows 2000, and then run the following loadlin command, you can re-enter the Linux system:
Loadlin vmlinuz root =/dev/linuxrootpartition
After the command is executed, start to guide the Linux system. After logging on as a root user, edit/etc/lilo. conf and run/sbin/lilo. Then, reload the LILO system boot program into MBR.
2. File System Faults
In Linux, this is also a common fault. The file system is damaged due to abnormal system shutdown or sudden power loss.
Solution:
When the file system is damaged, you can use the fsck command to repair the file system. For example, the following command:
Fsck/dev/hda5
For more information about how to use the fsck command parameters, see the MAN reference manual. If an ext2fs file system is used, you can run the e2fsck command from a floppy disk to correct corrupted data in the file system.
Note: If the file system is damaged because the super block is damaged, the super block is the "Header" of the file system ". It contains information such as the status, size, and idle disk block of the file system. If a file system's super block is damaged, such as accidentally writing data directly to the file system's super block partition), Linux may not recognize the file system at all, even if you use the fsck or e2fsck command, you cannot fix it. At this time, you only need to check whether there is a corresponding file system in the installation disc, and overwrite the file damaged by the original operating system to restore it. If you accidentally delete important files in the system, you can try this method.
3. function library fault
In Linux, if the function library file in the system is accidentally damaged or the symbolic link in the/lib directory is damaged, the commands dependent on these libraries cannot be executed. This is also a common system fault.
Solution:
The simplest solution is to use the first aid boot disk group to start the system, install the hard disk file system in the/mnt directory, and then repair the library in the/mnt/lib directory.
4. logon system faults
The system password file is modified because the Administrator forgets the password or the system is hacked. The Administrator may not be able to log on to the system using an account.
Solution:
Method 1: when the system is started, enter the single-user mode linux single), then use the passwd command to reset the password, or change the password file to restore normal.
Method 2: Use the First Aid boot disk group to start the system, install the file system of the hard disk in the/mnt directory, and edit the/mnt/etc/passwd file for recovery.
Method 3: remove the hard disk of the installation system, place it in another Linux system, and then mount it.) mount the system installation area of the hard disk and mount/etc/passwd in the hard disk partition, the/etc/shadow and/etc/group files can be overwritten or modified or restored.
5. KDE environment faults
If the KDE environment of Linux cannot be started normally, for example, after running the startx command with a common account, the following error occurs: can not start X server. perhaps you do not have console ownershiip? . The cause of this prompt is that another user may have run the KDE environment and left a cached file indicating this user in the system.
Solution:
Run the following command:
Rm-rf/tmp /*
Then, run the startx command again to enter the KDE environment.
If the "can not start X server" error message is displayed after running the startx command with a common account, and the English characters of the error message are continuously tumble up, the KDE cannot be entered. In this case, it may be because the Linux system is not properly shut down, and thus cannot enter the Linux KDE environment.
Solution:
Log on to the console as a root user, type the setup command, and select "X Window Settings" in the system settings menu ", follow the prompts to correctly set the display type, refresh frequency, display size, and resolution. In this way, reset the X Window in the system,
If no error is reported, the system automatically starts the KDE environment. Note that a large number of English characters may tumble on the screen during setup, this does not matter. Please continue to see the screen and use the TAB or direction key for the above configuration. After the configuration is correct, the KDE environment will be restored immediately.
This article describes how to solve Linux system faults.
- Linux virtualization technology Xen virtualization beginner's Guide
- Handling Linux kernel security details
- Basic Shell programming syntax in Linux
- How to program and run a Shell program in Linux
- Linux Shell programming bash Internal commands