![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
![]() |
| UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to debug the awk script | chella | Shell Programming and Scripting | 2 | 11-08-2007 07:51 PM |
| Debug an Awk Script | mboro | Shell Programming and Scripting | 1 | 10-01-2007 06:05 AM |
| Difference between writing Unix Shell script and AIX Shell Scripts | haroonec | AIX | 0 | 04-12-2006 02:27 AM |
| disk space script debug - posted before | bryan | Shell Programming and Scripting | 3 | 04-28-2005 07:50 PM |
| “Ostream” object is not printing message on HP-UNIX for debug mode | heena | UNIX for Advanced & Expert Users | 0 | 09-13-2004 05:08 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|||||
|
Hi,
Just a quick reply/hint as im not a shell expert , add "set -x" in the begining of the script, this will display all commands that are about to be executed, hopefully helping you to know where your shell might bug ... For 'handling exceptions' you can only catch signal like segfault, sigint (user hitting break key, etc ...) with the "trap" keyword ... Good luck hunting bugs ![]() |
|
||||
|
Hi,
on the overview,if your a naive user ,then the easiest way is to use bash -xv <your script> Assuming your using bash as your shell.... This will print the output line by line and will also include every statement with the corresponding actions,attributes and parameters you've passed!!! It will list out each arg as and when they are called in the script ,so that it will be easier to debug... Regards PS:if your script is lengthy,be ready to scroll pages at a time, helpful nevertheless ![]() |
|
||||
|
u can debug unix scripts using ksh -vx <filename> , using echo statements and creating log files
|
| Sponsored Links | ||
|