/build/static/layout/Breadcrumb_cap_w.png

Trying to get output of dsregcmd /status

Hi

I want to run a script or custom inventory rule, or something that would be able to get the output of dsregcmd /status on the machines, but when I try to set it as a script, it doesn't seem like it is able to run for some reason, and also as a custom inventory rule, it seems it was not able to get any output either.

Has anyone here ever tried this?  And how were you able to get the output?


0 Comments   [ + ] Show comments

Answers (1)

Posted by: tomciuu 1 week ago
White Belt
0

Hi. Use Powershell and pipe the output to Select-String cmdlet.

Simple example (run within powershell):

dsregcmd /status | Select-String -Pattern "IsUserAzureAd"


If you pack it into foreach statement with list of machines and sprinkle desired output titles in text file after -Pattern, than you might just end up with what you need. Next you could put the output into variables, append each iteration to csv file and generate a nice report in Excel to get the managers attention for a few seconds :)

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

View more:

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