The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 11-18-2008
manojbarot1 manojbarot1 is offline
Registered User
  
 

Join Date: Nov 2008
Posts: 1
passing password in shell script

Hi,

Anybody help to write a shell script as below requirement.

script stops some costomized application services.
1. first it will stop apache as root
2. then it will switch to my application user and stop app service.
Note: passing password is required to stop app service as app user.
I dont want it to prompt for password.
3 then exit from app user and move to another service to stop.

Please help me as soon as possible.

Thanks in advance
Manoj