Redhat Linux 9: Sử dụng Rescue Disk



Redhat Linux 9: Sử dụng Rescue Disk

Redhat Linux 9:  Sử dụng Rescue Disk

Link playlist
Red Hat Enterprise Linux Administration
https://www.youtube.com/playlist?list=PLIpLw6v7Z1qnIUiJipjgYEHwxF16TZbCN

2023 08 27 21 15 39

Restoring System Access Using a Rescue Disk
After selecting the Troubleshooting option, you are presented
with the following options, as shown in Figure 18-3:
Figure 18-3 Starting from a Rescue Disk
Install Red Hat Enterprise Linux 9 in Basic Graphics
Mode: This option reinstalls your machine. Do not use it
unless you want to troubleshoot a situation where a normal
installation does not work and you need a basic graphics
mode. Normally, you should never need to use this option to
troubleshoot a broken installation.
Rescue a Red Hat Enterprise Linux System: This is the
most flexible rescue system. In Exercise 18-2, you can explore
it in detail. This should be the first option of choice when
using a rescue disk.
Run a Memory Test: Run this option if you encounter
memory errors. It allows you to mark bad memory chips so
that your machine can boot normally.
Boot from Local Drive: If you cannot boot from GRUB on
your hard disk, try this option first. It offers a boot loader
that tries to install from your machine’s hard drive, and as
such is the least intrusive option available.
After starting a rescue system, you usually need to enable full
access to the on-disk installation. Typically, the rescue disk
detects your installation and mounts it on the /mnt/sysimage
directory. To fix access to the configuration files and their
default locations as they should be available on disk, use the
chroot /mnt/sysimage command to make the contents of this
directory your actual working environment. If you do not use
this chroot command, many utilities will not work, because if
they write to a configuration file, it will be the version that
exists on the read-only disk. Using the chroot command
ensures that all path references to configuration files are
correct.
In Exercise 18-2, you learn how to use the Rescue a Red Hat
Enterprise Linux System option to troubleshoot a system that
does not boot anymore.
Exercise 18-2 Using the Rescue Option
1. Restart your server from the installation disk. Select the
Troubleshooting menu option.
2. From the Troubleshooting menu, select Rescue a Red Hat
Enterprise Linux System. This prompts you to press Enter
to start the installation. Do not worry; this option does not
overwrite your current configuration, it just loads a rescue
system.
3. The rescue system now prompts you that it will try to find an
installed Linux system and mount on /mnt/sysimage. Press 1
to accept the Continue option (see Figure 18-4).
Figure 18-4 The Rescue System Looks for an Installed System Image and Mounts It
for You
4. If a valid Red Hat installation was found, you are prompted
that your system has been mounted under /mnt/sysimage. At
this point, you can press Enter to access the rescue shell.
5. Your Linux installation at this point is accessible through the
/mnt/sysimage directory. Type chroot /mnt/sysimage. At this
point, you have access to your root file system and you can
access all tools that you need to repair access to your system.
6. Type exit to quit the chroot environment, and type reboot
to restart your machine in a normal mode.