Page 1 of 2 12>
Topic Options
#27514 - 2002-08-22 02:51 PM Complete Newbie......questions
Addict Offline
Getting the hang of it

Registered: 2002-08-22
Posts: 62
Loc: Ohio, US
I have a network that runs Windows 95/98 clients and Windows 2000 Server DCs with some Novell servers. I'm not real sure where to begin with this.

First, I'm not acustomed to using 2000 logon scripts. We currently use logon scripts from our Novell servers. I don't really know where to start.

I've written a logon script (just a basic 'net use'), but it doesn't execute on Win9x machines. I've assigned via the AD Users snap-in under Profile. I copied it to the Netlogon share so it replicates itself as well.

Another thing. Any ideas on how to check to see if Kix is installed and if its not to install it? I've got the kix script written, but I just need to get it to execute. I copied all the kix files(kix32.exe, kx16.dll & kx32.dll) to the window/system on my test machine as well. The basic logon batch file does execute on Win2k machines.

Sorry is these seem like dumb questions, but I'm new to this and need a bit of guidance.

Top
#27515 - 2002-08-22 02:56 PM Re: Complete Newbie......questions
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
everyone of has been a newbie, so let the questions come up.

anyway, about the install, there is no need to install kix.
if your kix files are in netlogon you can call them from that running basic batch:
%0\..\kix32.exe %0\..\myfirstscript.kix

about not running with win9x I can't advice as my net does not have them!

anyway, what is the name of the batch file?
it should be named *.bat to work on win9x

cheers.
_________________________
!

download KiXnet

Top
#27516 - 2002-08-22 03:14 PM Re: Complete Newbie......questions
Addict Offline
Getting the hang of it

Registered: 2002-08-22
Posts: 62
Loc: Ohio, US
Thanks for the reply.
The batch file name is logon.bat.
It still doesn't execute on Win9s machines though. Well I'll jsut have to wait for the admins who have Win9x machines to wake [Wink] .

[ 22. August 2002, 15:15: Message edited by: Civic_Addict ]

Top
#27517 - 2002-08-22 03:16 PM Re: Complete Newbie......questions
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
Please visit the FAQ section. It does contain the answers to your questions.

Also, check out Kixtart Deployment
Kixtart Starter's Guide
Windows 9x/Me Kixtart Support

Finally, search the BBs for 'LOGIN.BAT' to find examples of login batch files that automatically deploy/update KiXtart.

[ 22. August 2002, 15:17: Message edited by: sealeopard ]
_________________________
There are two types of vessels, submarines and targets.

Top
#27518 - 2002-08-22 03:19 PM Re: Complete Newbie......questions
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
jens, there is just the little problem that any of those does not address the problem.

as the batch does not run at all.

good links anyway, once he gets it to run in the first place.
_________________________
!

download KiXnet

Top
#27519 - 2002-08-22 03:24 PM Re: Complete Newbie......questions
Addict Offline
Getting the hang of it

Registered: 2002-08-22
Posts: 62
Loc: Ohio, US
Good links. Lots of good info.
But my logon script isn't starting at all. Any ideas?

Top
#27520 - 2002-12-03 05:39 AM Re: Complete Newbie......questions
MCA Offline
KiX Supporter
*****

Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
Dear,

Did you find already a solution? Please return status uodate.
People on this board always be glad to help you. Possible your open-end was lost.
thanks & greetings.
_________________________
email scripting@wanadoo.nl homepage scripting@wanadoo.nl | Links | Summary of Site Site KiXforms FAQ kixtart.org library collection mirror MCA | FAQ & UDF help file UDF kixtart.org library collection mirror MCA | mirror USA | mirror europe UDF scriptlogic library collection UDFs | mirror MCA

Top
#27521 - 2002-12-03 06:44 AM Re: Complete Newbie......questions
Steve M Offline
Fresh Scripter

Registered: 2002-05-08
Posts: 40
Loc: Orange,California
Hi Civic_Adict,
I am fairly new to kix just like you and instead of me telling you about links and reading the manual I will try to give some guidence to you. I also have an NT win2k servers and Novell servers with win9x and win2k clients. I prefer to use kix on the win9x clients only and the win2k pro boxes I use the native win2k GPO's. To get my win9x clients to work with kix I have 4 scripts total. Logon.bat calls script1.bat wich calls script1.scr and finally that calls the macro.bat
The macro the bat is really the only one that I add or edit. All four of these scripts are in the netlogon share. On the user properties for script you must specify the Logon.bat and the rest is taken care of. Below are my scripts that you may copy and make any modifications you need. I hope this will get you started.
code:
 
