As a follow up, I'm obviously still confused about how sacctmgr works. See
here - I add a user, and realise I've set their Default Account incorrectly.

So I try to modify it and then I realise it's just easier to delete the
user and start again:

[root@vmpr-res-head-node ~]# sacctmgr add user lsimp...@domain.com
Fairshare=1 DefaultAccount="core" Partition='prod'
 Adding User(s)
  lsimp...@domain.com
 Settings =
  Default Account = core
 Associations =
  U = lsimpson@ A = core       C = rosalind   P = prod
 Non Default Settings
  Fairshare     = 1
Would you like to commit changes? (You have 30 seconds to decide)
(N/y): y
[root@vmpr-res-head-node ~]# sacctmgr mod user lsimp...@domain.com set
DefaultAccount="rcf"
 Can't modify because these users aren't associated with new default
account 'rcf'...
  U = lsimp...@domain.com C = rosalind
[root@vmpr-res-head-node ~]# sacctmgr remove user lsimp...@domain.com
 Deleting users...
  lsimp...@domain.com
Would you like to commit changes? (You have 30 seconds to decide)
(N/y): y
[root@vmpr-res-head-node ~]# sacctmgr add user lsimp...@domain.com
Fairshare=1 DefaultAccount="rcf" Partition='prod'
 Adding User(s)
  lsimp...@domain.com
 Settings =
  Default Account = rcf
 Associations =
  U = lsimpson@ A = rcf        C = rosalind   P = prod
 Non Default Settings
  Fairshare     = 1
Would you like to commit changes? (You have 30 seconds to decide)
(N/y): y




Is that expected behaviour for reasons I haven't read yet, or am I just
thinking about sacctmgr all wrong?


cheers
L.
------
The most dangerous phrase in the language is, "We've always done it this
way."

- Grace Hopper

On 18 July 2016 at 11:21, Lachlan Musicman <data...@gmail.com> wrote:

> Hola,
>
> Because I built the cluster on the fly, I named it after my partner. The
> boss didn't like this, so we wanted to change the name. (to rosalind for
> Rosalind Franklin).
>
> I took a dump of sacctmgr:
>
>
> sacctmgr dump fiona File=/root/fiona_cluster.cfg
>
> and took a look inside. I didn't read the entire man page because I'm
> impatient and I saw the "dump/load" combo and figured it would do what it
> said on the tin.
>
> I edited the dump file, replacing the cluster name with the new one,
> renamed the file and reloaded the cfg file:
>
> sacctmgr load rosalind_cluster.cfg
>
> Didn't work.
>
> First error was that QOS didn't exist?
>
> Cluster - 'rosalind':Fairshare=1:QOS='normal'
>
>
> Second error was that the partitions didn't exist? Obviously they did -
> the only thing that had changed was the cluster name (in the conf, slurmctl
> and slurmd had restarted fine across all nodes).
>
> In particular it was the format of the user lines:
>
>  User - 'test_user':Partition='bcl2fastq':DefaultAccount='dev':Fairshare=1
>  User - 'test_user':Partition='debug':DefaultAccount='dev':Fairshare=1
>
> The Partition section.
>
> I can only surmise that:
>
>  - I did something wrong*
>  - there's an error in the dump/load workflow
>
> I have added all users and associations back by hand - tedious but at
> least I could complete it without error.
>
>
> * note that I recognise I did do something wrong by not reading the man
> file thoroughly end to end and missing the line "Cluster= - specify a
> different name for the cluster than that which is in the file."
>
> Having said that, I feel that I must be missing something else/have done
> something else wrong. AFAICT those users are showing "Associations" rather
> than users (hence the "Partition" part).
>
> I've posted about this here before.
>
> I was using the syntax
>
> sacctmgr add user manfred DefaultAccount=dev Fairshare=x
>
> but then couldn't work out how to mod the user to define a Partition. Of
> course the reason this didn't work is because users don't have Partitions -
> Associations have Users, Partitions, Accounts and Clusters. But to add
> those I was using this (confusing) syntax:
>
> sacctmgr add user manfred DefaultAccount=dev Fairshare=x Partition=dev
>
> Anyway, despite my own failings (numerous), I feel that either dump/load
> isn't working as one would expect it to work; or that the docs aren't clear
> enough with regard to adding a user and adding an association.
>
>
>
> Cheers
> L.
>
>
>
>
> ------
> The most dangerous phrase in the language is, "We've always done it this
> way."
>
> - Grace Hopper
>

Reply via email to