Help Center> > User Guide> Creating a Private Image> Creating a System Disk Image Using a Linux ECS> Installing the One-Click Password Reset Plug-in

Installing the One-Click Password Reset Plug-in

Updated at: Mar 01, 2019 10:39

It is recommended that you install the password reset plug-in (CloudResetPwdAgent) on the ECS before using it to create a private image.

After the plug-in is installed, you can easily reset the passwords of ECSs created from this private image.

Precautions

  • You can determine whether to install the password reset plug-in.
  • You will be responsible for the failure to reset the ECS password if you uninstall the plug-in after having installed it successfully.
  • After you reinstall or change the OS of the ECS, the one-click password reset function will become invalid. If you want to continue using this function, reinstall the plug-in.
  • The password reset plug-in cannot be installed on ECSs running CoreOS.
  • If you install the password reset plug-in after your ECS password has expired or been lost, the one-click password reset function will not take effect.
  • The plug-in can be automatically upgraded only if an EIP is bound to the ECS. You can also download the upgrade package and upgrade CloudResetPwdAgent manually.
  • The plug-in has been open-sourced in the GitHub open-source platform according to GNU General Public License v2.0.
  • Not all OSs support the one-click password reset plug-in. Table 1 lists the OSs that support this plug-in.
    Table 1 OSs that support the one-click password reset plug-in

    OS Type

    OS Version

    CentOS

    CentOS 7.3 64bit

    CentOS 7.2 64bit

    CentOS 7.0 64bit

    CentOS 7.1 64bit

    CentOS 6.9 64bit

    CentOS 6.8 64bit

    CentOS 6.8 32bit

    CentOS 6.6 32bit

    CentOS 6.6 64bit

    CentOS 6.5 64bit

    CentOS 6.4 64bit

    CentOS 6.3 64bit

    Debian

    Debian 9.0 64bit

    Debian 8.8 64bit

    Debian 8.2 64bit

    Debian 7.5 64bit

    Debian 7.5 32bit

    openSUSE

    OpenSUSE 42.2 64bit

    OpenSUSE 13.2 64bit

    OpenSUSE Leap 42.2 64bit

    OpenSUSE Leap 42.1 64bit

    SUSE

    SUSE 12 sp2 64bit

    SUSE 12 sp1 64bit

    SUSE 11 sp4 64bit

    Ubuntu

    Ubuntu 16.10 32bit

    Ubuntu 16.04 32bit

    Ubuntu Server 16.04 64bit

    Ubuntu Server 14.04 64bit

    Ubuntu Server 14.04 32bit

    EulerOS

    EulerOS 2.2 64bit

    Fedora

    Fedora 25 64bit

    Fedora 24 64bit

    Oracle

    Oracle Linux7.3 64bit

    Oracle Linu6.9 64bit

    Oracle Linu6.5 64bit

Prerequisites

  • The ECS is in the Running state.
  • The available space in the root directory of a Linux ECS is greater than 300 MB, and data can be written to it.
  • ECSs running SUSE 11 SP4 must have 4 GB or larger memory.
  • DHCP has been enabled in the VPC to which the ECS belongs.
  • The ECS network is accessible.
  • The ECS security group rule in the outbound direction meets the following requirements:
    • Protocol: TCP
    • Port Range: 80
    • Remote End: 169.254.0.0/16

    If you use the default outbound security group rule, preceding requirements can be met, and the ECS can be initialized. The default outbound security group rule is as follows:

    • Protocol: All
    • Port Range: All
    • Remote End: 0.0.0.0/16

Procedure

  1. Check whether the password reset plug-in has been installed on the ECS.

    The CloudResetPwdAgent installation package consists of CloudResetPwdAgent and CloudResetPwdUpdateAgent. You can use either of the following methods:

    Method 1: Check the installation on the management console.

    1. Log in to the management console.
    2. Under Computing, click Elastic Cloud Server.
    3. Locate the row containing the target ECS, click More in the Operation column, and select Reset Password from the drop-down list.
      • If a dialog box is displayed where you can reset the password for the ECS, the one-click password reset plug-in has been installed. No further action is required.
      • If the system prompts you to download and install the password reset software, the password reset plug-in has not been installed. You must continue installing the plug-in.
    Method 2: Use the ECS for query.
    1. Log in to the ECS as user root.
    2. Run the following command to check whether the plug-in has been installed:

      ls -lh /Cloud*

      Figure 1 Checking whether the plug-in has been installed

      Check whether the information is similar to that shown in Figure 1.

      • If yes, the plug-in has been installed.
      • If no, the plug-in has not been installed. Go to the next step.
  2. Download and decompress CloudResetPwdAgent.zip, the CloudResetPwdAgent installation package.
    NOTE:

    CloudResetPwdAgent can be automatically upgraded only if an EIP is bound to the ECS. You can also download the upgrade package and upgrade CloudResetPwdAgent manually.

    The download path is as follows:

    For 32-bit OSs: http://ap-southeast-1-cloud-reset-pwd.obs.myhwclouds.com/linux/32/reset_pwd_agent/CloudResetPwdAgent.zip

    For 64-bit OSs: http://ap-southeast-1-cloud-reset-pwd.obs.myhwclouds.com/linux/64/reset_pwd_agent/CloudResetPwdAgent.zip

  3. Install the one-click password reset plug-in.
    1. Run the following command to open the CloudResetPwdUpdateAgent.Linux file:

      cd CloudResetPwdAgent/CloudResetPwdUpdateAgent.Linux

    2. Run the following command to add the execute permission for the setup.sh file:

      chmod +x setup.sh

    3. Run the following command to install the plug-in:

      sudo sh setup.sh

    4. Run the following command to check whether the installation is successful:

      service cloudResetPwdAgent status

      service cloudResetPwdUpdateAgent status

      If the status of CloudResetPwdAgent and CoudResetPwdUpdateAgent is not unrecognized service, the installation is successful. Otherwise, the installation fails.

      NOTE:
      • You can also check whether the password reset plug-in is successfully installed by referring to 1.
      • If the installation fails, check whether the installation environment meets the requirements and install the plug-in again.

Did you find this page helpful?

Submit successfully!

Thank you for your feedback. Your feedback helps make our documentation better.

Failed to submit the feedback. Please try again later.

Which of the following issues have you encountered?







Please complete at least one feedback item.

Content most length 200 character

Content is empty.

OK Cancel