swconfig - configure software
swconfig [-p][-u][-c catalog][-f file][-t targetfile][-x option=value]
[-X options_file][software_selections][@ targets]
The swconfig command configures, unconfigures and reconfigures installed software on the target hosts specified on the command line for execution on those hosts.Configuration primarily involves executing vendor-supplied configure and unconfigure scripts. These scripts configure or unconfigure the installed software. They are only executed on the target hosts that are intended to actually run the software. Software can be configured more than once by rerunning the configure scripts.
Configuration can also be done as part of the swinstall and swremove utilities.
The swconfig utility supports the following options. Where there is no description, the description inCommon Definition for Utilities . applies.
- -c catalog
If this option is specified, then use the exported catalog structure at this path as the source of the response files.If ask=true or ask=as_needed, the control directories in the exported catalog structure are used for both the eventual source of the response files, and the control directory where the request scripts are executed in order to create any needed response files.
- -f file
- -p
- -t targetfile
- -u
- Undo configuration.
This option tells the swconfig utility to unconfigure the software, instead of configuring it.
- -x option=value
- -X options_file
The swconfig utility supports the software_selections and targets operands described inCommon Definition for Utilities .
SeeCommon Definition for Utilities for descriptions of external influences common to all utilities.Extended Options
The swconfig utility supports the following extended options. The description in
Common Definition for Utilities applies.
- allow_incompatible=false
- allow_multiple_versions=false
- ask=false
- autoselect_dependencies=true
- autoselect_dependents=false
- enforce_dependencies=true
- installed_software_catalog=implementation_defined_valuea
- logfile=implementation_defined_value
- loglevel=1
- reconfigure=false
- select_local=true
- software="
- targets=
- verbose=1
SeeCommon Definition for Utilities .
SeeCommon Definition for Utilities for general information. There are three key phases in the swconfig utility:
- Selection phase
- Analysis phase
- Execution phase
Selection Phase
Software selections apply to the software installed on the target. Each specified selection is added to the selection list after it passes the following checks:
- If the selection is not found, generate an event.
[SW_WARNING: SW_SELECTION_NOT_FOUND]
- If the selection is not found at that product location but it does exist in another location, generate an event.
[SW_WARNING: SW_SELECTION_NOT_FOUND_RELATED]
Add any dependencies to the selection list if autoselect_dependencies=true and the task is configure. Add any dependents to the selection list if the autoselect_dependents=true and the task is unconfigure.
If ask=true then execute the request scripts for the selected software as described in the swask utility. See
tagmref_swask extended description.Analysis Phase
The following checks are made:
- If configuring, check for compatibility of selections, and if the software is not compatible, generate an event. If allow_incompatible=true generate an event. See
Software Compatibility .
[SW_WARNING: SW_NOT_COMPATIBLE]If allow_incompatible=false generate an event.
[SW_ERROR: SW_NOT_COMPATIBLE]
- If configuring and the state is corrupt or transient , generate an event.
[SW_ERROR: SW_SELECTION_IS_CORRUPT]
- If the state is already configured when configuring, or not configured when unconfiguring, generate an event. This event is independent of whether the software will be reconfigured or not, which in turn is controlled by the reconfigure option.
[SW_NOTE: SW_ALREADY_CONFIGURED]
- Check whether configuring this software will create a new configured version of a fileset, and generate an event if it will. See the definition for version in the Glossary. If allow_multiple_versions=true generate an event.
[SW_WARNING: SW_NEW_MULTIPLE_VERSION]If allow_multiple_versions=false generate an event.
[SW_ERROR: SW_NEW_MULTIPLE_VERSION]
- If the dependencies are not in the configured state and have not been autoselected to be configured, generate an event. If enforce_dependencies=false generate an event.
[SW_WARNING: SW_DEPENDENCY_NOT_MET]If enforce_dependencies=true, generate an event.
[SW_ERROR: SW_DEPENDENCY_NOT_MET]
Execution Phase
The sequential relationship between the configure operations is shown in the following list. Products are ordered by prerequisite dependencies if any. Fileset operations are also ordered by any prerequisites.
- Configure each product
- Run configure script for the product.
- Configure each fileset in the product.
- Run the configure script for the fileset.
- Update the result of the script (control_file). Update the state of the fileset to configured in the database for the installed_software object.
If there is no configure script for a fileset, the state of the fileset is still changed as specified above.
For unconfigure operations, the order of the products and filesets within the products is the reverse of the order of products and filesets for configure. The operations are:
- Unconfigure each product:
- Unconfigure each fileset in the product:
- Run the unconfigure script for the fileset.
- Update the result of the script. Update the state of the fileset in the product to installed in the database for the installed_software object.
- Run the unconfigure script for the product.
If there is no unconfigure script for a fileset the state of the fileset is still changed as specified above.
Executing Configure Scripts
In this operation, swconfig executes vendor-supplied configure or unconfigure scripts.
The configure scripts are interactive; however, they may access the response file generated by an interactive request script. If any response file has been generated, it will exist in the directory pointed to by SW_CONTROL_DIRECTORY.
- If a configure script returns an error and enforce_scripts=true, generate an event and invoke the implementation defined error handling procedures.
[SW_ERROR: SW_CONFIGURE_ERROR]
- If a configure script returns an error and enforce_scripts=false, generate an event.
[SW_WARNING: SW_CONFIGURE_ERROR]
- If the configure script returns a warning, generate an event.
[SW_WARNING: SW_CONFIGURE_WARNING]
- If a configure script has a return code of 3, generate an event, and exclude the fileset (or all filesets within the product for a product level script) from any state change between configured and installed).
[SW_NOTE: SW_CONFIGURE_EXCLUDE]
SeeCommon Definition for Utilities .
SeeCommon Definition for Utilities .
Contents | Next section | Index |