Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Login script problems

20 Aug 2009   #1
wingnut144

Win7
 
 
Login script problems

We recently moved to a different domain, previous to that, OUR DC had our login script and all worked well.

The login script is defined in our GPO and works well for everyone else (running XP), I'm the only one on Win7 and its not running for me.

Its a simple .vbs script. The odd thing is, when I save the file to my desktop and run the .vbs locally, it runs fine, and maps the drives I need, etc., it just won't run when I log into the domain.

If I log into another machine running WinXP, the login script runs just fine.

Any ideas???


My System SpecsSystem Spec
.
20 Aug 2009   #2
JimKeating

Windows XP and Windows 7
 
 
Logon Script Issue .vbs

I found that if you turn the "User Account Control" settings to the lowest level the GP Scripts will run. We run 2 Scripts. A batch file to copy icons to the desktop and a .vbs script to map the drives. The batch file had no problem running but it was a different story with the .vbs script.

There is probably an easier way to allow the .vbs script without dumbing down the "User Account Controls" Does anyone know how?

Thanks, JK
My System SpecsSystem Spec
16 Sep 2009   #3
mattlok

Windows 7 with windows 2003 R2 SBS premium
 
 
Same problem as well but check this out

Hey guys,

i am having the same problems will my logon script for mapped drives through GPO.

although i am using a logonscript.cmd file instead with simple net use command.

but this link explained a bit better what is going on because it is related to the UAC and token for each user:

Logon script that map network drives failes to apply if UAC is on. - Vista Forums

I know from my end if i run the logonscript.cmd as the domain user (even though it belongs to the local admin group), the cmd windows shows as running as local administrator account even though i am logged in as domain user.

the funny thing is if i run the cmd prompt manually (from the run command or from accessories group) it will launch as domain user and i can manually type in the net use command to map the network drives:

echo off
Title Login in Process for %Username%... Please Wait.
net time \\ABC01 /set /yes
net use H: /d
net use K: /d
net use K: \\ABC01\CompanyData\Accounting /persistent:no >nul
net use M: /d
net use M: \\ABC01\CompanyData\Management /persistent:no >nul
net use P: /d
net use P: \\ABC01\CompanyData\Public /persistent:no >nul
net use X: /d
net use X: \\XYZVM\images /persistent:no >nul

RUNDLL32 PRINTUI.DLL,PrintUIEntry /in /n\\MARKLYN01\hp2200

-----------------------------------------------

There's no rocket sceince to the script. However based on everything i read so far it has to do with the UAC and the token per user it runs.

Other people said to use this regedit:

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System]
"EnableLinkedConnections"=dword:00000001

but it never worked for me at all for both vista and windows 7

also a technet post claims to use the launchscript.wsf - which the script is broken.

Even another user which is in the link above had made changes to the launchscript.wsf and made it work but had to add another script.

However as much as a success to that user, none of the solution works for me here in our environment.

Hopefully someone can ringout a universal solution that works for at least 75% of common network environments. (i know each environment is different be we all have common denominators in GPO)

Please help!!!
My System SpecsSystem Spec
.

05 Apr 2010   #4
Opportunitor

Windows 7 Ultimate (64 Bit) - Version 6.1
 
 

Interesting topic.
Does anyone have found a solution yet?
My System SpecsSystem Spec
05 Apr 2010   #5
WindowsStar

Windows 7 Enterprise (x64); Windows Server 2008 R2 (x64)
 
 

We found that .CMD scripts have a hard time running in a domain because of UAC. However .VBS seem to work fine, unless you are doing something that requires Admin Rights. All of our XP and 7 machines work fine with the .VBS logon scripts.
My System SpecsSystem Spec
06 Apr 2010   #6
Opportunitor

Windows 7 Ultimate (64 Bit) - Version 6.1
 
 

@WindowsStar: Okay. thanks for reply
At this moment I'm busy to finetune some vbs- and kixtart scripts to improve the logon processes. Automated logonscripts are awesome! Maybe you want to post some examples of vbs-logonscripts that works well on your W7-systems?

Here's only a workgroup-based network, rather then a domain, consist of 1 W7-64 and 3 XP-SP3 workstations - where W7 also acts as server . Up to now their cooperation seems well because all workstations shares the same (local) groups, users, grouppolicy- and secpol settings.

Although I already consider a home-server for two years, W7 offers many administrative tools to discover yet. Now I try to manually set these stuff. Actually, I really would prefer a central AD with associated advantages like dsa.msc, gpmc.msc and access-based enumeration, without install a server version.

