Mount in single-user mode

Source: Internet
Author: User

Mount in single-user mode

Mount-o remount in single-user mode, rw/has a major purpose

 

When the Linux system cannot be started, we usually need to modify some configuration files or adjust some parameters in single-user mode. However, after entering the single-user mode, our/file system is read-only and cannot be modified. Therefore, we need to use a command: mount-o remount, rw/this command is used to set the/path File System to the readable mode, which can be freely modified.

For example:

Added/etc/mtab

/Dev/sdb1/install ext3 rw 0 0

/Etc/fstab

LABEL =/install ext3 defaults 1 2

Then the system restarts: it cannot start, prompting

Give root password for maintenance
(Or type control-d to continue :)

Enter the root password, enter the system, and remove the added content. The prompt is read-only. Do not allow modification.

Use the following method

Mount-o remount, rw/

Because root directory/is mounted inread only mode. type follwing command, then you shoshould be able to editrc. sysint script.

Now you can modify the MTAB/FSTAB file. reboot is finished, and the system starts successfully.

 


How to change the fstab file in Linux single-user mode

An error occurs during the restart and the system cannot be properly logged on to the system. Therefore, the system enables Linux to access the system in single-user mode. When the/etc/fstab file is modified, the system prompts that the file is read-only and cannot be modified; you can use either of the following methods to modify the settings. Run root # mount-o remount in Linux single-user mode, rw/And then/etc/fstab to modify 2. Use the CD to enter the Linux repair mode (Press F2 when the CD is started, enter linux rescue and press Enter), and then modify fstab. Note that the fstab path is

How to change the fstab file in Linux single-user mode

Today, a new hard disk is added to the server, and the partition format is configured with automatic mounting in fstab. Due to the incorrect fstab settings, an error occurs during linux restart and the system cannot be properly logged on; so let Linux enable the single-user mode to enter the system. When the/etc/fstab file is modified, the system prompts that the file is read-only and cannot be modified. There are two ways to modify the file after searching by netizens and online. Run root # mount-o remount in Linux single-user mode, rw/And then/etc/fstab to modify 2. Use the CD to enter the Linux repair mode (Press F2 when the CD is started, enter linux rescue and press Enter), and then modify fstab. Note that the fstab path is

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.