Four volumes of the distributed storage are mounted to the customer's database server. After the server is restarted, the system enters the emergency mode and services cannot be started.
The networking mode is IP SAN. The database server is connected to the distributed storage using a switch. Automatic mounting of Huawei data volumes is enabled by modifying fstab through UUID in the operating system.
However, after the server restarts unexpectedly, the system enters the emergency mode, and the system cannot be started properly.
1. Log in to the server using the emergency mode and check the operating system logs as prompted. An alarm is generated, indicating that the connection to the data volumes times out.
2. Comment out the fields added to /etc/fstab and restart the test.
3. After the operating system is restarted, the data volumes are manually mounted.
4. Modify startup script /cet/rc.local and add the mounting command to the script (sleep 300 mount -t ext4 -o sync UUID=).
5. Restart the system for a test. The volumes are automatically mounted.
The network adapter is not started when the server is started, but the automatic mounting script runs before the startup. Therefore, the host cannot find the data volumes in the mounting script. As a result, the server enters the emergency mode.
Add sleep 300 to the startup script to enable the operating system to restart after 300 seconds. Wait until the network adapter is started and the server can be connected to IP SAN of Huawei, and then mount the data volumes automatically.
1. Comment out the fields added to /etc/fstab and restart the test.
2. After the operating system is restarted, the data volumes are manually mounted.
3. Modify startup script /cet/rc.local and add the mounting command to the script (sleep 300 mount -t ext4 -o sync UUID=).
4. After restarting the system, the problem is resolved.