if "%OS%"=="Windows_NT" goto winnt
if exist %windir%\win.com goto BATSTART
;GOTO BATSTART
$res=WRITEVALUE("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce","KixScript","$kixscript","REG_SZ")
EXIT
:BATSTART

SET KIXDIR=C:\UTILS

REM set the full UNC path to the KiXtart script
REM (the Z: drive cannot be used here, it no longer exists when
REM the KiXtart script is running from RunOnce)
REM
SET KIXSCRIPT=%LOGONSERVER%\NETLOGON\script1.scr

REM set the filename of the KiXtart version tag;
REM change this name to upgrade to a newer version of KiXtart
REM
SET KIXVER=KIX347.TAG

REM ---------------------------------------------------------------------

REM if necessary, create destination directory
REM
IF NOT EXIST %KIXDIR%\NUL MKDIR %KIXDIR%

REM perform a completely new install or upgrade of KiXtart
REM if the current version tag can not be found
REM
IF EXIST %KIXDIR%\%KIXVER% GOTO KIXCOPIED
COPY %0\..\KIX32.EXE %KIXDIR% /Y >NUL
COPY %0\..\KX16.DLL %KIXDIR% /Y >NUL
COPY %0\..\KX32.DLL %KIXDIR% /Y >NUL
COPY %0\..\KX95.DLL %KIXDIR% /Y >NUL
ECHO. >%KIXDIR%\%KIXVER%

:KIXCOPIED

REM check all KiXtart files individually and restore them
REM if something has been deleted accidentally by the user
REM
IF NOT EXIST %KIXDIR%\KIX32.EXE COPY %0\..\KIX32.EXE %KIXDIR% >NUL
IF NOT EXIST %KIXDIR%\KX16.DLL COPY %0\..\KX16.DLL %KIXDIR% >NUL
IF NOT EXIST %KIXDIR%\KX32.DLL COPY %0\..\KX32.DLL %KIXDIR% >NUL
IF NOT EXIST %KIXDIR%\KX95.DLL COPY %0\..\KX95.DLL %KIXDIR% >NUL

REM use KiXtart to add the KiXtart script to the RunOnce registry key
REM
IF NOT EXIST %0 GOTO script1
%KIXDIR%\KIX32.EXE %0 $kixscript="%KIXDIR%\KIX32.EXE %KIXSCRIPT%"
GOTO script1
:NOEXT
%KIXDIR%\KIX32.EXE %0.BAT $kixscript="%KIXDIR%\KIX32.EXE %KIXSCRIPT%"
:script1
%0\..\kix32.exe script1.scr
EXIT

:winnt


EXIT

code:
? "Setting DOS variables..."
SHELL "winset.exe USERNAME=@USERID"
SHELL "Winset.exe ADDRESS=@ADDRESS"
SHELL "Winset.exe COMPUTER=@WKSTA"
SHELL "Winset.exe DOMAIN=@DOMAIN"
SHELL "Winset.exe COMMENT=@COMMENT"
SHELL "Winset.exe FULLNAME=@FULLNAME"
SHELL "Winset.exe HOMEDIR=@HOMEDIR"
SHELL "Winset.exe HOMESHR=@HOMESHR"
SHELL "Winset.exe LSERVER=@LSERVER"
SHELL "Winset.exe PRIV=@PRIV"
? "Done."
Call Macro.bat
EXIT

code:
 SHELL "winset.exe USERNAME=@USERID"
BREAK ON ;(re)set Ctrl-C/Break handling
COLOR r+/n

;
CLS
;
small
Color b+/n
BOX (7,20,17,61,FULL)
;
Color w+/n
;
IF ((@time > "00:00:00") AND (@time < "12:00:00"))
at (9,22) "Good Morning,"
ELSE
IF ((@time >= "12:00:00") AND (@time < "18:00:00"))
at (9,22) "Good Afternoon,"
ELSE
at (9,22) "Good Evening,"
ENDIF
ENDIF
;
at (10,22) @fullname
at (12,22) "Please Wait For Logon script Execution"
at (13,22) "Progress"

$drive="\\FS2\"+@userid+chr(36)
USE U: $drive
SLEEP 5

DelKey("HKEY_CURRENT_USER\Software\KiXtart\TokenCache")



