Code from Deji... That falls pretty straight forwardly into the you are in trouble category I think....
:o) -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Monday, June 21, 2004 3:15 PM To: [EMAIL PROTECTED] Subject: RE: [ActiveDir] PC move depending on how you look at it, you are either in luck, or you are in trouble :) enjoy Sincerely, Dèjì Akómöláfé, MCSE MCSA MCP+I Microsoft MVP - Directory Services www.readymaids.com - we know IT www.akomolafe.com Do you now realize that Today is the Tomorrow you were worried about Yesterday? -anon ________________________________ From: [EMAIL PROTECTED] on behalf of joe Sent: Mon 6/21/2004 11:19 AM To: [EMAIL PROTECTED] Subject: RE: [ActiveDir] PC move You could also have the script look at the dnsHostName, do a lookup (fairly easy in perl, not so sure for vbscript) and then do the move. Keep in mind people who move about from location to location. Also keep in mind what do you do with machines that don't have a host name that can be looked up for some reason or are in an IP you aren't expecting. I can understand where someone would do this. Say you originally didn't have a clean site structure for where machines went for admin organization and you all of a sudden want to do so. Like say for instance you walk into a location that gave all admins the ability to create machines in computers and then someone realized that gave all admins rights on all machines and now they want to break them up to delegated OUs with good controls... Etc etc. joe -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Tony Murray Sent: Monday, June 21, 2004 7:41 AM To: [EMAIL PROTECTED] Subject: Re: [ActiveDir] PC move I don't know of any easy way to do this. As the IP address information is not stored in AD, I guess you would need to do this with a script (probably using WMI) to directly query each machine who's object is in the first OU and then perform the move using ADSI based on the retrieved IP address information. If the PCs get their IP allocated by DCHP then you'd have to derive the IP information from the DHCP server(s). I can't think of a good reason why you would want to do this in the first place? Typically you create OUs for delegation of administration and/or Group Policy application. If you're doing this for GPO purposes you could consider defining separate sites based on the IP subnets and then applying Site GPOs. Tony ---------- Original Message ---------------------------------- Wrom: EGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCD Reply-To: [EMAIL PROTECTED] Date: Mon, 21 Jun 2004 15:45:01 +0530 I want to move PC's from one OU to another OU based on IP Subnet. Details : I want to move all PC's whose IP is 10.238.10.* and 10.238.20.* from "Office" OU to "Home" OU. I want to do this in bulk command. Regards, Dinesh Tashildar ________________________________________________________________ Sent via the WebMail system at mail.activedir.org List info : http://www.activedir.org/mail_list.htm List FAQ : http://www.activedir.org/list_faq.htm List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/ List info : http://www.activedir.org/mail_list.htm List FAQ : http://www.activedir.org/list_faq.htm List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/ List info : http://www.activedir.org/mail_list.htm List FAQ : http://www.activedir.org/list_faq.htm List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/