~ubuntu-branches/ubuntu/vivid/slurm-llnl/vivid

« back to all changes in this revision

Viewing changes to src/sacctmgr/association_functions.c

  • Committer: Bazaar Package Importer
  • Author(s): Gennaro Oliva
  • Date: 2009-09-24 23:28:15 UTC
  • mfrom: (1.1.11 upstream) (3.2.4 sid)
  • Revision ID: james.westby@ubuntu.com-20090924232815-enh65jn32q1ebg07
Tags: 2.0.5-1
* New upstream release 
* Changed dependecy from lib-mysqlclient15 to lib-mysqlclient 
* Added Default-Start for runlevel 2 and 4 and $remote_fs requirement in
  init.d scripts (Closes: #541252)
* Postinst checks for wrong runlevels 2 and 4 links
* Upgraded to standard version 3.8.3
* Add lintian overrides for missing slurm-llnl-configurator.html in doc
  base registration
* modified postrm scripts to ignore pkill return value in order to avoid
  postrm failure when no slurm process is running
* Checking for slurmctld.pid before cancelling running and pending
  jobs during package removal 

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 *  Copyright (C) 2002-2008 The Regents of the University of California.
6
6
 *  Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
7
7
 *  Written by Danny Auble <da@llnl.gov>
8
 
 *  LLNL-CODE-402394.
 
8
 *  CODE-OCEC-09-009. All rights reserved.
9
9
 *  
10
10
 *  This file is part of SLURM, a resource management program.
11
 
 *  For details, see <http://www.llnl.gov/linux/slurm/>.
 
11
 *  For details, see <https://computing.llnl.gov/linux/slurm/>.
 
12
 *  Please also read the included file: DISCLAIMER.
12
13
 *  
13
14
 *  SLURM is free software; you can redistribute it and/or modify it under
14
15
 *  the terms of the GNU General Public License as published by the Free
349
350
                PRINT_USER
350
351
        };
351
352
 
352
 
        _set_cond(&i, argc, argv, assoc_cond, format_list);
 
353
        for (i=0; i<argc; i++) {
 
354
                int command_len = strlen(argv[i]);
 
355
                if (!strncasecmp (argv[i], "Where", MAX(command_len, 5))
 
356
                    || !strncasecmp (argv[i], "Set", MAX(command_len, 3))) 
 
357
                        i++;            
 
358
                _set_cond(&i, argc, argv, assoc_cond, format_list);
 
359
        }
353
360
 
354
361
        if(exit_code) {
355
362
                destroy_acct_association_cond(assoc_cond);
357
364
                return SLURM_ERROR;
358
365
        } else if(!list_count(format_list)) 
359
366
                slurm_addto_char_list(format_list,
360
 
                                      "C,A,U,Part,F,GrpJ,GrpN,GrpS,"
 
367
                                      "C,A,U,Part,F,"
 
368
                                      "GrpCPUMins,GrpJ,GrpN,GrpS,GrpWall,"
361
369
                                      "MaxJ,MaxN,MaxS,MaxW,QOS");
362
370
 
363
371
        print_fields_list = list_create(destroy_print_field);
382
390
                        field->type = PRINT_ACCOUNT;
383
391
                        field->name = xstrdup("Account");
384
392
                        if(tree_display)
385
 
                                field->len = 20;
 
393
                                field->len = -20;
386
394
                        else
387
395
                                field->len = 10;
388
396
                        field->print_routine = print_fields_str;
546
554
                        continue;
547
555
                }
548
556
 
549
 
                if(newlen > 0) 
 
557
                if(newlen) 
550
558
                        field->len = newlen;
551
559
                
552
560
                list_append(print_fields_list, field);          
608
616
                                        }
609
617
                                        print_acct = get_tree_acct_name(
610
618
                                                local_acct,
611
 
                                                parent_acct,
612
 
                                                assoc->cluster, tree_list);
 
619
                                                parent_acct, tree_list);
613
620
                                        xfree(local_acct);
614
621
                                } else {
615
622
                                        print_acct = assoc->acct;
628
635
                        case PRINT_FAIRSHARE:
629
636
                                field->print_routine(
630
637
                                        field,
631
 
                                        assoc->fairshare,
 
638
                                        assoc->shares_raw,
632
639
                                        (curr_inx == field_count));
633
640
                                break;
634
641
                        case PRINT_GRPCM: