Announcement

Collapse
No announcement yet.

Logon/Logoff Script Best Practices?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Logon/Logoff Script Best Practices?

    I see a lot of vbscript being used is that the way to go instead of regular batch file commands?

    Where do you store your scripts?

    the default logon/logoff script location is a pain to get to when you have multiple GPOs and want to make changes IMO.

    I was thinking of putting all scripts in one folder like Netlogon and simply point to them in the GPO for each group, is that a bad idea?

    I have to make logon scripts that add shared printers, set default printers and connect a shared folder for each of my Security Groups.

    also logoff scripts that remove them.

    I already have scripts to do these using
    Code:
    rundll printui.dll xxxxx
    and
    Code:
    net use xxxxx
    but would appreciate any advice on how best to do this.

  • #2
    Re: Logon/Logoff Script Best Practices?

    Originally posted by channer View Post
    the default logon/logoff script location is a pain to get to when you have multiple GPOs and want to make changes IMO.
    I was thinking of putting all scripts in one folder like Netlogon and simply point to them in the GPO for each group, is that a bad idea?
    Me too, I use the following share to link to the Startup-, Logon-, Logoff- and Shutdown scripts:
    \\domain.local\sysvol\domain.local\scripts (what actually is the domain.local\netlogon folder)
    rather than in one of the \\domain.local\sysvol\domain.local\policies\... subfolders
    In the netlogon folder I created 4 subfolders for the 4 different scripts and a few 'include/lib folders' that are supporting some scripts with utils and other kind of stuff.
    It is just a personal choice! I am not telling this is better.
    (Note, the NetLogon share is probably not present by default when using Windows Server 2008 domain -> http://support.microsoft.com/kb/947022)


    Originally posted by channer View Post
    I see a lot of vbscript being used is that the way to go instead of regular batch file commands?
    Use a batch if you are best in writing batches. When batches become to long and complicated or for some reasons unsufficient, then learn to use VBS.
    If you like puzzeling with vbs code anyway just go ahead start with converting the existing batches to vbs.
    The third file type that is supported by a GPO to launch as a script are exe files - so you can also run KIX login scripts too. Or, buy an advanced programming application what let you compile the created code to an exe file and learn the script language used by that application.


    Originally posted by channer View Post
    I have to make logon scripts that add shared printers, set default printers and connect a shared folder for each of my Security Groups.
    also logoff scripts that remove them.
    <>
    would appreciate any advice on how best to do this.
    Looking for a batch or vbscript


    \Rems
    Last edited by Rems; 5th May 2009, 18:12.

    This posting is provided "AS IS" with no warranties, and confers no rights.

    __________________

    ** Remember to give credit where credit's due **
    and leave Reputation Points for meaningful posts

    Comment

    Working...
    X