Ask for help again ~~ Another question about shell scripts
Source: Internet
Author: User
Ask for help again ~~ It is also a question about shell scripts-general Linux technology-Linux technology and application information. The following is a detailed description. Suppose I want to use shell scripts to execute a command command_1, but it only needs root permission to execute it,
But we all know that the password is required for switching to the root user. (Of course, some people say that using sudo doesn't have to switch to the root user, but using sudo to execute the command also requires entering the password of the current user)
So this time I would like to ask you how to directly enter the required password in the shell script (that is, the password does not need to be input externally or through parameters)
Could you please kindly advise ~~~~~~~~~~
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