When new jobs are created slurmctld converts the specified account into
lowercase. src/slurmctld/job_mgr.c:_job_create() calls
xstrtolower(job_desc->account)

squeue does not do the same when the -A parameter is specified, which I
think is confusing.

Submit a job:
    [paran@kubb ~]$ sbatch -t 15 -A NsC shortjob.sh 
    Submitted batch job 145658

Specifying the exact same account to squeue does not list this job:
    [paran@kubb ~]$ squeue -A NsC
      JOBID PARTITION     NAME     USER  ST       TIME  NODES NODELIST(REASON)

Unless I use lower case:
    [paran@kubb ~]$ squeue -A nsc
      JOBID PARTITION     NAME     USER  ST       TIME  NODES NODELIST(REASON)
     145658     kappa shortjob    paran  PD       0:00      1 (Priority)

The following patch converts to lowercase in squeue as well. It is
tested with 2.2.3 but seems to apply on 2.3.0.pre3 also.

Regards,
Pär Andersson
NSC

---
 src/squeue/opts.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/squeue/opts.c b/src/squeue/opts.c
index cdd3d43..cd3890d 100644
--- a/src/squeue/opts.c
+++ b/src/squeue/opts.c
@@ -148,10 +148,10 @@ parse_command_line( int argc, char* argv[] )
                case (int) 'A':
                case (int) 'U': /* backwards compatibility */
                        xfree(params.accounts);
-                       params.accounts = xstrdup(optarg);
+                       params.accounts = xstrtolower(xstrdup(optarg));
                        params.account_list =
                                _build_str_list( params.accounts );
-               break;
+                       break;
                case (int)'a':
                        params.all_flag = true;
                        break;
-- 

Attachment: pgpB00MsiVCWr.pgp
Description: PGP signature

Reply via email to