Posts

Showing posts from February, 2024

WMIC : Invalid Global Switch - The How and Why Cookbook

Image
 WMIC says "Invalid Global Switch" Why does it say that when you use the /NODE switch?  It's because WMIC really wants the full IP address of the remote computer, not the name. Here's an example of it: This is the right way to do it, to prevent "Invalid Global Switch" The WMIC Cookbook In these examples, we will write all output to a file called a.out. First one will be written, others will be appended. # --------- CUT HERE ----------------------- # A powershell script by Uncle Joe # To append to the file, use /APPEND instead of /OUTPUT $username="talladega\lets_go_brandon" $password="Nascar22" # Get Computer Name wmic /NODE:192.168.0.143 /OUTPUT:a.out /USER:${username} /PASSWORD:${password} computersystem get model,manufacturer,name,username # Disk Check wmic /NODE:192.168.0.143 /APPEND:a.out  /USER:${username} /PASSWORD:${password}   logicaldisk list full # CPU Check: wmic /NODE:192.168.0.143 /APPEND:a.out  /USER:${username} /PASSWORD...

Lot of this message: No suitable default server credential exists on this system

How to fix this "No suitable default server credential exists on this system" The Fix The fix was done by Dell Server support using Powershell command  New-SelfSignedCertificate -CertStoreLocation Cert:\LocalMachine\My -DnsName "ims.local" -FriendlyName "MySiteCertIMS" -NotAfter (Get-Date).AddYears(10) Then finding the newly created certificate using MMC under Console Root, Certificates (Local Computer), personal, certificates and copying to Trusted Root Certification Authorities, Certificates.