Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


A lil help with a DC finder script.

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,49082
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> A lil help with a DC finder script.
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 A lil help with a DC finder script. - 7/5/2007 5:32:31 AM   
  morten_leth

 

Posts: 2
Score: 0
Joined: 7/5/2007
Status: offline
Hey guys

I'm currently in the process of making a HTA to create users with, this i actually have all done, and they can make users and so forth.
My only problem is that they have to be able to put on homedrives, and homefolders on the users, which is no problem either, the problem is the right's on the folder.

My domain is a pretty large one i'd say, we have 1 root domain with 5 subdomains, and this HTA has to be able to create users, and homefolders cross-domain.
When i am in domain A, and create a user in Domain B, i get everything created as it should, but when i put on rights to the folder (am using fileACL atm, the EXE) it gives me an error No SID for the user, the reason for that beeing is that the DC i get the user from when trying to set the rights, is in domain A (hence the reply my domain hasn't replicated yet).

In fileACL i can set a targetDC, which is where it takes the user from, now here's the problem.
I want to locate the nearest DC in the domain i have created the USER, i don't think i can use a random DC cause we have differen't sites in our infrastructure and could wind up having the same problem.
And i don't want to hardcode anything in our HTA, cause we have made it untill now without doing that, and it would be silly cause i now there is a solution to this problem outthere.


      


i thought of doing something like taking one of the servers i get back here, but again i don't know what happens if i get a DC outta the site where i created the user.
What would be really cool is if i could get the server where the user was created (don't want to hardcode the place where the user get's created).

Does anyone have any great idea's on how i get going again, this problem is actually the last outta many problem which i have solved in my HTA, and when i get this done it's finished.

/Leth
 
 
Post #: 1
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> A lil help with a DC finder script. Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts