Shell Command Deployment Times Out After the su Command Is Executed to Switch the User
Symptoms
When the shell command sudo su – test && echo hello is deployed, the progress is stuck in deploying state until timeout occurs.
Cause Analysis
After the su command is executed to switch to another user, the operation window of the test user is displayed and the deployment of subsequent commands stops. The commands can continue to be deployed only after the test user exits. However, the test user cannot exit during application deployment. As a result, the deployment times out.
Solution
Change the command to sudo -u test /bin/bash -c "shell command".
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot