diff --git a/NEWS b/NEWS index 2df4c2af7221577b181de83f86a1107171b2629d..49c3a7a70350b4bdccb79a3cf6b9cd35fa71d701 100644 --- a/NEWS +++ b/NEWS @@ -299,6 +299,9 @@ documents those changes that are of interest to users and administrators. reservation). Backport from 14.11 commit 77c2bd25c. -- Fix PrivateData=reservation when using associations to give privileges to a reservation. + -- Better checking to see if select plugin is linear or not. + -- Add support for time specification of "fika" (3 PM). + -- Standardize qstat wrapper more. * Changes in Slurm 14.03.8 ========================== diff --git a/contribs/torque/qstat.pl b/contribs/torque/qstat.pl index b8c4f89682f19e2deb8e21b13b19335ad81136e8..3462d097189e139f0e66b3cd5a445e97c70b0066 100755 --- a/contribs/torque/qstat.pl +++ b/contribs/torque/qstat.pl @@ -436,7 +436,9 @@ sub print_job_brief if(!$line_num) { printf("%-19s %-16s %-15s %-8s %-1s %-15s\n", - "Job ID", "Jobname", "Username", "Time", "S", "Queue"); + "Job id", "Name", "Username", "Time Use", "S", "Queue"); + printf("%-19s %-16s %-15s %-8s %-1s %-15s\n", + '-' x 19, '-' x 16, '-' x 15, '-' x 8, '-' x 1, '-' x 15); } printf("%-19.19s %-16.16s %-15.15s %-8.8s %-1.1s %-15.15s\n", $job->{'job_id'}, $job->{'name'}, $job->{'user_name'}, @@ -458,8 +460,8 @@ sub print_job_select "", "", "", "", "", "", "", "Req'd", "Req'd", "", "Elap"); printf( "%-20s %-8s %-8s %-20s %-6s %-5s %-5s %-6s %-5s %-1s %-5s\n", - "Job ID", "Username", "Queue", "Jobname", "SessID", "NDS", - "TSK", "Memory", "Time", "S", "Time" + "Job id", "Username", "Queue", "Name", "SessID", "NDS", + "TSK", "Memory", "Time Use", "S", "Time" ); printf( "%-20s %-8s %-8s %-20s %-6s %-5s %-5s %-6s %-5s %-1s %-5s\n", diff --git a/doc/html/team.shtml b/doc/html/team.shtml index 73da51ea5a30d9692a3c1d630bdf61c850271dd5..38019e28f3dfbbfd8ced7eac593d42b51e8d8124 100644 --- a/doc/html/team.shtml +++ b/doc/html/team.shtml @@ -65,6 +65,7 @@ Lead Slurm developers are: <li>J.T. Conklin</li> <br> <li>Yuri D'Elia (Center for Biomedicine, EURAC Research, Italy)</li> +<li>Ino de Bruijn (SciLifeLab, Sweden)</li> <li>Francois Diakhate (CEA, France)</li> <li>Daniele Didomizio (EURAC Research, Italy)</li> <li>Joseph Donaghy (Lawrence Livermore National Laboratory)</li> @@ -110,7 +111,7 @@ Lead Slurm developers are: <li>Klaus Joas (University Karlsruhe, Germany)</li> <li>Greg Johnson (Los Alamos National Laboratory)</li> <li>Magnus Jonsson (Umeå University, Sweden)</li> -<li>Nicolas Joly (Institut Pastuer, France)</li> +<li>Nicolas Joly (Institut Pasteur, France)</li> <li>Matthias Jurenz (ZIH, TU Dresden, Germany)</li> <br> <li>Jason King (Lawrence Livermore National Laboratory)</li> diff --git a/doc/man/man1/salloc.1 b/doc/man/man1/salloc.1 index 077e44693a30f0274c69aac240f82893778c5232..3f205601edeeb0f7e6dea77efe0f94f169af8727 100644 --- a/doc/man/man1/salloc.1 +++ b/doc/man/man1/salloc.1 @@ -129,8 +129,8 @@ tell the controller to defer the allocation of the job until the specified time. Time may be of the form \fIHH:MM:SS\fR to run a job at a specific time of day (seconds are optional). (If that time is already past, the next day is assumed.) -You may also specify \fImidnight\fR, \fInoon\fR, or -\fIteatime\fR (4pm) and you can have a time\-of\-day suffixed +You may also specify \fImidnight\fR, \fInoon\fR, \fIfika\fR (3 PM) or +\fIteatime\fR (4 PM) and you can have a time\-of\-day suffixed with \fIAM\fR or \fIPM\fR for running in the morning or the evening. You can also say what day the job will be run, by specifying a date of the form \fIMMDDYY\fR or \fIMM/DD/YY\fR diff --git a/doc/man/man1/sbatch.1 b/doc/man/man1/sbatch.1 index ac0abcb8b5d1bc465d6ca2aef900fec76cae9206..96d5c33892362fab1c84f626d8b6b3c526590cd1 100644 --- a/doc/man/man1/sbatch.1 +++ b/doc/man/man1/sbatch.1 @@ -148,8 +148,8 @@ tell the controller to defer the allocation of the job until the specified time. Time may be of the form \fIHH:MM:SS\fR to run a job at a specific time of day (seconds are optional). (If that time is already past, the next day is assumed.) -You may also specify \fImidnight\fR, \fInoon\fR, or -\fIteatime\fR (4pm) and you can have a time\-of\-day suffixed +You may also specify \fImidnight\fR, \fInoon\fR, \fIfika\fR (3 PM) or +\fIteatime\fR (4 PM) and you can have a time\-of\-day suffixed with \fIAM\fR or \fIPM\fR for running in the morning or the evening. You can also say what day the job will be run, by specifying a date of the form \fIMMDDYY\fR or \fIMM/DD/YY\fR diff --git a/doc/man/man1/scontrol.1 b/doc/man/man1/scontrol.1 index 6f3f136cd0ce79ba7bf94e0e2ea320cf6a888f68..076d6abde38cb552b046e3b72de76d59f6438ead 100644 --- a/doc/man/man1/scontrol.1 +++ b/doc/man/man1/scontrol.1 @@ -685,8 +685,8 @@ Set the job's earliest initiation time. It accepts times of the form \fIHH:MM:SS\fR to run a job at a specific time of day (seconds are optional). (If that time is already past, the next day is assumed.) -You may also specify \fImidnight\fR, \fInoon\fR, or -\fIteatime\fR (4pm) and you can have a time\-of\-day suffixed +You may also specify \fImidnight\fR, \fInoon\fR, \fIfika\fR (3 PM) or +\fIteatime\fR (4 PM) and you can have a time\-of\-day suffixed with \fIAM\fR or \fIPM\fR for running in the morning or the evening. You can also say what day the job will be run, by specifying a date of the form \fIMMDDYY\fR or \fIMM/DD/YY\fR or \fIMM.DD.YY\fR, @@ -1260,8 +1260,8 @@ The start time for the reservation. A new reservation must specify a start time. It accepts times of the form \fIHH:MM:SS\fR for a specific time of day (seconds are optional). (If that time is already past, the next day is assumed.) -You may also specify \fImidnight\fR, \fInoon\fR, or -\fIteatime\fR (4pm) and you can have a time\-of\-day suffixed +You may also specify \fImidnight\fR, \fInoon\fR, \fIfika\fR (3 PM) or +\fIteatime\fR (4 PM) and you can have a time\-of\-day suffixed with \fIAM\fR or \fIPM\fR for running in the morning or the evening. You can also say what day the job will be run, by specifying a date of the form \fIMMDDYY\fR or \fIMM/DD/YY\fR or \fIMM.DD.YY\fR, diff --git a/doc/man/man1/srun.1 b/doc/man/man1/srun.1 index 9cc61ba3d5c72625d99ffae8c9a3fb9edb23b8fb..7313bf692b15835acea04a2cd5b4849bbfd43e09 100644 --- a/doc/man/man1/srun.1 +++ b/doc/man/man1/srun.1 @@ -115,8 +115,8 @@ Defer initiation of this job until the specified time. It accepts times of the form \fIHH:MM:SS\fR to run a job at a specific time of day (seconds are optional). (If that time is already past, the next day is assumed.) -You may also specify \fImidnight\fR, \fInoon\fR, or -\fIteatime\fR (4pm) and you can have a time\-of\-day suffixed +You may also specify \fImidnight\fR, \fInoon\fR, \fIfika\fR (3 PM) or +\fIteatime\fR (4 PM) and you can have a time\-of\-day suffixed with \fIAM\fR or \fIPM\fR for running in the morning or the evening. You can also say what day the job will be run, by specifying a date of the form \fIMMDDYY\fR or \fIMM/DD/YY\fR diff --git a/src/common/node_select.c b/src/common/node_select.c index 2e150cd286434ef93fb298ddd1a3b4c77b0c1534..cb4de3561db48c922aec759a3888761b099bfe52 100644 --- a/src/common/node_select.c +++ b/src/common/node_select.c @@ -211,23 +211,6 @@ extern int slurm_select_init(bool only_default) if (working_cluster_rec) { /* just ignore warnings here */ } else { -#ifdef HAVE_XCPU - if (strcasecmp(type, "select/linear")) { - error("%s is incompatible with XCPU use", type); - fatal("Use SelectType=select/linear"); - } -#endif - if (!strcasecmp(type, "select/linear")) { - uint16_t cr_type = slurm_get_select_type_param(); - if ((cr_type & CR_SOCKET) || (cr_type & CR_CORE) || - (cr_type & CR_CPU)) { - fatal("Invalid SelectTypeParameters for " - "select/linear: %s (%u)", - select_type_param_string(cr_type), - cr_type); - } - } - #ifdef HAVE_BG if (strcasecmp(type, "select/bluegene")) { error("%s is incompatible with BlueGene", type); @@ -397,11 +380,30 @@ skip_load_all: } init_run = true; - done: slurm_mutex_unlock( &select_context_lock ); + if (!working_cluster_rec) { + if (select_running_linear_based()) { + uint16_t cr_type = slurm_get_select_type_param(); + if ((cr_type & CR_SOCKET) || (cr_type & CR_CORE) || + (cr_type & CR_CPU)) { + fatal("Invalid SelectTypeParameters for " + "%s: %s (%u)", + type, + select_type_param_string(cr_type), + cr_type); + } + } else { +#ifdef HAVE_XCPU + error("%s is incompatible with XCPU use", type); + fatal("Use SelectType=select/linear"); +#endif + } + } + xfree(type); xfree(dir_array); + return retval; } @@ -453,6 +455,28 @@ extern int select_get_plugin_id(void) return *(ops[select_context_default].plugin_id); } +/* If the slurmctld is running a linear based select plugin return 1 + * else 0. */ +extern int select_running_linear_based(void) +{ + int rc = 0; + + if (slurm_select_init(0) < 0) + return 0; + + switch (*(ops[select_context_default].plugin_id)) { + case 102: // select/linear + case 104: // select/alps -> linear + case 107: // select/cray -> linear + rc = 1; + break; + default: + rc = 0; + break; + } + return rc; +} + /* * Save any global state information * IN dir_name - directory into which the data can be stored diff --git a/src/common/node_select.h b/src/common/node_select.h index 90025b75ad2b2d9ed44ab4c5b8b42d9bfd539c4b..25f8ed953e43bc2e843423228d3d7d22c8d1a5fa 100644 --- a/src/common/node_select.h +++ b/src/common/node_select.h @@ -265,6 +265,10 @@ extern int select_get_plugin_id_pos(uint32_t plugin_id); /* Get the plugin ID number. Unique for each select plugin type */ extern int select_get_plugin_id(void); +/* If the slurmctld is running a linear based select plugin return 1 + * else 0. */ +extern int select_running_linear_based(void); + /* * Save any global state information * IN dir_name - directory into which the data can be stored diff --git a/src/common/parse_time.c b/src/common/parse_time.c index 243cde474fbb34c2e6a4cd792d0cd53c95a710fb..61550c53048c4124faf8ec4884373ec59c94b25c 100644 --- a/src/common/parse_time.c +++ b/src/common/parse_time.c @@ -431,7 +431,7 @@ static int _get_date(char *time_str, int *pos, int *month, int *mday, int *year) /* Convert string to equivalent time value * input formats: * today or tomorrow - * midnight, noon, teatime (4PM) + * midnight, noon, fika (3 PM), teatime (4 PM) * HH:MM[:SS] [AM|PM] * MMDD[YY] or MM/DD[/YY] or MM.DD[.YY] * MM/DD[/YY]-HH:MM[:SS] @@ -499,6 +499,13 @@ extern time_t parse_time(char *time_str, int past) pos += 3; continue; } + if (strncasecmp(time_str+pos, "fika", 4) == 0) { + hour = 15; + minute = 0; + second = 0; + pos += 3; + continue; + } if (strncasecmp(time_str+pos, "teatime", 7) == 0) { hour = 16; minute = 0; diff --git a/src/common/read_config.c b/src/common/read_config.c index 063d83dc9a35d3deb0eb22aee00a1eaceddab82b..ad32f1dbec5cce918930b7432cbf28804db9163a 100644 --- a/src/common/read_config.c +++ b/src/common/read_config.c @@ -3865,9 +3865,12 @@ _validate_and_set_defaults(slurm_ctl_conf_t *conf, s_p_hashtbl_t *hashtbl) conf->select_type_param = 0; /* If not running linear default to be CR_CPU */ - if (!(slurmctld_conf.select_type_param & (CR_CPU | CR_SOCKET | CR_CORE)) - && strcmp(conf->select_type, "select/linear")) - slurmctld_conf.select_type_param |= CR_CPU; + if (!(conf->select_type_param & (CR_CPU | CR_SOCKET | CR_CORE)) + && (strcmp(conf->select_type, "select/linear") && + ((!strcmp(conf->select_type, "select/alps") || + !strcmp(conf->select_type, "select/cray")) && + (conf->select_type_param & CR_OTHER_CONS_RES)))) + conf->select_type_param |= CR_CPU; if (!s_p_get_string( &conf->slurm_user_name, "SlurmUser", hashtbl)) { conf->slurm_user_name = xstrdup("root"); diff --git a/src/plugins/select/alps/select_alps.c b/src/plugins/select/alps/select_alps.c index 4da23957961cd4ec61215723bad105ecb59b5879..4f4c9833f4ac4fff09175c34729d03574378184f 100644 --- a/src/plugins/select/alps/select_alps.c +++ b/src/plugins/select/alps/select_alps.c @@ -153,7 +153,7 @@ static int select_cray_dim_size[3] = {-1}; * minimum version for their plugins as the node selection API matures. */ const char plugin_name[] = "Cray node selection plugin"; -const char plugin_type[] = "select/cray"; +const char plugin_type[] = "select/alps"; uint32_t plugin_id = 104; const uint32_t plugin_version = 120;