{"id":137974,"date":"2021-12-03T15:39:57","date_gmt":"2021-12-03T20:39:57","guid":{"rendered":"http:\/\/www.bu.edu\/tech\/?page_id=137974"},"modified":"2021-12-03T15:39:57","modified_gmt":"2021-12-03T20:39:57","slug":"tracking-jobs","status":"publish","type":"page","link":"https:\/\/www.bu.edu\/tech\/support\/research\/system-usage\/running-jobs\/tracking-jobs\/","title":{"rendered":"Managing and Tracking your Batch Job"},"content":{"rendered":"<h2>Content<\/h2>\n<ul>\n<li><a href=\"#qstat\">Check the status of submitted jobs<\/a><\/li>\n<li><a href=\"#qdel\">Delete a job from the queue<\/a><\/li>\n<li><a href=\"#qhold\">Hold back\/delay a job from executing<\/a><\/li>\n<li><a href=\"#qrls\">Release previously held jobs<\/a><\/li>\n<li><a href=\"#qacct\">Get information about completed jobs<\/a><\/li>\n<\/ul>\n<h2 style=\"margin-bottom:1.em; margin-top: 2.5em;\"><a name=\"qstat\"><\/a>Check the status of submitted jobs<\/h2>\n<p>To query the status of submitted batch jobs, execute:<\/p>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qstat -u <\/span><span class=\"placeholder\">userID<\/span><br><span class=\"output\">job-ID  prior   name       user         state submit\/start at     queue                          slots ja-task-ID<br>-----------------------------------------------------------------------------------------------------------------<br>1000001 0.10000 network_gr <span class=\"placeholder\">userID  <\/span>     r     05\/19\/2014 09:17:53 b@scc-bd7.scc.bu.edu               1<br>1000002 0.00000 network_gr <span class=\"placeholder\">userID  <\/span>     qw    05\/19\/2014 09:14:53                                    16<\/span><\/code><\/pre>\n<p>&nbsp;<br \/>\n&nbsp;<\/p>\n<table>\n<tr>\n<td colspan=2 style=\"padding:7px;background-color:#2c6696; color:#ffffff; text-align:center;  font-size:120%\">Understanding qstat output<\/td>\n<\/tr>\n<tr>\n<th width=\"20%\" style=\"background-color:#c9d5d7;  text-align:center; border-width: 1px; border-style:solid; border-color:#97a1a4; box-shadow:none;\">Queue Column<\/th>\n<th width=\"80%\"  style=\"background-color:#c9d5d7;  text-align:center; border-width: 1px; border-style:solid; border-color:#97a1a4; box-shadow:none;\">Description<\/th>\n<\/tr>\n<tbody>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>job-ID<\/b><\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">Lists the job ID. All jobs have a unique job ID that can be used to reference a particular job.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>prior<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">Priority of the job. This number is set by the SCC batch scheduling system and its value is set based on a &#8220;fair share&#8221; system to make sure all researches have reasonably equal access to the SCC resources.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>name<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">Name of the job. A user can specify the name of the job using the <code>-N<\/code> option to the <code><span class=\"command\">qsub<\/span><\/code> command. Otherwise the system will use the batch script (or binary executable) name  as a job&#8217;s name.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>userID<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">User SCC login ID.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>state<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">The state of the job: (r) &#8211; running; (qw) &#8211; waiting to run; (hqw) &#8211; on hold, waiting to run; (Eqw) &#8211; job in error state; (s) &#8211; suspended; (t) &#8211; transfering.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>submit\/start<\/b><\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">Time when the job was submitted. When the job is running, this field is updated with the time the job started.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>queue<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">The queue name and the node ID on which the job is running.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>slots<\/b> <\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">The number of slots the job requested.<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:7px;background-color:#ecf4f7;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\"><b>task<\/b><\/td>\n<td style=\"padding:7px;background-color:#ffffff;text-align:left;border-width: 1px; border-style:solid; border-color:#97a1a4;\">The task ID if the job was submitted as a job array. For all other types of jobs this field is empty.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2 style=\"margin-bottom:1.em; margin-top: 2.5em;\"><a name=\"qdel\"><\/a>Delete a job from the queue<\/h2>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qdel <\/span><span class=\"placeholder\">jobID<\/span><br><span class=\"output\"><span class=\"placeholder\">userID<\/span> has deleted job <span class=\"placeholder\">jobID<\/span> <\/span><\/code><\/pre>\n<h2 style=\"margin-bottom:1.em; margin-top: 2.5em;\"><a name=\"qhold\"><\/a>Hold back\/delay a job from executing<\/h2>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qhold <\/span><span class=\"placeholder\">jobID<\/span><br><span class=\"output\">modified hold of job <span class=\"placeholder\">jobID<\/span> <\/span><\/code><\/pre>\n<h2 style=\"margin-bottom:1.em; margin-top: 2.5em;\"><a name=\"qrls\"><\/a>Release previously held jobs<\/h2>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qrls <\/span><span class=\"placeholder\">jobID<\/span><br><span class=\"output\">modified hold of job <span class=\"placeholder\">jobID<\/span> <\/span><\/code><\/pre>\n<h2 style=\"margin-bottom:1.em; margin-top: 2.5em;\"><a name=\"qacct\"><\/a>Get information about completed jobs<\/h2>\n<p>The <code><span class=\"command\">qacct<\/span><\/code> tool is an SGE tool to report on usage over the entire SCC cluster. If the command is executed without arguments it will output the aggregate total of SCC usage. For the user or a project, a more useful output could be obtained using various options to the <code><span class=\"command\">qacct<\/span><\/code> command. For example, to retrieve the information about completed jobs: <\/p>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qacct -j <span class=\"placeholder\">jobID<\/span>\r\n<\/span><\/code><\/pre>\n<p>To list the full statistics for all the jobs a user ran during the past week, he can execute: <\/p>\n<pre class=\"code-block\"><code><span class=\"prompt\">scc % <\/span><span class=\"command\">qacct -d 7 -o <span class=\"placeholder\">userID<\/span> -j <\/span><\/code><\/pre>\n<p>For every job that ran during the specified period of time, this command will list the exit status, user, system and wallclock time, memory usage, queue name, hostname, and some other relevant information. Read the <a href=\"http:\/\/scv.bu.edu\/cgi-bin\/perl\/manscript\/SCC\/qacct\/1\">man page for qacct<\/a> for the list of all available options and their usage.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Content Check the status of submitted jobs Delete a job from the queue Hold back\/delay a job from executing Release previously held jobs Get information about completed jobs Check the status of submitted jobs To query the status of submitted batch jobs, execute: scc % qstat -u userIDjob-ID prior name user state submit\/start at queue&#8230;<\/p>\n","protected":false},"author":1692,"featured_media":0,"parent":137962,"menu_order":6,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/137974"}],"collection":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/users\/1692"}],"replies":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/comments?post=137974"}],"version-history":[{"count":1,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/137974\/revisions"}],"predecessor-version":[{"id":137975,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/137974\/revisions\/137975"}],"up":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/137962"}],"wp:attachment":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/media?parent=137974"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}