Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Ubuntu19.04 uses root users to log in to the system

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Getting started with Ubuntu19.04 Zero Foundation (2) _ logging in to the system using root users [Video demonstration]

After the Ubuntu19.04 system is installed, root users are not allowed to log on to the graphical interface by default. After we have just installed the system, we need to install a lot of software, so it is still troublesome to use root permissions temporarily through sudo or to switch to root user permissions by using the sudo-I command. If you can use root users to log in directly to the graphical interface, you can directly use the command to install, saving a lot of trouble. Here's how to configure root users to log in directly to the graphical interface under the command line window:

1. Use ordinary users to log in to the system

two。 Right-click in the blank space of the screen and select the [Open in Terminal] option.

3. In the Terminal command window, use the sudo-I command to get root permissions

~ $sudo-I

PS: notice that the command prompt has changed from "$" to "#"

4. In the Terminal command window, add the root user password.

~ # passwd root

5. Modify the contents of / usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf file

~ # gedit / usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf

Add the following two lines at the end of the file:

Greeter-show-manual-login=true

All-guest=false

6. Modify the contents of / etc/pam.d/gdm-autologin file

~ # gedit / etc/pam.d/gdm-autologin

Using the # character, comment out the line auth required pam_succeed_if.so user! = root quiet_success (around the third line)

7. Modify the contents of / etc/pam.d/gdm-password file

~ # gedit / etc/pam.d/gdm-password

Using the # character, comment out the line auth required pam_succeed_if.so user! = root quiet_success (around the third line)

8. Modify the contents of / root/.profile file

~ # gedit / root/.profile

Change the last line of the file to the following

Tty-s&&mesg n | | true

9. Restart the system and you can log in to the graphical interface using the root user.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report