#138017 - 2005-04-14 11:20 PM
Script stops working....why?
|
Mouse51180
Fresh Scripter
Registered: 2005-04-14
Posts: 6
|
I have created a small script that when the user logs in, it checks their groups and maps the appropriate drives in reference to those groups during logon. The script seems to run fine, until it has run 5-10 times. Then it just stops running all together.
The funny thing is if I copy one of the example .kix files into my servers and have them run during startup, everything is fine so then I copy my script back over the example and my script starts working...for about 5-10 times...then it stops working again.
I have the /f command on the test accounts login script box. I have checked the registry and I have the kixtart folder in the software section of the hkey_current_user, but nothing under that folder, so I guess the /f command is working.
Any ideas or have I completely lost everyone?
|
|
Top
|
|
|
|
#138018 - 2005-04-14 11:40 PM
Re: Script stops working....why?
|
Kdyer
KiX Supporter
   
Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
|
Can you show us what your script is? Sorry, crystal ball is broken. 
BTW, Welcome to the board.
Kent
|
|
Top
|
|
|
|
#138020 - 2005-04-15 03:36 PM
Re: Script stops working....why?
|
Mouse51180
Fresh Scripter
Registered: 2005-04-14
Posts: 6
|
Here is my script - Where it says my script actually has the share loction it doesnt say ... if that makes any sense:
COLOR r+/n at(2,2) "Initializing Logon Script - Please Stand By" SETTIME "*" CLS
COLOR y+/n at(2,2) BOX (2,2,17,67,Double) COLOR b+/n at(3,3) BOX (3,19,5,49,Full) COLOR w+/n at(4,21) "Welcome to Joe Gibbs Racing" COLOR w+/n at(7,6) "Welcome back:" COLOR y+/n at(7,21) "@fullname" COLOR w+/n at(8,6) "Today is:" COLOR c+/n at(8,17) "@Day - @Month @Day, @Year" COLOR w+/n at(9,6) "The current time is:" COLOR c+/n at(9,29) "@Time" COLOR y+/n at(12,6) "Please standby as we map your network drives:"
USE H: "\\App-Server\Homefolders$\@userid"
If InGroup ("IT Admins") USE Z: "\\\IT Folders" EndIf If InGroup ("Marketing Group") USE Y: "\\\Marketing" EndIf
CLS COLOR y+/n at(2,2) BOX (2,2,17,67,Double) COLOR b+/n at(3,3) BOX (3,19,5,49,Full) COLOR w+/n at(4,21) "Welcome to Joe Gibbs Racing" COLOR w+/n at(7,6) "Welcome back:" COLOR y+/n at(7,21) "@fullname" COLOR w+/n at(8,6) "Today is:" COLOR c+/n at(8,17) "@Day - @Month @Day, @Year" COLOR w+/n at(9,6) "The current time is:" COLOR c+/n at(9,29) "@Time" COLOR g+/n at(12,6) "Drive Mapping Complete!" COLOR w+/n at(13,6) "Have a nice day :-P" SLEEP 2 COLOR r+/n at(15,6) "Press Any Key to Exit" get $x break
|
|
Top
|
|
|
|
#138021 - 2005-04-15 03:39 PM
Re: Script stops working....why?
|
Mouse51180
Fresh Scripter
Registered: 2005-04-14
Posts: 6
|
By the way...just to add to the info... I ran the script until it broke again last night...then tried to run it again this morning to see if there is just some strage replication issue somewhere in my domain, but the script is still broken.
I copied the script and the .dll files to my local pc and ran the script manually and everything mapped and worked fine. Just cant get it to run from the server automatically everytime.
Thanks for your help
|
|
Top
|
|
|
|
#138022 - 2005-04-15 06:48 PM
Re: Script stops working....why?
|
Kdyer
KiX Supporter
   
Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
|
What version of KiXtart are you running?
What is BREAK? I believe you want BREAK ON or BREAK OFF. That is, BREAK gives you the ability to Break in on a script.
Here is the script changed to be more of what you are looking for: Code:
CLS BREAK ON
COLOR r+/n at(2,2) "Initializing Logon Script - Please Stand By" ;SETTIME "*"
COLOR y+/n at(2,2) BOX (2,2,17,67,Double) COLOR b+/n at(3,3) BOX (3,19,5,49,Full) COLOR w+/n at(4,21) "Welcome to Joe Gibbs Racing" COLOR w+/n at(7,6) "Welcome back: " COLOR y+/n at(7,21) @fullname COLOR w+/n at(8,6) "Today is: " COLOR c+/n at(8,17) @Day+" - "+@Month+" "+@Day+", "+@Year COLOR w+/n at(9,6) "The current time is: " COLOR c+/n at(9,29) @Time COLOR y+/n at(12,6) "Please standby as we map your network drives:"
USE H: "\\App-Server\Homefolders$$\"+@userid
If InGroup("IT Admins") USE Z: "\\\IT Folders" EndIf If InGroup("Marketing Group") USE Y: "\\\Marketing" EndIf
COLOR g+/n at(12,6) "Drive Mapping Complete!" COLOR w+/n at(13,6) "Have a nice day :-P" SLEEP 2 COLOR r+/n at(15,6) "Press Any Key to Exit" get $x
You may also want to check into SETTIME with 2000/XP machines as they will automatically sync time throughout the day.
Also, you may need to double-up on the $ for Homefolders$ as older versions of KiX will want to use this.
Thanks,
Kent
|
|
Top
|
|
|
|
#138024 - 2005-04-15 10:22 PM
Re: Script stops working....why?
|
Mouse51180
Fresh Scripter
Registered: 2005-04-14
Posts: 6
|
Ok to answer everyones questions:
kdyer: (1) - Im running 4.23 version of Kixtart. (2) - I was using "Break" to exit the program. For some reason if I used exit or end, it would act funny so I just tried adding break to exit the program and it seem to work so I didnt ask question. (3) - I needed the time to be set during login because the opening screen displays the time and I didnt want that to be incorrect. I know the time gets synced throughout the day on Win 2000 and higher machines. (4) - As for doubling up on the $. I have Kixtart running off a server and everything in my domain is Win 2000 or XP so I didnt see a need to double up on the $. I tested it on both systems and that part seem to work fine.
Les: (1) - I am well aware of how and what .DLLs are. MY code does not have \\\IT Folders and when I copied the script I replaced some of the location code with "share location" but used <> instead of "". I also explained this at the top of the script, but im not going to fight about that. Apprently this part was taken out when I copied this into my post. So the actual script says:
USE Z: "\\"SOURCE LOCATION"\IT Folders"
|
|
Top
|
|
|
|
#138027 - 2005-04-18 08:04 PM
Re: Script stops working....why?
|
Mouse51180
Fresh Scripter
Registered: 2005-04-14
Posts: 6
|
Well I appologize. It sounds like a few of us have taken a few of these post out of context. I am sorry for not posting all the script and all the system variables. I didnt think they were relavent because the script runs fine. It seems more like a networking or AD issues then anything else. I am sorry if it sounds like I have come on here "demanading" information. I just wanted to know if anyone had seen this in the past, but it seems like we are all stumped.
I will continue to play around with this and I will post anything I find.
|
|
Top
|
|
|
|
#138028 - 2005-04-18 08:43 PM
Re: Script stops working....why?
|
Kdyer
KiX Supporter
   
Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
|
I really think that Les nailed with the three "\\\".
You have for example: Code:
USE Z: "\\\IT Folders"
It really needs to be: Code:
USE Z: "\\IT Folders"
And looking at this, what server is this going to?
Shouldn't it not be: Code:
USE Z: "\\SOME_SERVER\IT Folders"
?
HTH,
Kent
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 837 anonymous users online.
|
|
|