Linux User and Permissions Basics 4 Linux Password change

Source: Internet
Author: User

1 for students who just use Linux, the most painful thing is to use the root user to execute some commands, but do not know the root password

2 I'll just explain how to change the password for a normal user and root user

1 Change the password for root

1 The first thing to say is that the root of the Linux system does not have a password by default.

2 we can go to see the root of the/etc/shadow under the corresponding password for!, that's the default no password

3 We're going to start modifying the root user's password.

1 First step: We want to log in as a normal user, and this ordinary user can use sudo to perform administrator privileges

2 Use the command sudo passwd root to modify the root password, and then just follow the prompts to modify the password

2 Modify the general user's password

1 if we want to modify the current user's password, such as I want to modify the current user Chenguolin password, then I directly enter passwd can

2 If we want to modify the other user's password, then we directly use sudo passwd user name, this is not demo

3 Third We can use

sudo passwd-d username-This command is used to delete the user's password

4 we can use

CHAGE-L User name--to view the password-related information for this user

See more highlights of this column: http://www.bianceng.cnhttp://www.bianceng.cn/OS/Linux/

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.