Solved

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

Posted on 2014-12-29
2
187 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
ID: 40523198
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 8

Author Comment

by:Senior IT System Engineer
ID: 40523208
Wow that's cool and quick
0

Featured Post

How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Windows functions GetTickCount and timeGetTime retrieve the number of milliseconds since the system was started. However, the value is stored in a DWORD, which means that it wraps around to zero every 49.7 days. This article shows how to solve t…
Recently, Microsoft released a best-practice guide for securing Active Directory. It's a whopping 300+ pages long. Those of us tasked with securing our company’s databases and systems would, ideally, have time to devote to learning the ins and outs…
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

751 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