Using the GlassFish ESB Installation CLI

ProcedureTo Generate the State File for Silent Installations

  1. Download the installation executable file for your platform from https://open-esb.dev.java.net/Downloads.html.

  2. Navigate to the location of the file.

  3. Run the file from the command line with the --silent and --record options, specifying where you want to save the state file.

    For example:

    glassfishesb-v2.1-full-installer-solaris-sparc.sh --silent --record /home/glassfishesb/state.xml


    Note –

    A log file is generated in your home directory under /.glassfishesb-v2.1-full-installer-hostname_date/log so you can track the progress of the installation. For Windows, this file is located in \Documents and Settings\user_name.


  4. When the installer is finished, run the GlassFish ESB uninstaller

    and remove the GUI installation.


    Note –

    For detailed information about running the GlassFish ESB uninstaller, see Uninstalling GlassFish ESB.


  5. Using a text editor or XML editor, open the state file and modify the installation properties to correspond to your custom requirements.

    Ensure that items such as user names, passwords, directories, and so on are correct. You can view a sample state file following these instructions.

  6. Save any changes, and close the state file.

  7. After creating the state file, note the file location and name, and then continue to Installing GlassFish ESB Silently Using Custom Settings.


Example 1 Excerpt From the State File Generated by the GlassFish ESB GUI Installer


<?xml version="1.0" encoding="UTF-8"?>
<state xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
       xsi:noNamespaceSchemaLocation="state-file.xsd">
<properties>
        <property name="street.address.windows-x86.en_US"/>
        <property name="country.windows-x86.en_US">United States</property>
        <property name="company.windows-x86.en_US"/>
        <property name="password.windows-x86.en_US"/>
        <property name="email.address.windows-x86.en_US"/>
        <property name="first.name.windows-x86.en_US"/>
        <property name="last.name.windows-x86.en_US"/>
        <property name="register.choice.windows-x86.en_US">skip</property>
        <property name="zip.code.windows-x86.en_US"/>
        <property name="city.windows-x86.en_US"/>
    </properties>
    <components>
        <product platform="windows linux solaris-sparc solaris-x86 macosx-ppc macosx-x86" 
                 status="to-be-installed" uid="nb-base" version="6.1.0.0.200809090101">
            <properties>
                <property name="start.menu.shortcut.location.windows-x86.en_US">all.users</property>
                <property name="desktop.shortcut.location.windows-x86.en_US">all.users</property>
                <property name="jdk.location.windows-x86.en_US">C:\Program Files\Java\jdk1.6.0_07</property>
                <property name="installation.location">$N{install}/netbeans</property>
                <property name="installation.location.windows">$N{install}/netbeans</property>
                <property name="installation.location.macosx">$N{install}/netbeans.app</property>
                <property name="installation.location.windows-x86.en_US">C:\GlassFishESB\netbeans</property>
            </properties>
        </product>
        <product platform="windows linux solaris-sparc solaris-x86 macosx-ppc macosx-x86" 
                 status="to-be-installed" uid="nb-soa" version="6.1.0.0.80909">
            <properties>
                <property name="installation.location.windows-x86.en_US">C:\GlassFishESB\netbeans</property>
            </properties>
        </product>
        <product platform="windows" status="to-be-installed" uid="glassfish" version="9.1.0.4.20080411">
            <properties>
                <property name="admin.port.windows-x86.en_US">4848</property>
                <property name="jdk.location.windows-x86.en_US">C:\Program Files\Java\jdk1.6.0_07</property>
                <property name="http.port.windows-x86.en_US">8080</property>
                <property name="https.port.windows-x86.en_US">8181</property>
                <property name="password.windows-x86.en_US">adminadmin</property>
                <property name="installation.location">$N{install}/glassfish</property>
                <property name="username.windows-x86.en_US">admin</property>
                <property name="installation.location.windows-x86.en_US">C:\GlassFishESB\glassfish</property>
            </properties>
        </product>
        <product platform="windows linux solaris-sparc solaris-x86 macosx-ppc macosx-x86" 
                 status="to-be-installed" uid="openesb" version="2.0.0.80909.0">
            <properties>
                <property name="password.windows-x86.en_US">adminadmin</property>
                <property name="username.windows-x86.en_US">admin</property>
                <property name="installation.location.windows-x86.en_US">
                          C:\GlassFishESB\glassfish\addons\jbi-components</property>
            </properties>
        </product>
        <product platform="windows linux solaris-sparc solaris-x86 macosx-ppc macosx-x86" 
                 status="to-be-installed" uid="jbicomponents" version="2.0.0.80909.1">
            <properties>
                <property name="password.windows-x86.en_US">adminadmin</property>
                <property name="username.windows-x86.en_US">admin</property>
                <property name="installation.location.windows-x86.en_US">
                          C:\GlassFishESB\glassfish\addons\jbi-components</property>
            </properties>
        </product>
    </components>
</state>