[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

domainroot, forestroot and specifying a domain

Posted on 2010-11-17
4
Medium Priority
?
675 Views
Last Modified: 2012-05-10
Hi guys hope you can help.
We have several subdomains, and when I run the following:

dsquery * domainroot -filter "(&(objectCategory=Computer))" -attr Name operatingSystem operatingSystemServicePack -limit 0

It targets the current domain I am in.

What Id like to do is to change the domain focus to point to another subdomain and perform the same query against that subdomain.

Any help greatly appreciated.
0
Comment
Question by:Simon336697
[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
  • 2
4 Comments
 
LVL 65

Accepted Solution

by:
RobSampson earned 2000 total points
ID: 34160436
Hi, I don't have any subdomains, but can you use:
dsquery * "DC=subdomain,DC=domain,DC=com" -filter "(&(objectCategory=Computer))" -attr Name operatingSystem operatingSystemServicePack -limit 0

Regards,

Rob.
0
 
LVL 1

Author Comment

by:Simon336697
ID: 34199996
Thanks Rob that is awesome
0
 
LVL 1

Author Comment

by:Simon336697
ID: 34200004
Rob can I ask you, are you porting a lot of your scripts over to Powershell, and using Powershell instead of vbs now?
0
 
LVL 65

Expert Comment

by:RobSampson
ID: 34201039
Hi.  I'd like to be, but no, I don't know PowerShell and don't have the time to learn it at the moment.  The time spend in writing a PowerShell script would take me about five times as long as writing a VBS at the moment, despite the fact it would be MUCH less code.

One day I hope to find some time to learn PowerShell, but for now, still going with VBS.

Rob.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

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…
Had a business requirement to store the mobile number in an environmental variable. This is just a quick article on how this was done.
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

656 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