Files
docs/scripts/Identity and Certificates/Active Directory/Reports/Inactive Computers.md
T
nicole 289769a601
Automatic Documentation Deployment / Sync Docs to https://kb.bunny-lab.io (push) Successful in 8s
Restructured Documentation
2026-09-05 14:08:43 -06:00

614 B

tags
tags
PowerShell
Reporting
Scripting

Purpose

This document records the procedure for inactive computers. Follow the environment assumptions and commands below.

$DaysInactive = 30
$time = (Get-Date).Adddays(-($DaysInactive))
Get-ADComputer -Filter {LastLogonTimeStamp -lt $time} -ResultPageSize 2000 -resultSetSize $null -Properties Name | Select Name