Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Login script for Win2003 Server using the IF condition to determine if a user is in a group or not to map network drives

Posted on 2004-09-23
3
Medium Priority
?
272 Views
Last Modified: 2012-06-21
Hi

I want to map network drives based on if a user is in a particluar user group in AD . I guess using the login script ie dos bacth file , net use command

ie I gave a user group called sales

I login as joe bloggs who is in the sales group in the local domain  . The login script does a if statement to determine if Joe Bloggs is in that group or not

ie  " if  "user" Part of  "  Sales Group" Then
              net use L: \\Server\Share
                 else
                  End


Ie something like that I suppose ???

Also can ths work across multiple domains ? ie map a drive to another share on a another server in a different Domain ?


 
 
0
Comment
Question by:Davidedi
3 Comments
 
LVL 7

Accepted Solution

by:
sj_hicks earned 375 total points
ID: 12140066
The IFMEMBER utility included in the NT/2000 resource kit will do this.  See info at http://www.win2000mag.com/Articles/Index.cfm?ArticleID=5869

An alternative to using a batch file login script is to use a VBScript.  Do a web search and you should find plenty of samples.

You should be able to map drives across domains providing the appropriate trusts are in place.
0
 

Expert Comment

by:kdb01
ID: 12140151
Might help ??? I create containers (OU), I just put a straight dos batch with the proper net use in the container i want to give the specific shares to. I keep the groups to assign access rights only. Makes my life easier. I used to use the IFMember utility back in winNT4 and it works fine.  
0
 
LVL 3

Expert Comment

by:onesquin
ID: 12146214
Remember with login scripts... LESS IS MORE.  If loops and that are great... BUT if you can break it down into OUs and assign login scripts to each OU group logins will be quicker and less complex.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

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…
by Batuhan Cetin Within the dynamic life of an IT administrator, we hold many information in our minds like user names, passwords, IDs, phone numbers, incomes, service tags, bills and the order from our wives to buy milk when coming back to home.…
Screencast - Getting to Know the Pipeline
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…

879 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