if INGROUP("ESCROW-REO")
USE S: /delete /Persistent
use S: "\\FS2\REO$"
? "Member of ESCROW-REO group"
ENDIF


if INGROUP("ESCROW-UNIT1")
USE S: /delete /Persistent
use S: "\\FS2\ESCROW-UNIT1$"
? "Member of ESCROW-UNIT1 group"
ENDIF


if INGROUP("ESCROW-UNIT2")
USE S: /delete /Persistent
use S: "\\FS2\ESCROW-UNIT2$"
? "Member of ESCROW-UNIT2 group"
ENDIF


if INGROUP("ESCROW-UNIT3")
USE S: /delete /Persistent
use S: "\\FS2\ESCROW-UNIT3$"
? "Member of ESCROW-UNIT3 group"
ENDIF


if INGROUP("ESCROW-UNIT4")
USE S: /delete /Persistent
use S: "\\FS2\ESCROW-UNIT4$"
? "Member of ESCROW-UNIT4 group"
ENDIF

if INGROUP("ESCROW-UNIT5")
USE S: /delete /Persistent
use S: "\\FS2\ESCROW-UNIT5$"
? "Member of ESCROW-UNIT5 group"
ENDIF

if INGROUP("Everyone")
? "Member of Everyone group"
USE I: /delete /Persistent
use I: "\\FS2\APPS"
If Exist ("c:\windows\RD.bat") = 0
If Exist ("c:\windows\RD.pif") = 0
If Exist ("c:\windows\MSTSc.exe") = 0
If Exist ("c:\windows\MSTSCAX.DLL") = 0
copy "\\W2K2\netlogon\RD.BAT" "c:\windows"
copy "\\W2K2\netlogon\RD.PIF" "c:\windows"
copy "\\W2K2\netlogon\MSTSC.EXE" "c:\windows"
copy "\\W2K2\netlogon\MSTSCAX.DLL" "c:\windows"
ENDIF
ENDIF
ENDIF
ENDIF
ENDIF

if INGROUP("LED")
? "Member of LED group"
USE G: /delete /Persistent
use G: "\\ATC-CORP\VOL2"
USE S: /delete /Persistent
use S: "\\FS2\LED$"
If Exist ("c:\windows\DESKTOP\TRAKKE~1.PIF") = 0
copy "\\W2K2\netlogon\TRAKKE~1.PIF" "c:\windows\desktop" ;copies Trakker Star shortcut to desktop
If Exist ("c:\windows\DESKTOP\TRAKKE~2.PIF") = 0
copy "\\W2K2\netlogon\TRAKKE~2.PIF" "c:\windows\desktop" ;copies Trakker Lend shortcut to desktop
If Exist ("c:\windows\DESKTOP\STARDO~1.PIF") = 0
copy "\\W2K2\netlogon\STARDO~1.PIF" "c:\windows\desktop" ;copies Star Docnet shortcut to desktop
endif
endif
endif
endif

if INGROUP("REALEC")
USE R: /delete /Persistent
USE R: "\\FS1\REALEC"
? "Member of REALEC group"
endif
sleep 5

if INGROUP("TRAKKER")
USE L: /delete /Persistent
use L: "\\TK2\TRAKKER"
? "Member of Trakker group"
ENDIF
sleep 5

;if INGROUP("USBANK")
;USE I: /delete /Persistent
;use I: "\\FS2\Apps"
;? "Member of USBANK group"
;USE U: /delete /Persistent
;USE H: $drive
;endif

;if INGROUP("LANEGUIDE")
;USE I: /delete /Persistent
;use I: "\\FS1\LANE GUIDE"
;? "Member of LANEGUIDE group"
;endif


if INGROUP("Domain Admins")
? "Member of Domain Admins group"
sleep 5
USE G: /delete /Persistent
use G: "\\ATC-CORP\VOL2"
USE L: /delete /Persistent
use L: "\\TK2\TRAKKER"
If Exist ("c:\windows\DESKTOP\TRAKKE~1.PIF") = 0 ;Checks for the existance of Trakker Star shortcut
If Exist ("c:\windows\DESKTOP\TRAKKE~2.PIF") = 0 ;Checks for the existance of Trakker Lend shortcut
If Exist ("c:\windows\DESKTOP\ESCROW~1.PIF") = 0 ;Checks for the existance of Escrow Docnet shortcut
If Exist ("c:\windows\DESKTOP\REOESC~1.PIF") = 0 ;Checks for the existance of Reo Escrow Docnet shortcut
If Exist ("c:\windows\DESKTOP\STARDO~1.PIF") = 0 ;Checks for the existance of Star Docnet shortcut

