Sun Java Enterprise System 2004Q2 Installation Guide |
Chapter 6
Installing Software in Silent ModeThis chapter includes the following sections:
Overview of Silent InstallationSilent installation is useful for installing Java Enterprise System on multiple hosts that share similar configurations. Silent installation requires that you run the installer once to capture the values that you provide in a state file. The state file that contains your responses is a list of parameters, each representing a single prompt or field.
You can then run the installer on many hosts, using the same state file as input. This process propagates one configuration across multiple hosts in your enterprise.
If you are an experienced user of Java Enterprise System components, you might be accustomed to building state files manually. This method can cause problems at installation time, configuration time, or server start-up time.
Guidelines for a successful silent installation:
- Before using the installer to generate a state file, verify that you have performed the tasks on the Preinstallation Checklist.
- Allow the installer to generate the state file for you, as described in Generating a State File.
Do not create an original state file. A state file generated by the installer takes advantage of the installer’s real-time dependency checking and error reporting.
- Save a copy of the state file before making any edits.
- Do not modify parameters, except to edit their values.
- Use these guidelines when editing the values:
Generating a State FileTo generate a state file, you must first run the installer using the graphical interface or the text-based interface following the instructions in either Chapter 4, "Installing Software Using the Graphical Interface" or Chapter 5, "Installing Software Using the Text-Based Interface". It is especially important to verify that you have performed the tasks on the preinstallation checklist.
To Generate a State File
- To create a state file, you will run the installer without actually installing the software. Use the following syntax to provide a pathname for the state file:
./installer [-no] [-nodisplay] -saveState [statefile]
where:
- Follow the instructions in one of the following sections, depending on whether you are creating your state file using the graphical interface or the text-based interface:
- Proceed through the pages of the installer.
As you respond to the installer, it records your answers in the state file. When you complete the installation, the state file is available in the location that you specified. You are now ready to make copies of the state file and edit values for the various machines where you are going to install the Java Enterprise System silently.
Editing the State FileBefore you perform a silent installation, you must edit the state file to ensure that local parameters such as host name, domain name, IP address, and other such settings are appropriate for the various destinations machines.
You might also need to change the state file key, if you plan to install on an operating system platform that is different from the one on which you created the state file.
This section addresses the following:
Editing Local Parameters
The following table lists parameters that you might need to edit, depending on the component products you installed. The parameters you must edit also depend on your machine setup. For example, the machine on which you generated the state file might be in the same domain as the machine on which you are installing, or not.
For a description of each parameter, refer to Chapter 3, "Gathering Installation and Configuration Information."
Creating a Platform-Appropriate State File ID
A state file can only be run on a machine of the same platform type where you generated the state file unless you edit the state file ID manually. There is a different type of state file ID for the following platforms:
There are two procedures for editing a state file so that you can run it on a platform other than the one on which it was created.
To Generate a State File ID Using the Installer
This procedure generates a state file ID by running the installer on the platform on which you want to perform silent installation.
- If you are not logged in as root, become superuser.
- Navigate to the directory where the installer is located:
cd installer-dir
- Run the installer with the -id option.
./installer -id
The command generates an encrypted identifier.
- Copy the identifier and paste the value into the state file, as the value for the STATE_BEGIN and STATE_DONE parameters.
The following is an example of the state file identifier within a state file:
[STATE_BEGIN Sun Java(tm) Enterprise System f31c7e86a64605bc5b9b629931a30b275a0eb447]
.
.
.
[STATE_DONE Sun Java(tm) Enterprise System f31c7e86a64605bc5b9b629931a30b275a0eb447]
To Generate a State File ID Using Platform-Specific Distribution Files
This procedure generates a state file ID by using the Java Enterprise System distribution files for a specific platform. The Java Enterprise System distribution DVD contains all of the platform-specific distributions. This procedure also works if you downloaded a single platform-specific distribution.
- Navigate to the platform-specific .install directory:
cd platform/.install
where the value of platform can be Solaris_sparc, Solaris_x86 or Linux_x86.
- Enter one of the following commands to generate the ID for a specific platform:
- Copy the identifier and paste the value into the state file, as the value for the STATE_BEGIN and STATE_DONE parameters.
The following is an example of the state file identifier within a state file:
Running the Installer in Silent ModeRun the installer on a machine that has the same operating system as the machine on which you generated the state file. If you cannot do this, refer to Creating a Platform-Appropriate State File ID.
This section contains the following procedures:
If you have problems during uninstallation, refer to Chapter 11, "Troubleshooting".
To Run the Installer in Silent Mode
- Open a terminal window on the host where you want to install the Java Enterprise System components.
- If you are not logged in as root, become superuser.
- Navigate to the directory where the installer program is located.
cd installer-directory
- Start the installer with the following options:
./installer -nodisplay -noconsole -state statefile
where
Silent installation can be lengthy, depending on the number and type of components that you are installing. While the installer is running, you can monitor its progress by examining changes to the installation log.
To Monitor the Progress of a Silent Installation
- In a terminal window, use the cd command to change to the log file directory, /var/sadm/install/logs on Solaris and /var/opt/sun/install/logs on Linux.
- Locate the log files for the current installation.
There are two log files. The shared components are installed first installation and the components products follow. The two log files have names based on the following format:
Java_Enterprise_System_Shared_Component_Install.datetimestamp Java_Enterprise_System_install.Bdatetimestamp
The timestamp variable represents the time the log was created. It has the format MMddhhmm, where:
- Use the tail command to watch messages as they are written to the logs. Use this format:
tail -f log-file-name
Next StepsAt the end of this chapter you should have completed the installer portion of your Java Enterprise System installation. Proceed to Postinstallation Configuration and Startup for final instructions on configuring the component products for your environment.
If you want to make an installation image available to other administrators in your enterprise, refer to Setup Instructions for Network Installation.