Ticket 1749 - [cosmetic] sshare -l columns not aligned
Summary: [cosmetic] sshare -l columns not aligned
Status: RESOLVED FIXED
Alias: None
Product: Slurm
Classification: Unclassified
Component: Other (show other tickets)
Version: 14.11.7
Hardware: Linux Linux
: 5 - Enhancement
Assignee: Director of Support
QA Contact:
URL:
Depends on:
Blocks:
 
Reported: 2015-06-16 11:27 MDT by Kilian Cavalotti
Modified: 2017-08-29 10:28 MDT (History)
1 user (show)

See Also:
Site: Stanford
Slinky Site: ---
Alineos Sites: ---
Atos/Eviden Sites: ---
Confidential Site: ---
Coreweave sites: ---
Cray Sites: ---
DS9 clusters: ---
Google sites: ---
HPCnow Sites: ---
HPE Sites: ---
IBM Sites: ---
NOAA SIte: ---
NoveTech Sites: ---
Nvidia HWinf-CS Sites: ---
OCF Sites: ---
Recursion Pharma Sites: ---
SFW Sites: ---
SNIC sites: ---
Tzag Elita Sites: ---
Linux Distro: ---
Machine Name:
CLE Version:
Version Fixed: 17.11.0-pre3
Target Release: 17.11
DevPrio: ---
Emory-Cloud Sites: ---


Attachments
sshare -l output in 16.05 (228.64 KB, image/png)
2017-08-11 09:52 MDT, Kilian Cavalotti
Details
sshare -l output in 17.02 (339.75 KB, image/png)
2017-08-11 09:52 MDT, Kilian Cavalotti
Details
fixed misalignment in sshare for values exceeding allotted space. (885 bytes, patch)
2017-08-21 01:11 MDT, Isaac Hartung
Details | Diff
fixed edge case. (1.07 KB, patch)
2017-08-25 14:55 MDT, Isaac Hartung
Details | Diff
sshare before (146.32 KB, image/png)
2017-08-29 09:58 MDT, Isaac Hartung
Details
sshare after (131.59 KB, image/png)
2017-08-29 09:58 MDT, Isaac Hartung
Details

Note You need to log in before you can comment on or make changes to this ticket.
Description Kilian Cavalotti 2015-06-16 11:27:20 MDT
Hi there, 

Just a cosmetic thing: when using PriorityFlags=FAIR_TREE, "sshare -l" output can be misaligned, depending on the LevelFS value. 

Example:

root                                          0.000000  3837994870                  1.000000                                          20178336 
 root                      root          0    0.000000         196    0.000000      0.000000   0.001157   0.000000                           0 
 owners                               1000    0.500000  3116922705    0.005914      0.005914             84.545770                    19095485 
  abutte                              1000    0.030303    45338683    0.011813      0.011883              0.478139                      363200 
  ask                                 1000    0.030303           0    0.000000      0.000000                   inf                           0 
  bakerjw                             1000    0.030303          74    0.000000      0.000000            290509.829078                           0 
  billingt                            1000    0.030303           0    0.000000      0.000000                   inf                           0 
  biondo                              1000    0.030303         351    0.000000      0.000000            61723.051504                           0 
  borja                               1000    0.030303           0    0.000000      0.000000                   inf                           0 
  cbohon                              1000    0.030303          64    0.000000      0.000000            335203.648936                           0 
  dpwall                              1000    0.030303    22035036    0.005741      0.005775              0.983786                       46000 
  fischer                             1000    0.030303           0    0.000000      0.000000                   inf                           0 


Cheers,
Kilian
Comment 7 Isaac Hartung 2017-08-11 09:46:10 MDT
Hi Kilian,

I have attempted to reproduce your error in both the current version and version 14.11.7 and have failed.  Are you still experiencing this problem?  If so are there any further details you could provide that might be influencing it?

--Isaac
Comment 8 Kilian Cavalotti 2017-08-11 09:52:34 MDT
Created attachment 5079 [details]
sshare -l output in 16.05
Comment 9 Kilian Cavalotti 2017-08-11 09:52:52 MDT
Created attachment 5080 [details]
sshare -l output in 17.02
Comment 10 Kilian Cavalotti 2017-08-11 09:53:01 MDT
Hi Isaac, 

> I have attempted to reproduce your error in both the current version and
> version 14.11.7 and have failed.  Are you still experiencing this problem? 
> If so are there any further details you could provide that might be
> influencing it?

As far as I can see, the issue is still there, in both 16.05.7 and 17.02.6.

I provided example outputs as screenshots, to avoid any reformatting/line wrapping from bugzilla.

The causing factor is very likely using PriorityFlags=FAIR_TREE

Thanks!
-- 
Kilian
Comment 11 Isaac Hartung 2017-08-21 01:11:51 MDT
Created attachment 5116 [details]
fixed misalignment in sshare for values exceeding allotted space.
Comment 13 Isaac Hartung 2017-08-25 14:55:06 MDT
Created attachment 5154 [details]
fixed edge case.
Comment 17 Isaac Hartung 2017-08-29 09:58:11 MDT
Created attachment 5170 [details]
sshare before
Comment 18 Isaac Hartung 2017-08-29 09:58:44 MDT
Created attachment 5171 [details]
sshare after
Comment 19 Isaac Hartung 2017-08-29 10:02:16 MDT
Hi Kilian,

I was able to reproduce your error by generating large, random values for sshare.  Now if the values are too large for the column, they will be printed in scientific notation (I've attached screen shots to illustrate).  If you want the exact value, you can still access it with the '-p' or '-P' option.  The patch will be included in the 17.11 release. I am closing this ticket, but if the problem persists, feel free to re-open it.

Bugs are fixed in the following commits:

https://github.com/SchedMD/slurm/commit/c125759ddecb3e7887c11186bed39f4df829cf9c

https://github.com/SchedMD/slurm/commit/d43fa74f72011031223037f4d0bb1934f53dd071

--Isaac
Comment 20 Kilian Cavalotti 2017-08-29 10:28:44 MDT
Excellent, thank you very much!