Page 1 of 1 1
Topic Options
#44470 - 2003-08-25 02:09 PM Using Kixtart to run ez-audit trhough login script
Gary O Offline
Lurker

Registered: 2003-08-25
Posts: 4
Loc: Plymouth, NC
I have written a small script to run EZ-Audit on machines, in which the users are in a specifc group (EZAUDIT), as they log in. I have been able to get the script to run on Windows XP, NT, and 2000. But it does not seem to run on any Windows 95 machines. I have found that I can launch Kixtart from the command prompt and the program will run on Windows 95 clients. Below is the scipt I am using. Any help would be greatly appreciated:

:setcmd
if @INWIN = 1 ; 1 = NT, 2 = Win95
$CMD = "cmd /E:1024 /C" ; e.g., shell "$CMD whatever.bat"
$DllDir = "%SYSTEMROOT%\System32"
else
$CMD = "command.com /E:1024 /C"

endif

:runeza
IF INGROUP("EZAUDIT")
CLS
AT (12,12) "YOUR WORKSTION IS BEING INVENTORIED BY EZ AUDIT"
SLEEP 10
CLS
USE V: /DEL
USE V: "\\ipmcs01\ezaudit"
SHELL "$Cmd V:\ezscan.exe /Auto"
USE V: /DELETE
Return
endif
Return

Top
#44471 - 2003-08-25 02:16 PM Re: Using Kixtart to run ez-audit trhough login script
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
there is no problems foundable in the part you showed.
well, except...

instead of:
code:
:setcmd
if @INWIN = 1 ; 1 = NT, 2 = Win95
$CMD = "cmd /E:1024 /C" ; e.g., shell "$CMD whatever.bat"
$DllDir = "%SYSTEMROOT%\System32"
else
$CMD = "command.com /E:1024 /C"
endif

:runeza
IF INGROUP("EZAUDIT")
CLS
AT (12,12) "YOUR WORKSTION IS BEING INVENTORIED BY EZ AUDIT"
SLEEP 10
CLS
USE V: /DEL
USE V: "\\ipmcs01\ezaudit"
SHELL "$Cmd V:\ezscan.exe /Auto"
USE V: /DELETE
Return
endif
Return

you should use:
IF INGROUP("EZAUDIT")
CLS
AT (12,12) "YOUR WORKSTION IS BEING INVENTORIED BY EZ AUDIT"
USE V: /DELETE
USE V: "\\ipmcs01\ezaudit"
SHELL "%comspec% /c V:\ezscan.exe /Auto"
USE V: /DELETE
endif


see the FAQ forum for more about shell and run and console usage.
_________________________
!

download KiXnet

Top
#44472 - 2003-08-25 02:35 PM Re: Using Kixtart to run ez-audit trhough login script
Gary O Offline
Lurker

Registered: 2003-08-25
Posts: 4
Loc: Plymouth, NC
I made the changes you recommended. I still have the same problem, which I neglected to put in my first post, which is I get a Kernel 32 error when I run the script and it stops executing.
Top
#44473 - 2003-08-25 02:38 PM Re: Using Kixtart to run ez-audit trhough login script
Kdyer Offline
KiX Supporter
*****

Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
Gary,

Windows 9x, will need COMMAND.COM, not CMD.EXE.

COMMAND.COM is also available on nt-class machines too..

Thanks,

Kent

[ 25. August 2003, 14:41: Message edited by: kdyer ]
_________________________
Utilize these resources:
UDFs (Full List)
KiXtart FAQ & How to's

Top
#44474 - 2003-08-25 03:15 PM Re: Using Kixtart to run ez-audit trhough login script
Gary O Offline
Lurker

Registered: 2003-08-25
Posts: 4
Loc: Plymouth, NC
This is what I had in my script to handle Win 95.

:setcmd

if @INWIN = 1 ; 1 = NT, 2 = Win95

$CMD = "cmd /E:1024 /C"

else

$CMD = "command.com /E:1024 /C"

endif

Shouldn't this work?

Top
#44475 - 2003-08-25 03:31 PM Re: Using Kixtart to run ez-audit trhough login script
cwick Offline
Fresh Scripter

Registered: 2003-08-25
Posts: 10
Loc: Ohio
GaryO,

Just a suggestion, try using the server\share name and not a drive mapping. I just got this working last week with the following code.
IF INGROUP ("ezaudit")
RUN "%COMSPEC% /c \\server\share$\ezaudit\ezscan.exe auto"
ENDIF

Win9x may just be a little slow with the drive mappings.

Thank you to everyone I have really learned a lot from this forum in the last few weeks.

Top
#44476 - 2003-08-25 04:39 PM Re: Using Kixtart to run ez-audit trhough login script
Gary O Offline
Lurker

Registered: 2003-08-25
Posts: 4
Loc: Plymouth, NC
That did it. Using server\share name instead of mapping a drive took care of the problem.

Thanks for the help.

Top
#44477 - 2003-08-25 04:48 PM Re: Using Kixtart to run ez-audit trhough login script
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
you still should update your script according to my suggestion.

1) you get rid of those gosubs
2) your script is simpler as it will automatically determine which command-interpreter to use
3) as I wrote it [Big Grin]
_________________________
!

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
0 registered and 259 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.056 seconds in which 0.023 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