How to Boot into Single User Mode in CentOS 7 or RHEL 7

 Single User Mode RHEL 7In this tutorial, we will demonstrate How to Boot into Single User Mode in CentOS/RHEL 7.


Login to your Console - Lilo / VM Console

Single user mode is a mode in which a multi-user computer operating system boots into a single superuser. It is mainly used for maintenance of multi-user environments such as network servers. Some tasks may require exclusive access to shared resources.

The first thing to do is to open Terminal and log in to you CentOS 7 server.

After, restart you server wait for GRUB boot menu to show.

Next step is to select your Kernel version and press
e
 key to edit the first boot option.Find the kernel line (starts with “linux16“), then change the

ro
 to
rw init=/sysroot/bin/sh  or rw init=/sysroot/bin/bash

When you have finished, press
Ctrl-X  or  F10

 to boot into single user mode

After mount root filesystem using the following command:

# chroot /sysroot/

Now, to finish this process reboot your server using the following command:

# reboot -f