copy "\\W2K2\netlogon\TRAKKE~1.PIF" "c:\windows\desktop" ;copies Trakker Star shortcut to desktop
copy "\\W2K2\netlogon\TRAKKE~2.PIF" "c:\windows\desktop" ;copies Trakker Lend shortcut to desktop
copy "\\W2K2\netlogon\ESCROW~1.PIF" "c:\windows\desktop" ;copies Escrow Docnet shortcut to desktop
copy "\\W2K2\netlogon\REOESC~1.PIF" "c:\windows\desktop" ;copies Reo Escrow Docnet shortcut to desktop
copy "\\W2K2\netlogon\STARDO~1.PIF" "c:\windows\desktop" ;copies Star Docnet shortcut to desktop
ENDIF
ENDIF
ENDIF
ENDIF
ENDIF
ENDIF



_________________________
Steve

Top
#27522 - 2002-12-03 07:01 AM Re: Complete Newbie......questions
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Steve,

I just wanted to say thank you for taking an interest in helping another member out here. Always great to have thoughtful people on board.

I also wanted to let you know that this thread is about 4 months old, so I would assume the user has either figured it out by now, or left without an answer (which is not good). Maybe they did get it working and forgot to update everyone.

Hopefully your information will be helpful to others as they come by this thread in the future.

Thanks again.

Top
#27523 - 2002-12-03 07:42 AM Re: Complete Newbie......questions
MCA Offline
KiX Supporter
*****

Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
Dear,

NTDOC

Before asking a status update:
- first we are looking for "owner will receive an email".
- secondly we are reading contents very closely. when the combination is unique enough
an update can be very interesting.
In other situation we try only to complete the answer. A direct feedback isn't real-
ly necessary for us.

Steve

A pity is it, when your nice work will get lost. We advise you to create a new topic
when you want to share a nice piece of script or other information (f.e. OFF-TOPIC)
with us. It makes is also possible that you can monitor with ease reactions.

greetings.
_________________________
email scripting@wanadoo.nl homepage scripting@wanadoo.nl | Links | Summary of Site Site KiXforms FAQ kixtart.org library collection mirror MCA | FAQ & UDF help file UDF kixtart.org library collection mirror MCA | mirror USA | mirror europe UDF scriptlogic library collection UDFs | mirror MCA

Top
#27524 - 2002-12-03 02:12 PM Re: Complete Newbie......questions
Addict Offline
Getting the hang of it

Registered: 2002-08-22
Posts: 62
Loc: Ohio, US
Whoa. Its back from the dead.

I did finally solve my problem. NT4!!!!!

We have and old NT4 BDC sitting back there. Win9x prefers NT4 over Win2k and my login scripts weren't replicating to that server(and still don't but that's another thing). So to sum it up, Win9x will process the scripts from an NT4 box over Win2k.

Thank you all for the replies. I will definately have more questions as my login script grows.

Top
#27525 - 2002-12-03 02:30 PM Re: Complete Newbie......questions
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
addict, reading kholm's post some 10 days ago indicates that actually w9x prefers the machine it has previously used.

so, until you remove the nt-server, it should keep on using that.
_________________________
!

download KiXnet

Top
#27526 - 2002-12-03 02:37 PM Re: Complete Newbie......questions
Addict Offline
Getting the hang of it

Registered: 2002-08-22
Posts: 62
Loc: Ohio, US
In all honesty, I don't know why its still there.

I inherited this network, so I hate to just take it offline. But it will be going away soon regardless. Once my NT4 Terminal Server gets the boot!
All hail Citrix...

Top
#27527 - 2002-12-03 02:38 PM Re: Complete Newbie......questions
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
huh!
don't curse [Mad] [Big Grin]
_________________________
!

download KiXnet

Top
#27528 - 2002-12-03 03:27 PM Re: Complete Newbie......questions
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
Steve:

A) Get the replication working

B) Clean up the messy IF-ENDIF statements in your code. They show a lack of understanding of the logical structure used to intiate the COPY stements for missing files. Essentially, the COPY statements will not work unless in a very narrowly defined situation, amely if all files are missing. If just one file is missing, it won't work.

