Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
titleController Installer Script: js7_install_controller.sh
Usage: js7_install_controller.sh [Options] [Switches]

  Installation Options:
    --home=<directory>                  | required: directory to which the Controller will be be installed
    --data=<directory>                  | optional: directory for Controller data files, default:  <home>/var
    --config=<directory>                | optional: directory from which the Controller reads configuration files, default: <data>/config
    --logs=<directory>                  | optional: directory to which the Controller writes log files, default: <data>/logs
    --user=<account>                    | optional: user account for Controller daemon, default: $USER
    --home-owner=<account[:group]>      | optional: account and optionally group owning the home directory, requires root or sudo permissions
    --data-owner=<account[:group]>      | optional: account and optionally group owning the data directory, requires root or sudo permissions
    --controller-id=<identifier>        | optional: Controller ID, default: controller
    --release=<release-number>          | optional: release number such as 2.2.3 for download if --tarball is not used
    --tarball=<tar-gz-archive>          | optional: the path to a .tar.gz archive that holds the Controller installation or patch tarball
                                        |           if not specified the Controller tarball will be downloaded from the SOS web site
    --patch=<issue-key>                 | optional: identifies a patch from a Change Management issue key
    --patch-jar=<jar-file>              | optional: the path to a .jar file that holds the patch
    --license-key=<key-file>            | optional: specifies the path to a license key file to be installed
    --license-bin=<binary-file>         | optional: specifies the path to the js7-license.jar binary file for licensed code to be installed
                                        |           if not specified the file will be downloaded from the SOS web site
    --http-port=<port>                  | optional: specifies the http port the Controller will be operated for, default: 4444
                                                    port can be prefixed by network interface, e.g. localhost:4444
    --https-port=<port>                 | optional: specifies the https port the Controller will be operated for
                                                    port can be prefixed by network interface, e.g. batch.example.com:4444
    --pid-file-dir=<directory>          | optional: directory to which the Controller writes its PID file, default: <data>/logs
    --pid-file-name=<file-name>         | optional: file name used by the Controller to write its PID file, default: controller.pid
    --instance-script=<file>            | optional: path to the Instance Start Script that will be copied to the Controller, default <home>/bin/<instance-script>
    --backup-dir=<directory>            | optional: backup directory for existing Controller home directory
    --log-dir=<directory>               | optional: log directory for log output of this script
    --exec-start=<command>              | optional: specifies the command to start the Controller, e.g. 'StartService'
    --exec-stop=<command>               | optional: specifies the command to stop the Controller, e.g. 'StopService'
    --return-values=<file>              | optional: specifies a file that receives return values such as the path to a log file

  Configuration Options:
    --deploy-dir=<directory>            | optional: deployment directory from which configuration files are copied to the Controller
    --controller-conf=<file>            | optional: path to a configuration file that will be copied to <config>/controller.conf
    --private-conf=<file>               | optional: path to a configuration file that will be copied to <config>/private/private.conf
    --controller-primary-cert=<file>    | optional: path to Primary Controller certificate file
    --controller-secondary-cert=<file>  | optional: path to Secondary Controller certificate file
    --controller-primary-subject=<id>   | optional: subject of Primary Controller certificate
    --controller-secondary-subject=<id> | optional: subject of Secondary Controller certificate
    --joc-primary-cert=<file>           | optional: path to Primary/Standalone JOC Cockpit certificate file
    --joc-secondary-cert=<file>         | optional: path to Secondary JOC Cockpit certificate file
    --joc-primary-subject=<id>          | optional: subject of Primary/Standalone JOC Cockpit certificate
    --joc-secondary-subject=<id>        | optional: subject of Secondary JOC Cockpit certificate
    --keystore=<file>                   | optional: path to a PKCS12 keystore file that will be copied to <config>/private/
    --keystore-password=<password>      | optional: password for access to keystore
    --keystore-alias=<alias>            | optional: alias name for keystore entry
    --client-keystore=<file>            | optional: path to a PKCS12 client keystore file that will be copied to <config>/private/
    --client-keystore-password=<pass>   | optional: password for access to the client keystore
    --client-keystore-alias=<alias>     | optional: alias name for client keystore entry
    --truststore=<file>                 | optional: path to a PKCS12 truststore file that will be copied to <config>/private/
    --truststore-password=<password>    | optional: password for access to truststore
    --java-home=<directory>             | optional: Java Home directory for use with the Instance Start Script
    --java-options=<options>            | optional: Java Options for use with the Instance Start Script 
    --service-dir=<directory>           | optional: systemd service directory, default: /usr/lib/systemd/system
    --service-file=<file>               | optional: path to a systemd service file that will be copied to <home>/bin/
    --service-name=<identifier>         | optional: name of the systemd service to be created, default js7_controller_<controller-id>

   Switches:
    -h | --help                         | displays usage
    --force-sudo                        | forces use of sudo for operations on directories
    --active                            | makes Controller instance the default active node in a Controller Cluster
    --standby                           | makes Controller instance the default standby node in a Controller Cluster
    --no-install                        | skips Controller installation, performs configuration updates only
    --uninstall                         | uninstalls Controller
    --service-selinux                   | use SELinux version of systemd service file
    --show-logs                         | shows log output of the script
    --make-dirs                         | creates the specified directories if they do not exist
    --make-service                      | creates the systemd service for the Controller
    --move-libs                         | moves an existing Controller's lib directory instead of removing the directory
    --remove-journal                    | removes an existing Controller's state directory that holds the journal
    --restart                           | stops a running Controller and starts the Controller after installation
    --abortfail-over                             | abortsperforms afail-over runningin Controller Cluster if used with the --restart switch
    --killcancel                              | killscancels a running Controller if used with the --restart switch

