Skip to main content

Unattended installation of a remote server

To install a remote server quicker, you can use a script. This will perform all installation steps. You must then register the remote server and attach it to the central server.

Prerequisites​

  1. Update your system:

    dnf update
    subscription-manager register --username my_username --password my_password --auto-attach --force
    subscription-manager repos --enable codeready-builder-for-rhel-9-x86_64-rpms

    Replace my_username and my_password with your Red Hat account credentials.

  2. Download the script:

    curl -L https://download.centreon.com/26.10/unattended.sh --output /tmp/unattended.sh

Installation​

  1. As root, run the script with the options you want. The script writes a full log, including any errors, to /var/log/centreon-unattended-<date>.log.

    Here is the basic command (installs MariaDB with no TLS):

    bash /tmp/unattended.sh install -t central -v 26.10

    And here are the options you can pass (see the examples below):

    OptionDescription
    -d <database>Database to install. By default, the script installs MariaDB: use -d mysql to install MySQL instead.
    --tls enabledInstalls the central server in TLS mode: the connections to the web interface and to the database are encrypted. Without this option, the central server is installed without TLS. Note that on some OSs, cryptographic policies may prevent the script from running correctly.
    -p <password>Password of the default admin database account. If you omit this option, the script generates a password and tells you where it is stored.
    -sSilent installation: the script does not prompt you for anything.
    -l <level>Level of detail of the log file: DEBUG, INFO, WARN or ERROR.

    To display the full list of options, run:

    bash /tmp/unattended.sh -h
  2. Go to http(s)://<SERVER_IP>/centreon (where <SERVER_IP> is your server's IP address) and log in. Then follow the initialization of the monitoring steps.

  3. Once the script has run, carry out steps 5 to 8 of the standard installation procedure for a remote server.

  4. Start using Centreon: follow our Getting started guide to start monitoring your resources.

Examples​

SettingsCommand
Using MariaDB and no TLS
bash /tmp/unattended.sh install -t central -v 26.10
Using MySQL and no TLS
bash /tmp/unattended.sh install -t central -v 26.10 -s -d mysql
Using MariaDB and TLS
bash /tmp/unattended.sh install -t central -v 26.10 -s --tls enabled
Using MySQL and TLS
bash /tmp/unattended.sh install -t central -v 26.10 -s -d mysql --tls enabled