Help Center/ Elastic Cloud Server/ FAQs/ Password and Key Pair FAQ/ What Should I Do If the One-Click Password Reset Plug-ins Installed on a Linux ECS Fail to Be Started?
Updated on 2024-09-29 GMT+08:00

What Should I Do If the One-Click Password Reset Plug-ins Installed on a Linux ECS Fail to Be Started?

Scenarios

The one-click password reset plug-ins installed on a Linux ECS fail to be started.

Symptom

When a user ran sudo sh setup.sh to install one-click password reset plug-ins, the following error message is displayed:

begin install CloudResetPwdAgent
===============cp LinuxCloudResetPwdAgent======================
===============vi /etc/profile======================
===============begin install CloudrResetPwdAgent===================
Detected RHEL or Fedora:
Installing the cloudResetPwdAgent daemon using systemd...
creating default service file...
Reading file /etc/systemd/system/cloudResetPwdAgent.service
Job for cloudResetPwdAgent.service failed because the control process exited with error code.
See "systemctl status cloudResetPwdAgent.service" and "journalctl -xe" for details.
Failed to start service cloudResetPwdAgent
/CloudResetPwdAgent/CloudResetPwdAgent.Linux
cloudResetPwdAgent install successfully.

In the /var/log/message file, the following error information is displayed:

systemd[1]: Starting cloudResetPwdAgent...
systemd[2324]: cloudResetPwdAgent.service: Failed to execute command: Permission denied
systemd[2324]: cloudResetPwdAgent.service: Failed at step EXEC spawning /CloudrResetPwdAgent/bin/./cloudResetPwdAgent.script: Permission denied
systemd[1]: cloudResetPwdAgent.service: Control process exited, code=exited status=203
systemd[1]: cloudResetPwdAgent.service: Failed with result 'exit-code'.
systemd[1]: Failed to start cloudResetPwdAgent. 

The password reset plug-ins can be executed in the root directory only after Security-Enhanced Linux (SELinux) is disabled.

Solution

  1. Disable SELinux temporarily.

    setenforce 0

  2. Disable SELinux permanently.
  3. Install the password reset plug-ins again.

    sudo sh setup.sh

    • If "cloudResetPwdAgent install successfully." is displayed and "Failed to start service cloudResetPwdAgent" is not displayed, the installation is successful.
    • If the installation failed, check whether the installation environment meets requirements and install the plug-in again.