Moe,
Sure. Here are additions for sview and scontrol. Requires
previous patch. We don't have a BG system to test on, so i left that
code path as it was.
Martins
On 4/8/14 12:45 PM, [email protected] wrote:
I only took a quick look at the patch, but it looks like you are on
the right path. This new field should probably be displayed by
"scontrol show job" and the sview's job information too. You should be
able to see how other fields are displayed and add similar logic for
this new field, which is what I presume that you did in squeue.
Moe
Quoting Martins Innus <[email protected]>:
Hello,
I am working on trying to get better information on how jobs are
being scheduled by the backfill algorithm. And have started with the
attached patch to expose information to squeue that is already
calculated by the scheduler. Since it breaks the ABI for messages
from the controller, I don't expect that this would be merged in the
nearterm, but is there any interest at some point to have this
available? Also, I would appreciate some feedback on whether I'm
doing the memory management correctly. It wasn't clear to me exactly
where memory should be freed.
Thanks
Martins
--- slurm-14.03.0/src/sview/job_info.c.orig 2014-04-11 14:58:18.000000000
+0000
+++ slurm-14.03.0/src/sview/job_info.c 2014-04-11 15:15:06.000000000 +0000
@@ -152,6 +152,7 @@
SORTID_NODELIST,
SORTID_NODELIST_EXC,
SORTID_NODELIST_REQ,
+ SORTID_NODELIST_SCHED,
#endif
SORTID_NODE_INX,
SORTID_NODES,
@@ -322,6 +323,8 @@
FALSE, EDIT_TEXTBOX, refresh_job, create_model_job, admin_edit_job},
{G_TYPE_STRING, SORTID_NODELIST_REQ, "NodeList Requested",
FALSE, EDIT_TEXTBOX, refresh_job, create_model_job, admin_edit_job},
+ {G_TYPE_STRING, SORTID_NODELIST_SCHED, "NodeList Scheduled",
+ FALSE, EDIT_NONE, refresh_job, create_model_job, admin_edit_job},
#endif
{G_TYPE_STRING, SORTID_CONTIGUOUS, "Contiguous", FALSE, EDIT_MODEL,
refresh_job, create_model_job, admin_edit_job},
@@ -1687,6 +1690,10 @@
find_col_name(display_data_job,
SORTID_NODELIST_REQ),
job_ptr->req_nodes);
+ add_display_treestore_line(update, treestore, &iter,
+ find_col_name(display_data_job,
+ SORTID_NODELIST_SCHED),
+ job_ptr->sched_nodes);
}
if (cluster_flags & CLUSTER_FLAG_BG)
@@ -2182,6 +2189,8 @@
SORTID_NODELIST, tmp_nodes,
SORTID_NODELIST_EXC, job_ptr->exc_nodes,
SORTID_NODELIST_REQ, job_ptr->req_nodes,
+ SORTID_NODELIST_SCHED,
+ job_ptr->sched_nodes,
SORTID_NODES, tmp_node_cnt,
SORTID_NODES_MAX, tmp_nodes_max,
SORTID_NODES_MIN, tmp_nodes_min,
@@ -4513,6 +4522,9 @@
case SORTID_NODELIST_REQ:
display_data->name = "NodeList Requested";
break;
+ case SORTID_NODELIST_SCHED:
+ display_data->name = "NodeList Scheduled";
+ break;
case SORTID_IMAGE_BLRTS:
display_data->name = NULL;
break;
--- slurm-14.03.0/src/api/job_info.c.orig 2014-04-11 14:13:14.000000000
+0000
+++ slurm-14.03.0/src/api/job_info.c 2014-04-11 14:25:09.000000000 +0000
@@ -563,6 +563,14 @@
else
xstrcat(out, "\n ");
+ /****** Line 13A ******/
+ xstrfmtcat(out, "Sched%s=", nodelist);
+ xstrcat(out, job_ptr->sched_nodes);
+ if (one_liner)
+ xstrcat(out, " ");
+ else
+ xstrcat(out, "\n ");
+
/****** Line 14 (optional) ******/
if (job_ptr->batch_host) {
snprintf(tmp_line, sizeof(tmp_line), "BatchHost=%s",