Password Reset for centos systems in VPS

Source: Internet
Author: User
Tags vps solusvm

This topic is not applicable to OpenVZ under the SolusVM Management Panel, nor to XEN, because of these two architectures, you forgot to directly reset the root password in the background. However, what if you forget to install an independent server or KVM step by step? This article records solutions to similar problems.

I used to ask Zhao Rong, a friend of KVM, to forget the root password. Where can I change it? I usually think that reinstalling the system ...... Please forgive me for my ignorance. reinstalling is undoubtedly not the best choice. We can easily reset the root password through VNC connection.

Next I will take a VPS for testing. This article uses CentOS5. * as an example to test two KVM architecture VPS: XSVPS. COM (Kansas) and VPSPLAZA. COM (Singapore)

Assume that we forget the root password. First, log on to the SolusVM Management Panel, and restart the system first, and then connect to the VNC.

You can directly click the VNC button in the panel, or you can record the VNC information and use the tool. Here, I will execute it directly in the background.

Pay attention to the above step, restart and immediately go to VNC, the action is a little faster, because the Start menu is skipped soon, as shown in the countdown, press the keyboard up and down arrow keys to select.

Is the currently available system kernel. After selecting and changing the line, press "E" on the disk to edit it.

For example, select the second row and press "E" to edit it.

Add "Space single" at the end of the line to change. Note that a space is left between single and the previous part.

For example, I framed it in red.

After the input is complete, press enter to save, and then press "B" to start in this single-user mode.

At this time, the system logs in directly without entering any password, such:

It's easy here. We can set the root password at will, directly run passwd or passwd root, enter the password that needs to be set twice in a row, and restart the machine, you can log on with the modified password.

The above method is applicable to the KVM architecture VPS and those independent servers with IPMI management.

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.