C) What's the WRITEVALUE doing in your batch file? WRITEVALUE is a KiXtart function and won't work in a batch file

[ 03. December 2002, 15:27: Message edited by: sealeopard ]
_________________________
There are two types of vessels, submarines and targets.

Top
#27529 - 2002-12-04 01:06 AM Re: Complete Newbie......questions
Steve M Offline
Fresh Scripter

Registered: 2002-05-08
Posts: 40
Loc: Orange,California
sealeopard, my code that copies the pifs to the shortcuts works fine without any problems so I cannot understand why I am getting pounded on my code. I have had people in this newsfroup tell me that this and that code cannot work and believe it or not it does work.
_________________________
Steve

Top
#27530 - 2002-12-04 01:21 AM Re: Complete Newbie......questions
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Your code may work is certain cirmstances, but it does need to be reviewed and corrected to work as I think you intended it to work.

For instance:
code:
if INGROUP("Everyone")
? "Member of Everyone group"
USE I: /delete /Persistent
use I: "\\FS2\APPS"
If Exist ("c:\windows\RD.bat") = 0
If Exist ("c:\windows\RD.pif") = 0
If Exist ("c:\windows\MSTSc.exe") = 0
If Exist ("c:\windows\MSTSCAX.DLL") = 0
copy "\\W2K2\netlogon\RD.BAT" "c:\windows"
copy "\\W2K2\netlogon\RD.PIF" "c:\windows"
copy "\\W2K2\netlogon\MSTSC.EXE" "c:\windows"
copy "\\W2K2\netlogon\MSTSCAX.DLL" "c:\windows"
ENDIF
ENDIF
ENDIF
ENDIF
ENDIF

The copy commands will only ever execute when ALL the IF statements return true. Is that what you wanted? If so this does the same thing:
code:
if INGROUP("Everyone")
? "Member of Everyone group"
USE I: /delete /Persistent
use I: "\\FS2\APPS"
If Exist ("c:\windows\RD.bat") = 0 and
Exist ("c:\windows\RD.pif") = 0 and
Exist ("c:\windows\MSTSc.exe") = 0 and
Exist ("c:\windows\MSTSCAX.DLL") = 0
copy "\\W2K2\netlogon\RD.BAT" "c:\windows"
copy "\\W2K2\netlogon\RD.PIF" "c:\windows"
copy "\\W2K2\netlogon\MSTSC.EXE" "c:\windows"
copy "\\W2K2\netlogon\MSTSCAX.DLL" "c:\windows"
ENDIF
ENDIF

Oh and why the Ingroup("Everyone")? If you want everyone then execute the code for everyone without the added overhead of checking a group?

My guess is that you reall want something like:
code:
  USE I: /delete /Persistent
use I: "\\FS2\APPS"
If Exist ("c:\windows\RD.bat") = 0
copy "\\W2K2\netlogon\RD.BAT" "c:\windows"
Endif
If Exist ("c:\windows\RD.pif") = 0
copy "\\W2K2\netlogon\RD.PIF" "c:\windows"
Endif
If Exist ("c:\windows\MSTSc.exe") = 0
copy "\\W2K2\netlogon\MSTSC.EXE" "c:\windows"
Endif
If Exist ("c:\windows\MSTSCAX.DLL") = 0
copy "\\W2K2\netlogon\MSTSCAX.DLL" "c:\windows"
Endif



[ 04. December 2002, 01:30: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#27531 - 2002-12-04 01:27 AM Re: Complete Newbie......questions
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Howard,
You let an AND slip into the final code.

Steve,
Try not to take the critiquing too hard.

What is this?
;GOTO BATSTART
$res=WRITEVALUE("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce","KixScript","$kixscript","REG_SZ")

Seems to be in amongst DOS BAT stuff.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#27532 - 2002-12-04 01:29 AM Re: Complete Newbie......questions
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Thanks Les. The code has been corrected.
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#27533 - 2002-12-04 04:06 AM Re: Complete Newbie......questions
Steve M Offline
Fresh Scripter

Registered: 2002-05-08
Posts: 40
Loc: Orange,California
LLigetfa, answer to your question about the ;GOTO BATSTART
$res=WRITEVALUE("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce","KixScript","$kixscript","REG_SZ")

I was told the runonce was necessary. Can rem that out?
_________________________
Steve

Top
Page 1 of 2 12>


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

Who's Online
0 registered and 557 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.074 seconds in which 0.027 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