rijuroyson has asked for the wisdom of the Perl Monks concerning the following question:
Thanks for your replies
Let me try to explain the problem more clearly.
1. Say i want to execute 5 commands in a remote server.These commands are owned in a generic user id.
2. This should be executed one after the other. Output of one command execution is used as input to the second command.
3. I was using Net::SSH module to execute command in remote server( Why Net::SSH ? - using this i will get exit status,output and error status as return values). Once the remote connection is established, i need to be in generic user id (here i need to do sudo su "userid" )to execute the commands.
This is the problem i am trying to solve.
Meanwhile i will check on IPC::ShellCmd.
Thanks, Riju
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Implementing Unix sudo command in Perl
by robby_dobby (Hermit) on Mar 19, 2014 at 07:33 UTC | |
|
Re: Implementing Unix sudo command in Perl
by hdb (Monsignor) on Mar 19, 2014 at 07:39 UTC |