Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

capturing stderr and command

Status
Not open for further replies.

sswanstr

Technical User
Apr 28, 2008
5
US
I am working on a script that calls several system commands to change some OS settings and run some other commands. I want to try to capture stderr for when something goes wrong. I have been able to do this, however, all I get is the output from the command. Is there a way to tell/capture which exact system call/command resulted in the error?
 
That works great now I just need to figure out the best way to implement it for a lot of commands. Thanks for the help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top