Re: neverending script problem

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Mike Koch (mikey_at_NOSPAMebgames.com)
Date: 11/17/04


Date: Wed, 17 Nov 2004 11:42:42 -0500

Found the problem. First, I was wrong about where the script was getting
stuck. After removing an "on error resume next" statement (dumb), I could
easily see the script die with an ADODB.Connection error (this portion was
not in the snippet I included in my previous message). Upon further research
and testing, it appears that the "oledb32.dll" file was not upgraded during
the Windows 2003 upgrade, as it was still at version 2.71, instead of
version 2.80.

The solution was to download the latest MDAC files, extract the oledb32.dll
file, copy it to the proper locations on the server, then register the dll
with the system. The script works perfectly now.

Mike

"Mike Koch" <mikey@NOSPAMebgames.com> wrote in message
news:%23EiiKkLzEHA.352@TK2MSFTNGP14.phx.gbl...
> I've got an odd problem here, involving a login script and a freshly
> upgraded server.
>
> The login script has been in use for almost two years, and has not been
> modified recently. It works just fine on every machine in the domain,
> except one. On this one, it gets stuck in a loop, using 50% CPU time until
> I kill it in task manager.
>
> Up until this past Saturday, the server was running Windows 2000 Server
> Standard w/ SP4 and Exchange Server 2000 Enterprise Edition. In this
> configuration, the login script worked just fine.
>
> On Friday night, the server was upgraded to Exchange Server 2003
> Enterprise Edition and SP1. No problems were encountered during the
> upgrade, and the Exchange server is working perfectly.
>
> On Saturday evening, the server was upgraded to Windows Server 2003
> Standard Edition, plus all critical hotfixes and patches from
> windowsupdate. No problems were encountered during the upgrade, and aside
> from this script problem, the server is working perfectly.
>
> When any administrator logs on, the server becomes sluggish, and when task
> manager is opened, there are two instances of cscript.exe running, and
> each one is using close to 50% of CPU, which explain the sluggishness.
> Kill those processes and the server returns to normal.
>
> The script runs fine on every other machine in the domain, be it Windows
> 2000 Pro, Windows XP Pro, Windows 2000 Server, or Windows Server 2003.
>
> The script in question does nothing more than determine the user's group
> memberships, then maps drives accordingly. Here's a snippet of the code:
>
> dim ousr, nuser, ogrp, domain, username
> domain = "MyDomain"
> set nuser = wscript.createobject("Wscript.network")
> username = nuser.username
> set oUsr = getobject("WinNT://" & domain & "/" & username & ",user")
> set Grp = oUsr.Groups
> GrpID = oUsr.PrimaryGroupID
> GrpName = ""
>
> '*** Build Query Filter for the search for all the groups that the user is
> a member of.
> QueryFilter = "(|"
> for each Item in Grp
> NT4Name = replace(Item.ADsPath,"WinNT://","")
> tempArray = split(nt4Name,"/")
> NT4Name = tempArray(1)
> QueryFilter = QueryFilter & "(samAccountName=" & NT4Name & ")"
> next
> QueryFilter = QueryFilter & ")"
>
> Near as I can tell, the script never gets out of thew above for...next
> loop, which doesn't make sense, since the user only has so many groups -
> no more than 10 or 12 at most, usually less.
>
> Since the script works on every other mahcine in the domain, I'm wondering
> if WSH somehow got hosed during the upgrade. Maybe I'll try downloading
> and installing the latest version of WSH, but in the mean time, I thought
> I'd throw this out for discussion, to see if anyone else has any ideas.
>
> Thanks,
> Mike
>
>



Relevant Pages

  • Re: Windows/Macro Language Info?
    ... The point is that malware is often using Windows _features_. ... I totally understand the difference between client and server side (and you ... subverted by script code (the facilities to change file size, dates, etc. ...
    (comp.lang.cobol)
  • RE: NFS on w2k3 server question
    ... new Windows 2K3 server and it will work properly after migrating from ... Window NT4.0 to Windows 2K3. ... logon script migration is specific to how the logon ... it is recommended that you contact Microsoft Customer Support ...
    (microsoft.public.windows.server.migration)
  • Re: Same Internal Server Error from last two days
    ... I am trying to run a Hello World Perl Script in Apache 2.2. ... But its constantly giving me Internal Server Error.The script ... # have to place corresponding `LoadModule' lines at this location so the ...
    (perl.beginners)
  • Re: Same Internal Server Error from last two days
    ... I am trying to run a Hello World Perl Script in Apache 2.2. ... But its constantly giving me Internal Server Error.The script Runs perfectly fine from the command prompt. ... # This is the main Apache HTTP server configuration file. ... LoadModule actions_module modules/mod_actions.so ...
    (perl.beginners)
  • Re: Windows 2008 Limitlogin
    ... We are using windows 2008 64 bit Enterprise, we are trying to limit concurrent user login using limit login but unfortunetely always fail. ... I'm one of the people that Paul was referring to who has written a script to control concurrent sessions. ... It currently prevents regular users from logging in more than once by first warning them of where their other session exists and then uses WMI to log the user off forcefully. ... For admins who log in to Windows Server, a separate perl script that ties into a 3rd party perl module must be used because for some reason WMI on Server is ignored. ...
    (microsoft.public.windows.server.active_directory)