|
|
|||||||
Hi I apologise if Iam in the wrong area and would welcome your direction I am a newbie to the forum sorry. We all use XP sp3 and Kix login script ok for last 5 year but I now have 30 systems on Win7 and it say... This operating System is unknown or unsupported - Cancelling Login Script Press any key to continue . . . I can post my scripts etc if anyone feels they could assist me thank you |
||||||||
|
|
|||||||
It sounds like it has to be some kind of OS check written into the script. If you post the code, Im sure we can track it down. And please make sure to use the CODE tags when posted your script so that it gets formatted properly. |
||||||||
|
|
|||||||
Agreed - this is not a Kixtart message, but one from the script itself. Post the script! Glenn |
||||||||
|
|
|||||||
Hi there here is the KIX script and you can see where I tried to add win7 but its probably entirely wrong Code: ;***************************************************** ; SLISI STAFF Login Script ;***************************************************** ; Author: ; Date: 22/10/04 ; Format: KIX ; Description: SLISI Staff Login script ; Last Modifed Date: ; ;***************************************************** ;SETUP KIXSCRIPT ENVIRONMENT ;***************************************************** SetTitle ("Sun Life Ireland Login Script") cls Color w+/n ? "Sun Life Ireland Login Script on " @MDAYNO"/"@MONTHNO"/"@YEAR " at " @TIME ? ;***************************************************** ;Declare Global Variables ;***************************************************** GLOBAL $DDMMYYYY, $MyIP, $MySubnet, $LogonType, $MyPriv, $MyMachineType ;***************************************************** ;Set Global Variables ;***************************************************** $DDMMYYYY = DDMMYYYY $MyIP = MyIP $MySubnet = MySubnet $LogonType = LogonType $MyPriv = MyPriv $MyMachineType = MyMachineType ;***************************************************** ; This enables a Crtl/Break without rebooting. ;***************************************************** ; Break on ;***************************************************** ; Run Script in debug mode if user is a member of "LOGIN_SCRIPT_DEBUGGER" global group ;***************************************************** IF INGROUP("LOGIN_SCRIPT_DEBUGGER") DEBUG ON ENDIF ;***************************************************** ; Create a local logon.log file on users C: drive and redirect all output to this file ;***************************************************** If $logontype = "Local" IF RedirectOutput("C:\logon.log", 1 ) <> 0 ? "Error Logging Script Results to 'C:\logon.log' @error - @serror" ? ELSE ? "Login Script Results logged to 'C:\logon.log'" ? ENDIF ENDIF ? "Sun Life Ireland Login Script on " @MDAYNO"/"@MONTHNO"/"@YEAR " at " @TIME ;***************************************************** ; Welcome User ;***************************************************** ? ? "You are logged on to the " @LDomain " domain as User: " @UserID ? ? "*****************************************************" ? "User and Host computer Information" ? "*****************************************************" ? ? "Hostname: " @WKSTA ? ? "IP Address: " $MyIP ? ? "Location: " $MySubnet ? ? "Machine: " $MyMachineType ? ? "Logon Type: " $LogonType ? ? "User Privileges: " $MyPriv ;***************************************************** ;Log user and workstation information to central logfile location on the network ;***************************************************** $logshare= "\\sv4103\Software\Reports\Login" $logfile= "$Logshare\$DDMMYYYY.LOG" $logdata= "@MDAYNO/@MONTHNO/@YEAR,@TIME,@WKSTA,@ProductType,@FULLNAME,@USERID,$MyPriv,@LSERVER,$MyMachineType,$MySubnet,$MyIP,@ADDRESS,$LogonType" ? $null = Loginfo($logfile,$logdata) ? ;Run "c:\program files\internet explorer\IEXPLORE.exe http://www.google.ie/" ;Run "c:\program files\internet explorer\IEXPLORE.exe http://thesource-redirect.ca.sunlife/" ;***************************************************** ; Skip rest of script for all Citrix and Term Serv (Application mode) clients ;***************************************************** If $logontype = "Citrix Metaserver or Terminal Services in Application mode" GOTO END ENDIF ;***************************************************** ;DETERMINE ACTIONS BASED ON OS ;***************************************************** $OSVal = @PRODUCTTYPE SELECT ;***************************************************** ; Actions for Windows Server Operating Systems ONLY ;***************************************************** CASE ( (INSTR ($OSVal,"Server") <> 0) OR (INSTR ($OSVal,"Domain Controller") <> 0) ) ? ? "Running Windows NT/2000/2003 Server KiXtart Login Script" ? ;***************************************************** ;Actions for Windows XP Professional or 2000 Professional ONLY ;***************************************************** CASE (LEFT(@PRODUCTTYPE,10) = "Windows XP") OR (@ProductType = "Windows 2000 Professional") OR (@ProductType = "Windows 7") ? "*****************************************************" ? ? "Running Windows 2000/XP Workstation Login Script" ? ? "*****************************************************" ? "Mapping Drives for user @USERID..." ? "*****************************************************" ;ADD STANDARD DRIVE MAPPINGS FOR ALL Authenticated USERS MAPDRIVE ("J:","SV4103","Slisishare") MAPDRIVE ("L:","SV4101","Slisiapps") MAPDRIVE ("M:","SV4102","Dept") MAPDRIVE ("S:","SV4103","Software") ;ADD Personal DRIVE MAPPING FOR ALL Authenticated USERS MAPDRIVE ("P:","SV4102","Slisiprivat\@USERID") |
||||||||
|
|
|||||||
Modify the line where you tried to insert Windows 7 like shown below. I think the script you posted is not the full script because at least an EndSelect is missing at the bottom of the script. Code: Case InStr (@PRODUCTTYPE, "Windows XP") Or InStr(@ProductType, "Windows 2000 Professional") Or InStr (@ProductType, "Windows 7") |
||||||||
|
|
|||||||
If your Win7 boxes are all 32bit you should have no problems, but if they are 64bit you are going to have to take into account the folders/registry locations for both 32 and 64bit apps. {edit: although it looks like you have commented out any paths that might be effected by this. Just keep this in mind.} |
||||||||
|
|
|||||||
Also, writing the log to C:\ may no longer work, as the security on Windows 7 is tighter. Consider writing to %USERPROFILE% for user-specific logs. Also, the posted script is not complete, as the original message that was being returned is not present. Glenn |
||||||||
|
|
|||||||
Thanks to you all I will be introducing those changes this weekend to see how it all works. I have taken on board all of your generous replies. I shall certainly keep you all posted with my progress and finding. Thanks everyone. Indeed I have not put all the script in as it is very large and would swamp the board. Later I will post in the varies sections and functions if thats ok thank you |
||||||||
|
|
|||||||
Hi all, I have made the change you all recommended and it all works nicely under WXP however Win7 still fails. However I did remove all select-case-case1-endselect around os checks etc and left the mapdrives section and the script executes fine. So it does show that you are all correct when you say it is an OS check failure. I honestly do not know how to resolve this and wpuld like to continue to do an OS check so your suggestions and help would be most welcome steve |
||||||||
|
|
|||||||
Please post the complete script so we can see what it is doing and what may fail. |
||||||||
|
|
|||||||
Code removed and will be put up inh sections in next posts as I work thru the newer Kix version |
||||||||
|
|
|||||||
thank for the followup guys |
||||||||
|
|
|||||||
Strange, the only part I see that checks the OS is the following line, and it should work fine. Code: Case InStr(@ProductType,"Windows XP) OR InStr(@ProductType,"Windows 2000 Professional") Or InStr(@ProductType,"Windows 7") Do you know what the trouble machines are actually showing for @ProductType? Try adding the following and testing... Code: $nul = MessageBox(@ProductType,"OS",0) |
||||||||
|
|
|||||||
I don't recall bbb mentioning what version of Kix he is using. |
||||||||
|
|
|||||||
Ahh, good point. And just as I was adding the new OS version to a new CHM too. I must be on top of things today. |
||||||||
|
|
|||||||
LOL |
||||||||
|
|
|||||||
I have checked the version and it is Kix32 Version 4.50.0.0 buoild 196 2010 |
||||||||
|
|
|||||||
Guys I think I have solved it. Put the $nul = MessageBox(@ProductType,"OS",0) in the script and behold I was given this" Windows LongHorn Media Center Edition" changed the line windows 7 for this and behold the entire script ran. Here was I winver Windows 7 Ver.... in Dos windows 6.. bla bla... wrong track entirely now it reads Case InStr(@PRODUCTTYPE, "Windows XP") Or InStr(@ProductType, "Windows 2000 Professional") Or InStr(@ProductType, "Windows LongHorn Media Center Edition") |
||||||||
|
|
|||||||
You fixed it,but the better answer is to use 4.61 instead. |
||||||||
|
|
|||||||
Yep, I agree with Allen. It would have been recognized as Windows 7 with kix 4.61. BUT...if youre going to keep your current version, i would change your code to... Code: Case InStr(@PRODUCTTYPE, "Windows XP") Or InStr(@ProductType, "Windows 2000 Professional") Or InStr(@ProductType, "Windows LongHorn") I would be reluctant to lock it down to only the media version. |
||||||||
|
|
|||||||
OK thanks for that will download and try the version you suggested will also make the change to the os check you suggested will let you know how I get on thank guys this is great help and I really appreciate it will in time try and give back to the boards where I can also.. |