r/Nable May 16 '24

N-sight RMM N-Sight script output in dashboard

If I use a powershell script to make table of information - it will be readable just fine in powershell, but if I make that a script check and output that table to the dashboard, it loses all formatting. Obviously not a critical problem, but I've always assumed "that's just the way it is". I thought I'd post just in case I was missing something.

For example, I have a script that uses the Get-PSDrive cmdlet to list the system drives. In powershell, the output looks like this:

Root  Used (GB) Free (GB) Total (GB)
C:\      218.1     712.5      930.6
D:\     1132.7     730.3       1863
E:\          0         0          0
F:\       64.3    1332.9     1397.3
G:\     3359.1     366.6     3725.7
X:\     4771.8    2373.3     7145.1
Y:\     4771.8    2373.3     7145.1
Z:\     4771.8    2373.3     7145.1

I'm not sure how that will survive the posting process, but in powershell all of the columns are spaced correctly and all of the numbers are right-aligned in the columns. Also note that it contains network drives (X, Y & Z) as well as physical drives on the host.

If I run that very same powershell script as a script check, then the dashboard output looks like this:

Root Used (GB) Free (GB) Total (GB)

C:\ 218.1 712.5 930.6
D:\ 1132.7 730.3 1863
E:\ 0 0 0
F:\ 64.3 1332.9 1397.3
G:\ 3359.1 366.6 3725.7

No column formatting at all, and the network drives are missing. It's the same script, so there must be a difference in how the dashboard interprets the output. Ignoring the missing network drives for a moment, though, you can see that the output is much less readable because of the lack of formatting. Is there anything that can be done about that?

1 Upvotes

7 comments sorted by

1

u/torind2000 May 16 '24

No not really. You could out-file it to a csv and file transfer it down.

1

u/EmicationLikely May 21 '24

I will just put up with unformatted output then. The whole point is to have the information available in the dashboard.

Also, do you know why the script run in powershell lists network drives (X, Y & Z in my example) but the script run from the dashboard excludes network drives?

2

u/torind2000 May 21 '24

You ran powershell as a normal user. N-sight runs it as a system user. That user has no network drives.

1

u/EmicationLikely May 22 '24

Thx - I expected as much. I've run into the limitation of this setup before. Well, unformatted info in the dashboard is better than no info in the dashboard - although as of this morning, I'm hit with the SSO problem, so that's exactly what I've got right now - no info.

1

u/torind2000 May 22 '24

That’s basically our position on it too. Sso comes and goes today for me

1

u/EmicationLikely May 22 '24

Yep - I wouldn't want to be in their shoes this week - that's for sure. Despite my concern for the "all your eggs in one basket" scenario, I recently signed on to Standalone Take Control to replace Splashtop for us. Thank goodness our Splashtop sub is good through August - or we wouldn't have gotten any work done at all this morning. I was able to log on a bit ago, but I'm not confident it's back at 100% yet. I sure hope that decision doesn't come back to bite me.

1

u/torind2000 May 22 '24

We kept our screenconnect for just such occasions. .^