Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

new tag

  • Loading branch information...
commit 1741753edde0cd61654e3a8fced59298bf34f8b1 2 parents 65dfe5a + aaf4dfb
@dannyauble dannyauble authored
View
7 NEWS
@@ -1,6 +1,9 @@
This file describes changes in recent versions of SLURM. It primarily
documents those changes that are of interest to users and admins.
+* Changes in SLURM 2.1.13
+=========================
+
* Changes in SLURM 2.1.12
=========================
-- Fixes for building on OS X 10.5.
@@ -30,6 +33,10 @@ documents those changes that are of interest to users and admins.
-- Fix to node in correct state in accounting when updating it to drain from
scontrol/sview.
-- BLUEGENE - Removed incorrect unlocking on error cases when starting jobs.
+ -- Improve logging of invalid sinfo and squeue print options.
+ -- BLUEGENE - Added check to libsched_if to allow root to run even outside of
+ SLURM. This is needed when running certain blocks outside of SLURM in HTC
+ mode.
* Changes in SLURM 2.1.11-2
===========================
View
1  doc/html/team.shtml
@@ -45,6 +45,7 @@ Linux NetworX and many other contributors.
<li>David Jackson (Adaptive Computing)</li>
<li>Klaus Joas (University Karlsruhe, Germany)</li>
<li>Greg Johnson (LANL)</li>
+<li>Roman Kurakin (Institute of Natural Science and Ecology, Russia)</li>
<li>Jason King (LLNL)</li>
<li>Nancy Kritkausky (Bull)</li>
<li>Eric Lin (Bull)</li>
View
16 src/plugins/select/bluegene/plugin/libsched_if64.c
@@ -40,13 +40,21 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <unistd.h>
+#include <sys/types.h>
int get_parameters(void *params)
{
- char *partition = getenv("MPIRUN_PARTITION"); /* get MPIRUN env
- * var to see if we
- * are inside slurm
- * or not */
+ char *partition;
+
+ /* Always allow root to run no matter what. This is needed
+ for HTC mode where it is common to run outside of SLURM.
+ */
+ if (getuid() == 0)
+ return 0;
+
+ /* get MPIRUN env var to see if we are inside slurm or not */
+ partition = getenv("MPIRUN_PARTITION");
if (!partition || (strlen(partition) < 3)) {
printf("YOU ARE OUTSIDE OF SLURM!!!! NOT RUNNING MPIRUN!\n");
return 1;
View
11 src/sinfo/opts.c
@@ -626,9 +626,18 @@ _parse_format( char* format )
field_size,
right_justify,
suffix );
- } else
+ } else {
+ prefix = xstrdup("%");
+ xstrcat(prefix, token);
+ xfree(suffix);
+ suffix = prefix;
+ format_add_invalid( params.format_list,
+ field_size,
+ right_justify,
+ suffix );
fprintf(stderr, "Invalid node format specification: %c\n",
field[0] );
+ }
token = strtok_r( NULL, "%", &tmp_char);
}
View
8 src/sinfo/print.c
@@ -863,3 +863,11 @@ int _print_weight(sinfo_data_t * sinfo_data, int width,
printf("%s", suffix);
return SLURM_SUCCESS;
}
+
+int _print_com_invalid(sinfo_data_t * sinfo_data, int width,
+ bool right_justify, char *suffix)
+{
+ if (suffix)
+ printf("%s", suffix);
+ return SLURM_SUCCESS;
+}
View
4 src/sinfo/print.h
@@ -123,6 +123,8 @@ int print_sinfo_list(List sinfo_list);
format_add_function(list,wid,right,suffix,_print_weight)
#define format_add_alloc_nodes(list,wid,right,suffix) \
format_add_function(list,wid,right,suffix,_print_alloc_nodes)
+#define format_add_invalid(list,wid,right,suffix) \
+ format_add_function(list,wid,right,suffix,_print_com_invalid)
/*****************************************************************************
* Print Field Functions
@@ -184,5 +186,7 @@ int _print_weight(sinfo_data_t * sinfo_data, int width,
bool right_justify, char *suffix);
int _print_alloc_nodes(sinfo_data_t * sinfo_data, int width,
bool right_justify, char *suffix);
+int _print_com_invalid(sinfo_data_t * sinfo_data, int width,
+ bool right_justify, char *suffix);
#endif
View
26 src/squeue/opts.c
@@ -504,10 +504,20 @@ extern int parse_format( char* format )
field_size,
right_justify,
suffix );
- else
+ else {
+ prefix = xstrdup("%");
+ xstrcat(prefix, token);
+ xfree(suffix);
+ suffix = prefix;
+
+ step_format_add_invalid( params.format_list,
+ field_size,
+ right_justify,
+ suffix );
error ( "Invalid job step format "
"specification: %c",
field[0] );
+ }
} else {
if (field[0] == 'a')
job_format_add_account( params.format_list,
@@ -711,9 +721,19 @@ extern int parse_format( char* format )
field_size,
right_justify,
suffix );
- else
+ else {
+ prefix = xstrdup("%");
+ xstrcat(prefix, token);
+ xfree(suffix);
+ suffix = prefix;
+
+ job_format_add_invalid( params.format_list,
+ field_size,
+ right_justify,
+ suffix );
error( "Invalid job format specification: %c",
field[0] );
+ }
}
token = strtok_r( NULL, "%", &tmp_char);
}
@@ -752,7 +772,7 @@ _get_prefix( char *token )
* OUT field - the letter code for the data type
* OUT field_size - byte count
* OUT right_justify - true of field to be right justified
- * OUT suffix - tring containing everthing after the field specification
+ * OUT suffix - string containing everthing after the field specification
*/
static void
_parse_token( char *token, char *field, int *field_size, bool *right_justify,
View
7 src/squeue/print.c
@@ -1449,3 +1449,10 @@ static int _filter_step(job_step_info_t * step)
return 0;
}
+
+int _print_com_invalid(void * p, int width, bool right, char* suffix)
+{
+ if (suffix)
+ printf("%s", suffix);
+ return SLURM_SUCCESS;
+}
View
10 src/squeue/print.h
@@ -172,6 +172,8 @@ int job_format_add_function(List list, int width, bool right_justify,
job_format_add_function(list,wid,right,suffix,_print_job_comment)
#define job_format_add_reservation(list,wid,right,suffix) \
job_format_add_function(list,wid,right,suffix,_print_job_reservation)
+#define job_format_add_invalid(list,wid,right,suffix) \
+ job_format_add_function(list,wid,right,suffix,(void*)_print_com_invalid)
/*****************************************************************************
* Job Line Print Functions
@@ -296,6 +298,9 @@ int step_format_add_function(List list, int width, bool right_justify,
step_format_add_function(list,wid,right,suffix,_print_step_name)
#define step_format_add_num_tasks(list,wid,right,suffix) \
step_format_add_function(list,wid,right,suffix,_print_step_num_tasks)
+#define step_format_add_invalid(list,wid,right,suffix) \
+ step_format_add_function(list,wid,right,suffix, \
+ (void*)_print_com_invalid)
/*****************************************************************************
* Step Line Print Functions
@@ -323,4 +328,9 @@ int _print_step_nodes(job_step_info_t * step, int width,
int _print_step_num_tasks(job_step_info_t * step, int width,
bool right_justify, char *suffix);
+/*****************************************************************************
+ * Common Line Print Functions
+ *****************************************************************************/
+int _print_com_invalid(void * p, int width, bool right_justify, char * suffix);
+
#endif
Please sign in to comment.
Something went wrong with that request. Please try again.