![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Error Message | RDM00 | UNIX for Dummies Questions & Answers | 2 | 10-06-2006 03:43 PM |
| Error message | ammu | Shell Programming and Scripting | 2 | 08-16-2006 04:41 AM |
| shell script: forbid extension | Loriel | UNIX for Dummies Questions & Answers | 3 | 03-25-2004 01:47 PM |
| CSH Error Message | Latha Nair | Shell Programming and Scripting | 6 | 10-22-2003 09:27 AM |
| How can I forbid a user to go up his home directory | MarcoW | UNIX for Advanced & Expert Users | 2 | 10-04-2001 07:14 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
forbid the error message
In my system , there is a script seems have a minor problem but I can't find it out , now everytime run the script , it will generate some error message to the system log , is it possible to forbid it generate the error to the system log or put all these message to /dev/null ? thx
|
| Forum Sponsor | ||
|
|
|
#2
|
||||
|
||||
|
in a bourne-type shell
my_script 2>/dev/null in a c-type shell (this is a fudge) ( my_script > /dev/tty ) >& /dev/null Cheers ZB |
|
#3
|
||||
|
||||
|
From your question I understand the following:
You dont want to display the error messages on the terminal. You either want it to go to the sys log or to /dev/null This is way to put it to /dev/null Say, a line in your script is Code:
grep needle haystack You would need this to redirect the error to /dev/null Code:
grep needle haystack 2> /dev/null |
|
#4
|
|||
|
|||
|
thx much for replies.
|
|||
| Google The UNIX and Linux Forums |