Solved

Modifying powershell script to list all old computer in AD which not responding to ping ?

Posted on 2014-12-29
2
176 Views
Last Modified: 2014-12-29
Hi All,

Can anyone here please help me in fixing the one-liner script below to show all offline computers in a certain OU:

Get-QADComputer -SearchRoot "domain.com/Computers" -NotLoggedOnFor 180 -InactiveFor 180 -SizeLimit 0 | Where-Object { (Test-Connection $_ -Count 1 -Quiet) -ne $null }

Open in new window


Thanks
0
Comment
2 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
Comment Utility
Try..
Get-QADComputer -SearchRoot "domain.com/Computers" -NotLoggedOnFor 180 -InactiveFor 180 -SizeLimit 0 | Where-Object {-not (Test-Connection $_.Name -Count 1 -Quiet)}

Open in new window

0
 
LVL 7

Author Comment

by:Senior IT System Engineer
Comment Utility
Wow that's cool and quick
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Disabling the Directory Sync Service Account in Office 365 will stop directory synchronization from working.
Find out how to use Active Directory data for email signature management in Microsoft Exchange and Office 365.
The viewer will learn how to count occurrences of each item in an array.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now