...

  • -h | --help
    • Displays usage.
  • --force-sudo
    • Specifies that sudo is used when performing operations on directories. This switch is required if the home or data directory is not owned by the user account running the Controller Installation Script.
  • --active
    • Specifies that the Controller instance should act as the active node in a Controller Cluster during initial operation.
  • --standby
    • Specifies that the Controller instance should act as the standby node in a Controller Cluster during initial operation.
  • --no-install
    • Specifies if the Installation Script should be used to update configuration items without changes to the binary files of the installation.
      In fact no installation is performed but configuration changes as for example specified with the --keystore option will be applied.
  • --uninstall
    • Uninstalls the Controller including the steps to stop & remove a running Controller service and to remove the <home> and <data> directories.
  • --service-selinux
  • --show-logs
    • Displays the log output created by the script if the --log-dir option is used.
  • --make-dirs
    • If directories are missing that are indicated with the --home, --backup-dir or --log-dir options then they will be created.
  • --make-service
    • Specifies that a systemd service should be created for the Controller. The service will be created from the --service-name option or its default value.
  • --move-libs
    • For an existing Controller installation the lib sub-directory includes .jar files that carry the release number in their file names. If replaced by a newer version the lib directory has to be moved or removed. This switch tries to move the directory to a previous version number as indicated from the .version file in the Controller's home directory. For example, to rename lib to lib.2.3.1.
    • Files in the lib/user_lib sub-directory are preserved.
  • --remove-journal
    • If a Controller has been installed for the wrong operating mode (standalone, clustered) then the Controller's journal in the JS7_CONTROLLER_DATA/state directory can be removed. This operation removes any orders submitted to a Controller and Agents. It requires the Agents to be re-registered to the Controller.
  • --restart
    • Stops a running Controller before installation and starts the Controller after installation using the Controller's Instance Start Script. This switch can be used with the --fail-abort and over and --killcancel switches to control the way how the Controller is terminatedfail-over. This switch is ignored if the --exec-start and --exec-stop options are used.
  • --fail-over, --abort
    • Aborts a running Controller if Performs fail-over in a Controller Cluster if used with the --restart switch. Aborting an Controller includes to terminate the Controller in an orderly manner that allows to close files consistently..
    • Starting from release 2.7.2, the --fail-over switch is available, the --abort switch is an alias used by previous releases.
  • --cancel, --kill
    • Forcibly terminates
    --kill
    • Kills a running Controller if used with the --restart switch. This includes killing child processes of running tasks. In a Controller Cluster fail-over will be performed.
    • Starting from release 2.7.2, the --cancel switch is available, the --kill switch is an alias used by previous releases.

Exit Codes

    • 1: argument errors
    • 2: non-recoverable errors
    • 3: this exit code is returned when used with the --restart switch and if it cannot be identified whether a Controller instance is running
    • 4: this exit code is returned if no --tarball option is used and download of the tarball reports errors
    • 5: this exit code is returned when used with the --restart switch and if the Controller instance cannot be started
    • 6: this exit code is returned when used with the --restart switch and if the Controller instance cannot be stopped
    • 7: this exit code indicates that the Controller systemd service could not be started or stopped when using the --exec-start="StartService" or --exec-stop="StopService" options.

...