Find Computers Not Logged In for 30 Days Using PowerShell
To find computers not logged in for 30 days with PowerShell, run Search-ADAccount with -AccountInactive, -ComputersOnly and a 30-day time span: It needs the ActiveDirectory module. Below I set that up, show the Get-ADComputer alternative, explain why the dates can be off by up to two weeks, and cover Microsoft Entra ID devices. My test … Read more