How To Change To Root User In Linux?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
1. Log in as the user you want to change to the root user.
2. Open a terminal window.
3. Type “su” and press Enter.
4. Enter the root user password when prompted.
5. You are now logged in as the root user.
1. Log in to the system as a regular user.
2. Open a terminal window and run the su command. For example, if your username is john, you should type su – john.
3. Enter the root user password when prompted.
4. After logging in as root, the prompt will change from username@hostname to #. This indicates that you have successfully switched to root user.
5. To verify that you are logged in as root user, run the whoami command. It should return root.
6. To change back to the regular user, type exit at the terminal.