Disable inactive computers in AD

Disable inactive computers in AD

I would be tempted to run it manually in two parts.. that sounds a little cautious I know..

From your DC you can run

CMD ( as admin )
dsquery computer -inactive 8
(this lists the inactive computers- this list can include serveres!!!)

This will list the computers which have been inactive for 8 weeks or more.

Then you can choose to manually select the highlighted computers (from the query) in AD right click disable.
Or run    dsquery computer -inactive 8 | DSMOD computer -disabled yes

This will error if there is nothing to update “dsquery computer -inactive 8 | DSMOD computer -disabled yes”

I would not schedule this to run automatically.. Just in case it bins a server.. even though servers should never been offline for 8 weeks

Steve

Comments are closed.