Page 1 of 1 1
Topic Options
#146983 - 2005-09-01 06:11 PM Unable to launch batch from UNC path
MLoughran Offline
Fresh Scripter

Registered: 2005-08-17
Posts: 12
\\sop-dc1\netlogon
cmd.exe was started with the above path as the current directory.
UNC paths are not supported. Defaulting to windows directory.

C:\windows> kix32 er.kix

I have used group policy to make the call to this the batch file that calls the kix file. However, it doesn't run because of the above error. Anyone know exactly how I can resolve this issue. I'm running in a mixed 2000/xp user environment and a 2003 Domain controller. The kix file that is being called is simply mapping drives with IF statements:

small sample:
If InGroup("San Francisco IBG")

USE G: "\\FILERA\USERS\"
USE H: "\\FILERA\IBG USERS"
use l: "\\ca-dc\sys"
use n: "\\ca-dc\investment banking\%USERNAME%"
use o: "\\ca-dc\v2"
use t: "\\ca-dc\database"
use z: "\\filera\IBG Users\California Users\%USERNAME%\notes"
EndIf
If InGroup("Chicago IBG")
USE G: "\\FILERA\USERS\"
USE H: "\\FILERA\IBG USERS"
use l: "\\chi-dc\sys"
use n: "\\chi-dc\investment banking\%USERNAME%"
use o: "\\chi-dc\v2"
use t: "\\chi-dc\database"
use z: "\\filera\IBG Users\Chicago Users\%USERNAME%\notes"
EndIf
If InGroup("Atlanta IBG")..........

Top
#146984 - 2005-09-01 06:29 PM Re: Unable to launch batch from UNC path
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
well, if you wanna use batch, you need to call kix properly with the full path.
_________________________
!

download KiXnet

Top
#146985 - 2005-09-01 06:50 PM Re: Unable to launch batch from UNC path
MLoughran Offline
Fresh Scripter

Registered: 2005-08-17
Posts: 12
don't think thats it, b/c when i launch the batch file that calls the kix file, even with the full path to the location of the file

\\sop-dc1\netlogon\kix32 ER.kix

I still get the same error, saying UNC paths are not supported. The file then tries to run from my windows directory, at which point I get the error:
ERROR: failed to find/open script [ER.kix]!

Top
#146986 - 2005-09-01 07:07 PM Re: Unable to launch batch from UNC path
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
that is exactly the problem!

you can't make batch to run from UNC, ever.

but you can point to your kix exe and the script with proper path.
_________________________
!

download KiXnet

Top
#146987 - 2005-09-01 08:11 PM Re: Unable to launch batch from UNC path
MLoughran Offline
Fresh Scripter

Registered: 2005-08-17
Posts: 12
alright, I now have the file launching as so:

\\sop-dc1\netlogon\kix32 \\sop-dc1\netlogon\IBG.kix

this makes explicit calls from the users DOS prompt so the UNC path is no longer an issue. As a test, I mapped the drives to another DC and ran my script again. The first part of my script removes any previously loaded shares
ie.....USE G: /DELETE /PERSISTENT
USE H: /DELETE /PERSISTENT
USE I: /DELETE /PERSISTENT
USE L: /DELETE /PERSISTENT
USE N: /DELETE /PERSISTENT
USE O: /DELETE /PERSISTENT
USE T: /DELETE /PERSISTENT
USE Z: /DELETE /PERSISTENT

This part ran, because after I make a call to it, I have no more network shares. But it doesn't finish the script or it doesn't recognize that my user is a member of one of these groups because none of the shares are getting mapped. any other suggestions
the second part of my script was previously posted.

Top
#146988 - 2005-09-01 08:30 PM Re: Unable to launch batch from UNC path
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
well, you can do simple checking to find out why it doesn't work like you want it to...

If InGroup("San Francisco IBG")
"Ingroup SF IBG" ?
net use k: "\\some\some"
@error "- " @serror ?
else
"not in SF IBG" ?
endif
_________________________
!

download KiXnet

Top
#146989 - 2005-09-01 10:11 PM Re: Unable to launch batch from UNC path
MLoughran Offline
Fresh Scripter

Registered: 2005-08-17
Posts: 12
Much obliged. Had already resolved the issue, although the code you posted would have helped. It turns out I was using the registered domain name rather than the logon name of the group. So my kix file was running, but the groupname was all wrong. I hate people that don't stick to naming conventions. Thanks again
Top
Page 1 of 1 1


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

Who's Online
1 registered (Allen) and 675 anonymous users online.
Newest Members
batdk82, StuTheCoder, M_Moore, BeeEm, min_seow
17885 Registered Users

Generated in 0.063 seconds in which 0.028 seconds were spent on a total of 12 queries. Zlib compression enabled.

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