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

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 Windows 7 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

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

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

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

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

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 Windows 7-systems?

Here's only a workgroup-based network, rather then a domain, consist of 1 Windows 7-64 and 3 XP-SP3 workstations - where Windows 7 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, Windows 7 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

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 Windows 7-systems?

Here's only a workgroup-based network, rather then a domain, consist of 1 Windows 7-64 and 3 XP-SP3 workstations - where Windows 7 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, Windows 7 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

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

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

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 Windows 7 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 for2: Login script problems
Thread Forum
My VBS login script kept failing Network & Sharing
IE8 Script errors and other problems Browsers & Mail
Auto Login Script For Wifi Hotspots? Network & Sharing
I Need Help To Reorder The Context Menu Script In Script Form? Customization
Login Script Help Network & Sharing
Runing once an script before any user login Performance & Maintenance

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 11:51 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33