none
Different Aplication Install Command for Different Task Sequence

    Question

  • So I have windows 7 with different languages, and I'm installing same application bundle over them. I needed to install the application according to the OS language, hence i needed to tweak around with the quiet install command. Say if I'm installing the application in Win 7 Japanese language, i needed the application to be installed as Japanese language as well.

    Is it possible to provide different quiet install command based on which task sequence was employed?

    Thursday, May 02, 2013 4:10 AM

Answers

  • Rens is quite right, If you create 5 different applications with 5 command lines you can assign them directly. I've done that, importing the app once, then for subsequent ones creating apps "with no source files or elsewhere on the network" and pointing the new command line to the existing .\application folder.

    You can also if you're clever create an install script that uses a command line argument, and pass in a variable as needed

    msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=%MyOSVariable%

    There's a half dozen different ways to do that, however all assume a certain level of skill in scripting

    • Marked as answer by Jack_Tan Friday, May 03, 2013 6:05 AM
    Thursday, May 02, 2013 7:55 PM
  • Jack,

    I think you are missing something here. What you need to do is:

    If you have 1 application which you need to install 5 times (because you have 5 OS Languages) you then need to add this application 5 times, each time with another OS Language code:

    App1: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1033
    App2: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1031
    App3: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1041
    App4: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=0417
    App5: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=2057

    Then you place a condition on each step, which queries that this step may only executed if the OS Language = 1033 for example. This way only the application which matches the result of your query will be executed. Hope this clarify's it some bit?

    Good luck!

    edit: you can resolve this in anotherway with a script and possible task sequence variable to make things more flexible. But if you just want to get the job done. This is the easiest way :)


    If this post is helpful please click "Mark for answer", thanks! Kind regards


    Thursday, May 02, 2013 11:22 AM
  • Yes, you've pretty much got it. The syntax is important, sometimes proper placement of quotes can be fussy, and all your variables and queries need to be precise, but it does work.

    For example I set a ServerB variable in the MDT database location record and use it to create a command line for installing the Altiris client to the correct notification server based on site. I have a vbscript that takes a command line argument, and in the application, I use the ts variable for the argument like so:

    cscript "%SCRIPTROOT%\Altiris\install_args.vbs"  "/NS:%SERVERB%"

    (If I was typing that at a command prompt it would be   cscript install_args.vbs /ns:server01.mydomain.com)

    • Marked as answer by Jack_Tan Wednesday, May 08, 2013 5:56 AM
    Friday, May 03, 2013 5:16 PM