By the way- I just left the UAC alone for weeks ago. Too much hassle for me
My System SpecsSystem Spec
06 Apr 2010   #7
WindowsStar

Windows 7 Enterprise (x64); Windows Server 2008 R2 (x64)
 
 

Quote   Quote: Originally Posted by Opportunitor View Post
@WindowsStar: Okay. thanks for reply
At this moment I'm busy to finetune some vbs- and kixtart scripts to improve the logon processes. Automated logonscripts are awesome! Maybe you want to post some examples of vbs-logonscripts that works well on your W7-systems?

Here's only a workgroup-based network, rather then a domain, consist of 1 W7-64 and 3 XP-SP3 workstations - where W7 also acts as server . Up to now their cooperation seems well because all workstations shares the same (local) groups, users, grouppolicy- and secpol settings.

Although I already consider a home-server for two years, W7 offers many administrative tools to discover yet. Now I try to manually set these stuff. Actually, I really would prefer a central AD with associated advantages like dsa.msc, gpmc.msc and access-based enumeration, without install a server version.

By the way- I just left the UAC alone for weeks ago. Too much hassle for me
You may NOT want to use Kixtart due to the many issues you will run into with UAC. Plus you will have to pre-install it on every machine before you can use it. It is best to use pure Microsoft VBS for your scripts. You will have the least amount of trouble.

What type of scripting examples are you wanting???
My System SpecsSystem Spec
07 Apr 2010   #8
Opportunitor

Windows 7 Ultimate (64 Bit) - Version 6.1
 
 

Hi there,

Well, your warnings about Kixtart will be appreciated. I remember how powerful they were, explained by a fellow IT-collegue at work years ago.
What I want to achieve is to assign a per-user .vbs or .bat loginscript, stored in a central folder and invoked every time the user logs on (set via lusrmgr.msc). This page (Windows Logon Scripts - VBScript examples to create printers, map network drives) already seems to be a good source to me.

The script must perform at least the following tasks (per-session):
-remove and/or rename existing local and network drives;
-map c.q. attach multiple network drives and connect to different networkprinters;
-set access-based enumeration c.q. hide and restrict unused drives;
-set userpolicies to restrict or personalize desktop, start menu, taskbar, regedit et cetera.

Also I want to set up a mandatory or roaming profile for some specific users (as Windows SteadyState provides).

Thanks in advance!
My System SpecsSystem Spec
07 Apr 2010   #9
WindowsStar

Windows 7 Enterprise (x64); Windows Server 2008 R2 (x64)
 
 

I just want to clarify you want to do this without a domain? or you are considering setting up a domain?
My System SpecsSystem Spec
08 Apr 2010   #10
Opportunitor

Windows 7 Ultimate (64 Bit) - Version 6.1
 
 

Quote   Quote: Originally Posted by WindowsStar View Post
I just want to clarify you want to do this without a domain? or you are considering setting up a domain?
At this moment within a workgroup. AFAIN, setting up a domain is not possible in a W7 client without a Windows Server version. I just want to simulate the Server environment much as possible
My System SpecsSystem Spec
Reply

 Login script problems




Thread Tools




Similar help and support threads
Thread Forum
login problems
Hello, Since I just logged in I got into a different desktop. This afternoon I shut down my pc like any other time, so not any different than normal. But when I logged in into my own account, with my own password, I got a total new account, new desktop, everything was gone, as if I was in a new...
General Discussion
Turning on login script i.e. at Starbucks cafe
hi guys, It seems I disabled something but when I connect to any wireless networks that require a browser login, i.e. at a starbucks, hotels, etc I don't get by default their login page when launching any browser (ie, chrome, ff), in most cases I have to type 192.168.0.1, for me is fine but...
Browsers & Mail
run executable (script) @ startup / login (before explorer.exe?)
Hi, everything's going well, fixing an issue a day, but the solution to this continues to elude me... I have a (taskbar) toolbar (like quick launch) that shows the folder contents (as usual, like quick launch) on the toolbar. The target folder resides on a virtual volume, that's always...
General Discussion
IE8 Script errors and other problems
I have been running IE8 with no issues since I got my computer 14 months ago. Now things have gone bad. I am getting "Out of memory at line xx" and "Stop running this script? A script on this webpage is causing your browser to run slowly..." It seems to occur on one specific website and...
Browsers & Mail
Auto Login Script For Wifi Hotspots?
I've been trying to find a way for the follwoing to happen; My mum and dad have a static caravan and have paid for the sites wifi for the year, which works fine. When you open a browser it autoredirects you to a login page which needs your username and password. This is fine for their...
Network & Sharing


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 09:26.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App