[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 117
  • Last Modified:

Windows 2000 Server Groups

I have a over 3000 users running computers of various speeds.  I need to have a batch file for only 20-30 users.  I have these users in a group but i don't know how to make that batch file only run for that group (in addition to the script that runs for ALL users).

this is urgent.

thanks
0
earthbond
Asked:
earthbond
  • 2
  • 2
1 Solution
 
nick_sCommented:
What environment are you in?
Are you using Kix for your scripting?

Nick
0
 
oBdACommented:
"ifmember.exe" from the Resource Kit is your friend:
Assuming this is your logon script, copy ifmember.exe to your netlogon directory and put something like that that in your general script:

...
ifmember.exe YourSpecialGroup
if not errorlevel 1 goto NoSpecial
call YourSpecialBatchFile.cmd

:NoSpecial
...
0
 
earthbondAuthor Commented:
Some of the machines are only used to keep the furniture from floating away and many of the others ought to be given to musuems.  Still its what we have and I do not want to at more lines to my batch file if possible.  (Except of course if your one of those 20-30 users--and for them I would like to have an entirely seperate batch file... so that in the future the original "main" login script can be edited freely.)  I am using Windows 2000 Server and i have not idea what Kix is and since I am not the OverLord of this domain I will not be able to download more software (unless ABSOLUTLY neccessary)...  Basically what I am asking for is a way to do this per this group at the server level.  I am getting through browsing this site many suggestions on group policies but I don't know anything about them or how to set them up (although I do have the groups set up)..
0
 
oBdACommented:
Actually, I don't quite see your problem.
If I understand you correctly, you have a common logon script for all users, and you have an additional logon script for only a certain group of users.
If you want both scripts to run for this group, there is no other way than to call one script from the other.
So basically you have two options:
1. All users have the same logon script, and if the user logging on is member of the group, the other script is called from within the common script.
2. You change the logon script for members of the special group to be the special script, and then you call the common script from within your special script.

To avoid confusion, the first solution is definitely the better one.
Assuming your common script is a batch script, all you have to do is adding the lines above at the appropriate position (probably rather at the end of it).

Group policies don't offer any additional capabilities for logon scripts that seem to be really useful in your case. Especially if you don't have experience with them, I'd recommand reading up on them and testing their results before actually implementing them (especially since, given your hardware description, probably not all of your clients are running W2k/XP).

It might be useful if you clue us in a bit more about your surroundings.
0
 
earthbondAuthor Commented:
I will give you the points oBdA but actually I figured it out.  If you create an OU group (Orginizational Unit/Group)(we'll call this first one GROUPM) in which to put your main bulk of users.  Then create an OU group inside GROUPM (we'll call it SPECIALGROUP).  Then when you right click on the GROUPM icon-go to the third tab- and add a policy.  in that policy you can specifiy a logon/logoff script and many other options for the members in the OU group.  You can then create a seperate policy for SPECIALGROUP (which is a sub OU group of GROUPM).  If you specifiy a logon script for both the main OU group and sub OU group they well run heirarchically (however you spell it).  Meaning that the logon script (and the other policy settings) for GROUPM will run first then the logon script for the sub group SPECIALGROUP will run next (and the policies (this time from SPECIALGROUP) will be reapplied [i don't know which would win in a conflict-never tried it]).  NONE of that is visible (nor will a pause statement allow the cmd dialog to remain after windows finishes logging on).  After all of that then will the indiviual's logon script (if specified) will be run (visibly).  Any way I spent all day and thats what I come up with.  Just in case anyone else runs into this problem.  NOTE: no policiy but the main domain policy can be applied to an OU group.
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now