Search This Blog

Friday, August 11, 2006

Full info about your jobs in PBS

To get full info about job in PBS you have to use -f option, but it doesn't work with -u $USER option, so you get a list of all jobs, or you have to know yours job id. To get around this problem I created this one line 'script':
qstat -f `qstat -u $USER |grep $USER |awk {'print $1'} |sed 's/[a-z.]//g'`
  • qstat -u $USER - create the list of all user jobs,
  • grep $USER - cut lines with usernames,
  • awk {'print $1'} - prints only column with job id (first one),
  • sed 's/[a-z.]//g' - delete all letters and dots from it.
After that you have only id numbers which can be use with qstat -f. You can extent this command further, i.e. to get info about host where you job is running, by adding grep host (it can be very useful at a cluster).
Post a Comment