Page 1 of 1 1
Topic Options
#206122 - 2012-11-06 04:57 PM USE command silently failing
CuthbertRumbold Offline
Just in Town

Registered: 2012-11-05
Posts: 4
Loc: USA
Greetings,

I've been using a fairly simple KiXtart logon script for a number of years, mostly just for mapping drives. I have one Windows 7 client however where the drive mapping fails. All it's trying to do is:

 Code:
IF INGROUP("Mumble") = 1
  USE G: "\\file01.example.net\Blurfl"
ENDIF


I've tried DEBUG ON and single-stepping through the script. The conditional succeeds and the USE command is executed, and returns no error, but the drive isn't mapped. Checking @ERROR and @SERROR confirms that there is no error. Nothing in the event log either, but the drive just doesn't get mapped. Other USE statements in the same script all fail the same way.

Maybe this is a Win7 thing? Most (all?) of my other client machines are XP and they seem fine. I did try upgrading KiXtart to 4.63 saw but no change.

The only other clue is this client machine was recently moved to a different domain. A similar script worked fine before the domain change. Not sure why that would matter (it didn't for the XP clients) but who knows?

Suggestions welcomed, I'm a bit baffled. Thanks!

Top
#206123 - 2012-11-06 05:25 PM Re: USE command silently failing [Re: CuthbertRumbold]
Allen Administrator Online   shocked
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4545
Loc: USA
Is this a GPO script?
Top
#206130 - 2012-11-07 04:30 PM Re: USE command silently failing [Re: Allen]
CuthbertRumbold Offline
Just in Town

Registered: 2012-11-05
Posts: 4
Loc: USA
Hi Allen. The batch file that launches the KiXtart script is defined by a GPO, so I suppose, 'yes'. Defined in User Configuration -> Windows Settings -> Scripts (Logon/Logoff).
Top
#206131 - 2012-11-07 06:25 PM Re: USE command silently failing [Re: CuthbertRumbold]
Allen Administrator Online   shocked
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4545
Loc: USA
The problem you are having has to do with the UAC and the GPO script running in the context of a different user than the current user. In XP and below this was not an issue, but from Vista on, it causes the problem of drive mappings and printer mapping not to appear to work.

The options I know that work are: (There is no priority in this list, choose your poison)
1. use a traditional logon script rather than a GPO.
2. use the reghack that MS does not support
3. use something like RunAsInteractiveUser / LaunchApp

Another possibility is turning off UAC on the PC and see if it fixes it, although I have never personally tried that.

The reghack from MS can be found here: http://support.microsoft.com/kb/937624
but notice the warning on that page:
 Quote:

Important This workaround may make your system unsafe. Microsoft does not support this workaround. Use this workaround at your own risk.


RunAsInteractiveUser() can be found here.
http://www.kixtart.org/forums/ubbthreads.php?ubb=showflat&Number=198514#Post198514

If you want more info on this topic, just do board search for EnableLinkedConnections.

Top
#206138 - 2012-11-07 09:33 PM Re: USE command silently failing [Re: Allen]
CuthbertRumbold Offline
Just in Town

Registered: 2012-11-05
Posts: 4
Loc: USA
Thanks very much Allen. The reghack did the trick as a fast confirmation that this is indeed the problem. I'll take a closer look at RunAsInteractiveUser() as a longer term solution.

Sorry if this was a FAQ, I did try some searching of the board before posting but I didn't find quite the right incantation I guess. Thanks and best wishes!

Top
#206145 - 2012-11-08 12:52 AM Re: USE command silently failing [Re: CuthbertRumbold]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
That's a bit odd. I have a Windows 7 Pro x64 box that I certainly do not recall setting this policy change on and I don't set any GPO to do it (99.9% of the desktops are still XP Pro) yet my own computer does have that entry set already.
Top
#206147 - 2012-11-08 02:12 AM Re: USE command silently failing [Re: NTDOC]
Allen Administrator Online   shocked
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4545
Loc: USA
For what it is worth, there was a time when no one noticed that MS didn't support this configuration. It was about two years ago that I remember Glenn mentioning it first, and that reg fix was at least two years old at the time.
Top
#206148 - 2012-11-08 04:17 AM Re: USE command silently failing [Re: Allen]
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
it was known to be unsupported from the start.
but there was no other way than disabling UAC or linkedconnection back in the day.
both were flagged as baaaaad by MS.

end result, MS was the bad thing and we all got our fare share of their bad coding :).
_________________________
!

download KiXnet

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
1 registered (Allen) and 382 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.051 seconds in which 0.021 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org