#33885 - 2002-12-04 05:47 PM
Re: INGROUP problem
|
Steve M
Fresh Scripter
Registered: 2002-05-08
Posts: 40
Loc: Orange,California
|
LONKERO, I have added your debug code and it did not display any thing or ask me to hit any key. Below is my most recent code. And yes I am using kix to support win98 clients only. My win2k clients use native AD GPO 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("ESCROW-UNIT6") USE S: /delete /Persistent use S: "\\FS2\ESCROW-UNIT6$" ? "Member of ESCROW-UNIT6 group" ENDIF
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
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 Endif If Exist ("c:\windows\DESKTOP\TRAKKE~2.PIF") = 0 copy "\\W2K2\netlogon\TRAKKE~2.PIF" "c:\windows\desktop" ;copies Trakker Lend shortcut to desktop Endif 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
if INGROUP("RealEC") ? "Member of RealEC group" USE R: /delete /Persistent USE R: "\\FS1\RealEC" if @error ? "MAPPING ERROR: @error" ? "press any key to continue" get $somekey endif else ? "not Member of RealEC group" endif
if INGROUP("TRAKKER") USE L: /delete /Persistent use L: "\\TK2\TRAKKER" ? "Member of Trakker group" ENDIF sleep 5
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 copy "\\W2K2\netlogon\TRAKKE~1.PIF" "c:\windows\desktop" ;copies Trakker Star shortcut to desktop ENDIF If Exist ("c:\windows\DESKTOP\TRAKKE~2.PIF") = 0 ;Checks for the existance of Trakker Lend shortcut copy "\\W2K2\netlogon\TRAKKE~2.PIF" "c:\windows\desktop" ;copies Trakker Lend shortcut to desktop ENDIF If Exist ("c:\windows\DESKTOP\ESCROW~1.PIF") = 0 ;Checks for the existance of Escrow Docnet shortcut copy "\\W2K2\netlogon\ESCROW~1.PIF" "c:\windows\desktop" ;copies Escrow Docnet shortcut to desktop ENDIF If Exist ("c:\windows\DESKTOP\REOESC~1.PIF") = 0 ;Checks for the existance of Reo Escrow Docnet shortcut copy "\\W2K2\netlogon\REOESC~1.PIF" "c:\windows\desktop" ;copies Reo Escrow Docnet shortcut to desktop ENDIF If Exist ("c:\windows\DESKTOP\STARDO~1.PIF") = 0 ;Checks for the existance of Star Docnet shortcut copy "\\W2K2\netlogon\STARDO~1.PIF" "c:\windows\desktop" ;copies Star Docnet shortcut to desktop ENDIF
_________________________
Steve
|
Top
|
|
|
|
#33888 - 2002-12-04 05:54 PM
Re: INGROUP problem
|
GRF
Fresh Scripter
Registered: 2002-02-15
Posts: 45
Loc: Ohio
|
I noticed in your code that the group RealEC is the only group that tries to map to R:. Will one of the existing groups that currently map to another drive letter map to R:?
_________________________
GF
|
Top
|
|
|
|
#33890 - 2002-12-04 06:45 PM
Re: INGROUP problem
|
Steve M
Fresh Scripter
Registered: 2002-05-08
Posts: 40
Loc: Orange,California
|
I just tried the simpler code logged in as a user in the command window and it said not member of RealEC. I have also noticed that the L: drive stopped mapping for my users which in my code worked prior to my editing this code. This is an important drive because it runs our main application TRAKKER. WHAT stupid mistake have I done to break this thing?????
_________________________
Steve
|
Top
|
|
|
|
#33892 - 2002-12-04 06:55 PM
Re: INGROUP problem
|
Steve M
Fresh Scripter
Registered: 2002-05-08
Posts: 40
Loc: Orange,California
|
I just put back my backup of my old code and people are now getting their L drive back. I cannot understand why that is because I did not make any changes to the L drive code code:
if INGROUP("TRAKKER") USE L: /delete /Persistent use L: "\\TK2\TRAKKER" ? "Member of Trakker group" ENDIF
as you can see it is the same in the new code as it is in the old code.
_________________________
Steve
|
Top
|
|
|
|
#33893 - 2002-12-04 06:56 PM
Re: INGROUP problem
|
Howard Bullock
KiX Supporter
Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
|
Well, it appears that this code doesn't make much sense and it is missing an ENDIF.
code:
if INGROUP("TRAKKER") USE L: /delete /Persistent use L: "\\TK2\TRAKKER" ? "Member of Trakker group" ENDIF sleep 5
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"
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 381 anonymous users online.
|
|
|