ping | I do stuff sometimes.

Ramblings about things.

Archives

List Windows Server OS


I always forget the correct line for listing these things with WMI. Therefore, it’s now perpetuated on Fuffle.net. =) cls $servers = get-content “C:tempserverlist.txt” foreach ($s in $servers){ $gwmi = (Get-WmiObject -ComputerName $s -class win32_operatingsystem -ErrorAction SilentlyContinue).caption write-host “$s – IP:”([System.Net.Dns]::GetHostAddresses($s)) – $gwmi -foregroundcolor “green”} -F

Read More

Powershell Ping


This neat little thing wil test connection for a list of pingable DNS names (URLS, switches, servers, computers, whatever), and output the result in a list with the objects IP address(es). If the ICMP ping does not reach the object, it outputs this and jumps to the next object on its list. Hurray! cls $servers…

Read More

  • Archives