All replies

  • You should put an WMI query on your applications which you want to install depending on the OS language.


    Something like this, place a condition on a "Run Command Line" or "Install Application" step > Condition: "This step may run if all of the following conditions are true"


    and then you use a WMI query:

    select * from win32_OperatingSystem where OSLanguage=1033

    For a list of OS Language and Locale numbers (the four digit number), please check here: Windows Locale Codes - Sortable list

    Edit, so what you need to provide is an "Install application in Japanese" with a query for Japanese OSLanguage, "Install application in Englisch" with query for English OSLanguage. Or you need to work with a variable which you place into your install / quiet string, which looks at the OS language and then uses this value to install the application with the same language as your OS. But the solution I provided is less complicated, you can add 1 application multiple times, each time with another installation string.


    If this post is helpful please click "Mark for answer", thanks! Kind regards

    Thursday, May 02, 2013 7:50 AM
  • Thank you for the WMI query part. That certain help getting the OS locale language for starters.

    However for the second part, how do i put in "install application with japanese language" string to the application? By default a silent install string is provided when I first import the application into MDT, so how to u override the default silent install string? For example by default my application will install in English, so after using WMI query i found out that i need to install the application in japanese language, how do replace the default silent install string with "install application in Japanese language" string?

    I can add the same application many times with the appropriate silent install string for each language i needed, but that doesn't seem to be neat doesn't it?

    Thanks for your advice once again!

    Thursday, May 02, 2013 10:32 AM
  • Hi Jack,

    You need to be sure the application you are installing supports multiple languages, if so. Please check the documentation of the vendor for support for your installation string.


    If this post is helpful please click "Mark for answer", thanks! Kind regards

    Thursday, May 02, 2013 10:34 AM
  • Yes it does. For example, this is the install string I've provided for the application.

    msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1041

    This string installs Japanese language. So if I've encounter other language all i need to do is change the language parameter value to the Windows Locale code you provided. I just need to know if there is anyway changing the install string after the WMI query.

    Thursday, May 02, 2013 10:44 AM
  • Jack,

    I think you are missing something here. What you need to do is:

    If you have 1 application which you need to install 5 times (because you have 5 OS Languages) you then need to add this application 5 times, each time with another OS Language code:

    App1: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1033
    App2: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1031
    App3: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=1041
    App4: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=0417
    App5: msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=2057

    Then you place a condition on each step, which queries that this step may only executed if the OS Language = 1033 for example. This way only the application which matches the result of your query will be executed. Hope this clarify's it some bit?

    Good luck!

    edit: you can resolve this in anotherway with a script and possible task sequence variable to make things more flexible. But if you just want to get the job done. This is the easiest way :)


    If this post is helpful please click "Mark for answer", thanks! Kind regards


    Thursday, May 02, 2013 11:22 AM
  • Rens is quite right, If you create 5 different applications with 5 command lines you can assign them directly. I've done that, importing the app once, then for subsequent ones creating apps "with no source files or elsewhere on the network" and pointing the new command line to the existing .\application folder.

    You can also if you're clever create an install script that uses a command line argument, and pass in a variable as needed

    msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=%MyOSVariable%

    There's a half dozen different ways to do that, however all assume a certain level of skill in scripting

    • Marked as answer by Jack_Tan Friday, May 03, 2013 6:05 AM
    Thursday, May 02, 2013 7:55 PM
  • Wonderful Solution. Works like a charm.

    • Edited by Jack_Tan Friday, May 03, 2013 7:05 AM
    Friday, May 03, 2013 4:12 AM
  • Ok for example, based on your idea, I would put a Set Task Sequence Variable step before the Install Application step.

    In that Set Task Sequence Variable, I would query the System's Locale via WMI, and set the variable to the locale codes here.

    Now next step i would like to inject that locale code into the command line, like what've you shown above.

    Say if I name the Task Sequance Variable as LANG_ID, i would  have a command line of

    msiexec /i CiscoJabberSetup-9.1.msi /qb TYPE=CUP LANGUAGE=%LANG_ID% ?

    I wanted to try this is that although it works by importing the application multiple times i'd like to have some neatness and importing the application only once if possible. Thank you for your time!

    Friday, May 03, 2013 4:22 AM
  • Yes, you've pretty much got it. The syntax is important, sometimes proper placement of quotes can be fussy, and all your variables and queries need to be precise, but it does work.

    For example I set a ServerB variable in the MDT database location record and use it to create a command line for installing the Altiris client to the correct notification server based on site. I have a vbscript that takes a command line argument, and in the application, I use the ts variable for the argument like so:

    cscript "%SCRIPTROOT%\Altiris\install_args.vbs"  "/NS:%SERVERB%"

    (If I was typing that at a command prompt it would be   cscript install_args.vbs /ns:server01.mydomain.com)

    • Marked as answer by Jack_Tan Wednesday, May 08, 2013 5:56 AM
    Friday, May 03, 2013 5:16 PM
  • Thank you very much for the example. It certainly gives me some insight how scripting works.

    Last but not least do you have any sources regarding vbscripting? I'm interested in picking up some basics of it.

    Wednesday, May 08, 2013 5:58 AM
  • Jack,

    Have a look over here:

    VBScript Tutorial

    Scripting: Your First Steps


    If this post is helpful please click "Mark for answer", thanks! Kind regards

    Wednesday, May 08, 2013 7:12 AM