Solved

dsquery: find inactive users of a particular group

Posted on 2006-06-08
2
1,801 Views
Last Modified: 2007-12-19

I'm trying to get a list of all users who havn't loggedin for more than 4 weeks and are members of the VPN group:

my first attempt:
dsquery user domainroot -limit 0 -inactive 4 | dsget user -memberof | find /i "CN=VPN"

the issue being that the filters take out so much, the resulting info is useless (listing group containers witih no user affiliation) e.g.
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"
   "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com"

How can I construct a usefull query?
0
Comment
Question by:Marketing_Insists
[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 51

Accepted Solution

by:
Netman66 earned 500 total points
ID: 16866657
Try:

dsget group "CN=VPNc,OU=company Worldwide,DC=corp,DC=company,DC=com" -members | dsquery user -inactive 4


0
 

Author Comment

by:Marketing_Insists
ID: 16915455
Thhanks!
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

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

Suggested Solutions

The HP utility "HP Lights-Out Online Configuration Utility for Windows Server 2003/2008" could be of great use when it comes to remotely configure a HP servers ILO WITHOUT rebooting the server. We would only need to create and run scripts using thi…
Learn about cloud computing and its benefits for small business owners.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

739 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