Several common system failures and solutions under UNIX

  
        

As a computer system administrator of the financial system, we have been optimistic about SCO's multi-user series operating system products since 1994. We have used the normal and online versions of XENIX, SCO UNIX SVR4, and SCO OPENSERVER 5.0.5. The reason is that these operating system products have multi-user, multi-tasking functions, security and confidentiality is relatively good, easy to connect graphics, character terminal equipment, simple network connection, low cost of business use. However, it is precisely because of this that it inevitably brings problems such as abnormal shutdown of the computer and accidental deletion of system files. Unlike the Windows series products, there are Chinese prompts and help. System maintenance personnel need to understand various English prompts appearing in the system. Incorporating a unix command to eliminate various faults brings difficulties to system maintenance, and also provides relatively high technical requirements for system maintenance personnel.
In the actual work, we found that there are two main reasons for the UNIX system failure: First, the computer is abnormally closed, although the computer will automatically check the file system when restarting, but those error warnings that cannot be automatically repaired, first-line operation The person does not understand and does not process it, and the system crashes after a long period of time. Second, the technical maintenance personnel of the sub-branch handled the computer when the computer was faulty. Not only did the original problem not be solved, but it also caused new damage to the system. The fault phenomenon is concentrated in that the system cannot be booted, cannot enter the multi-user working mode, all users in the login state cannot log in, the system cannot be shut down normally, and the serial port of the individual terminal cannot be used. The tools used to solve these problems are mainly the emergency system boot disk created when the system is installed. There are many articles on the practice of the emergency disk. You can refer to "China Financial Computer", No. 10, 2001, "Unix System Super User". Introduction to the method of handling password loss. Here are a few typical troubleshooting tips to illustrate the solution one by one.

First, when the computer starts prompt:

boot not found
can not open;
stage 1 boot failure: error loading hd(40) /boot
The reason is the system The /boot file is corrupted or missing, causing the system to fail to boot. Repair method:
1. Boot the system with the boot disk of the emergency disk. At the Boot: prompt, enter:
fd(60) unix.Z root=hd(42)
2. Enter at system startup Super user password, enter single user mode, uninstall /stand file system, command format:
#umount /stand
3, reload stand file system
#mount /stand
Execute 2, 3 The purpose of the step is to change the read-only property of /stand. By default, /stand is read-only.
4, set up the boot disk file system, command format:
#mount -r /dev/rfd0135ds18 /mnt
5, copy the boot disk boot file into the hard disk
#cp /mnt/boot /stand
6, uninstall the floppy file system, restart the computer, the command format:
#umount /mnt
#reboot

Second, the computer starts prompt:

Unix not found

Then the system hangs because the system's /unix file is corrupted or missing. There are two solutions: First, use the system to automatically back up the old kernel when the kernel is reconnected: Enter the unix.old boot under Boot:. The second is to use the emergency boot disk repair, the specific steps are:

1, under the input: fd (60) unix.Z root = hd (42) swap = hd (41)
2, and The first type of fault is handled similarly. When the system boots to single-user mode, the /stand file system is unloaded and loaded, and the floppy disk unix.Z is copied into the hard disk. Command Format:

#umount /stand
#mount /stand
#mount -r /dev/rfd0135ds18 /mnt
#cp /mnt/unix.Z /stand
# Reboot

Third, the system can not enter the multi-user working mode after the start

There are two reasons for this situation:

1, /etc/inittab file is missing Or damaged
2, /etc/passwd file is missing or corrupted

If the system prompts at boot:
init:cannot open /etc/inittab errno:2

Then Pressing +d to enter multiple users failed. It indicates that the /etc/inittab file is missing or damaged, and this file includes the init command to control the init level entered by the computer. Init 0 is to shut down the computer, init 1 is to enter the single user mode, and init 2 is the default when the system is started. Multi-user run level. The solution is to fix the inittab file and re-create the Unix kernel. There are two solutions:

1. Re-establish the file link of inittab, command format:
#ln -s /var/opt/K/SCO/unix/5.0.5a/etc/inittab /Etc.inittab

2, refactoring the inittab file

#touch /etc/.new-unix
#cd /etc/conf/bin
#./idmkenv
Enter "y" at the system prompt, then enter:
#cat /etc/inittab
After completing the above work, enter:
#init 2

to enter multi-user operation The system is gone.

If the system prompts

su:unknown id:root
init:single user mode
password file missing
entering system maintenance mode

Then the system can only enter single-user maintenance mode, indicating that the /etc/passwd file is missing or corrupted. If you use the l command to display a long list of files, the system will first display: /etc/passwd cannot be opened for reading. The solution is to copy the passwd file in the root disk of the emergency disk (the second emergency disk) into the hard disk, and modify the owner and group of the passwd file. The command format is:

#mount -r; /dev/rfd0135ds18 /mnt
#cp /mnt/etc/passwd /etc/passwd
#chown bin:auth passwd
#reboot

Fourth, the system can not be shut down properly

The computer is running normally, but after the system closes the input shutdown -g0 -i0 -y command, the computer prompts /etc/initscript:/etc/uadmin:not found And then the system hangs. Every time the computer is turned off, it is abnormally shut down, and the file system needs to be checked when booting. The reason is that the /etc/uadmin file is missing or corrupted. The solution is to copy the uadmin file of the emergency boot root disk into the hard disk. The command format is:

The system starts in single-user mode. After checking the file system:

#mount /dev/rfd0135ds18 /mnt
#cp /mnt/etc/uadmin /etc/uadmin
#chown bin:bin /etc/uadmin
#umount /mnt
#reboot

V. Individual All users on the terminal connected to the serial port cannot register

. The phenomenon is that the terminal and the connection cable are normal. The login prompt is also displayed on the terminal. However, after the user name, the terminal prompts the serial port name (such as tty21a, etc.). Is disabled --- see account administrator, and then exit to the login prompt, ordinary users can not log in to the system. The reason is that the default number of unsuccessful logins by the default user is 99 times when the system is installed. If this number is exceeded, the system will automatically lock the serial port. The solution is to use the scoadmin management tool after the super user logs in. The operation steps are: scoadminàsystemàterminal manageràunlock, press the function key to select the locked terminal port and unlock. Then exit to the terminal manager àoptions, the default unsuccessful attempts before locking terminal defaults to 99 times, changed to infinte (no limit), so that users will have more than 99 incorrect logins in the future will not lock the terminal serial port.

Long-term work practice found that the computer operating system, I feel that sco's Unix operating system is still very stable and reliable. In practice, you should use the fsck -y command to check the consistency of the file system and automatically fix the error as you check the virus on the Windows platform. Once the computer system fails, both the front-line operators and the technical maintenance personnel must record the abnormal phenomena, treatment measures and steps of the computer, and provide detailed information for further higher-level technical processing in the future. The text accumulation process of work experience provides a good foundation for the exchange of experience.



Copyright © Windows knowledge All Rights Reserved