| Summary: | Is there a way to move all of a user's historical job data to a different account | ||
|---|---|---|---|
| Product: | Slurm | Reporter: | Ryan Novosielski <novosirj> |
| Component: | Accounting | Assignee: | Ben Roberts <ben> |
| Status: | RESOLVED INFOGIVEN | QA Contact: | |
| Severity: | 3 - Medium Impact | ||
| Priority: | --- | ||
| Version: | - Unsupported Older Versions | ||
| Hardware: | Linux | ||
| OS: | Linux | ||
| Site: | Rutgers | Alineos Sites: | --- |
| Atos/Eviden Sites: | --- | Confidential Site: | --- |
| Coreweave sites: | --- | Cray Sites: | --- |
| DS9 clusters: | --- | HPCnow Sites: | --- |
| HPE Sites: | --- | IBM Sites: | --- |
| NOAA SIte: | --- | OCF Sites: | --- |
| Recursion Pharma Sites: | --- | SFW Sites: | --- |
| SNIC sites: | --- | Linux Distro: | CentOS |
| Machine Name: | perceval | CLE Version: | |
| Version Fixed: | Target Release: | --- | |
| DevPrio: | --- | Emory-Cloud Sites: | --- |
|
Description
Ryan Novosielski
2019-08-09 09:28:48 MDT
Hi Ryan,
The entity that is created for a user/account combination (and potentially partition as well) is called an association and each association is unique. There isn't a good way in Slurm to move the usage from one association to another. The way you would want to proceed is to create a new association for the correct user/account combination and begin tracking the utilization on that association.
I'll use an example to demonstrate the most transparent to move a user to a new accocunt. I'll use user10 in my example. This user currently has an association with an account called 'a1'.
$ sacctmgr show association user=user10 format=cluster,account,user
Cluster Account User
---------- ---------- ----------
winston a1 user10
I'll create a new association for the user with the 'a2' account:
$ sacctmgr add user user10 account=a2
Now both associations show up for the user:
$ sacctmgr show association user=user10 format=cluster,account,user
Cluster Account User
---------- ---------- ----------
winston a1 user10
winston a2 user10
If you look at the user with sacctmgr you'll see that the default account is still the one they were originally created with.
$ sacctmgr show user user10
User Def Acct Admin
---------- ---------- ---------
user10 a1 None
I'll change the default to the new account:
$ sacctmgr modify user where user=user10 cluster=winston set defaultaccount=a2
This change is reflected in sacctmgr:
$ sacctmgr show user user10 User Def Acct Admin
---------- ---------- ---------
user10 a2 None
Now when the user submits a job it will default to being in the 'a2' account. At this point you could leave both associations so you can look at the usage from the first association or remove the old one. The potential down side of leaving the old association is that the user could request the other account, which could affect your reporting if you don't expect them to be using it. To show how to remove the first association I would do this:
$ sacctmgr remove user where user=user10 account=a1
I hope this helps. Please let me know if you have any questions.
Thanks,
Ben
Hi Ryan, I wanted to follow up and make sure the information I sent makes sense. Let me know if you have any questions about moving a user to a different account. Thanks, Ben Hi Ryan, I believe the information I sent should have helped and I haven't heard a response in a while. I'm going to close this ticket, but feel free to let me know if you have a follow up question. Thanks, Ben |