3 MySQL Database Installation and Configuration for Advanced Management Console

The database for the AMC provides data storage to host all the data. The database stores information about MSI files and applications, deployment rules, and deployment rule sets. It also stores information about agents, Java Runtime Environment (JRE) statistics, and Java Installer configurations.

The AMC is also supported on Oracle Database.

This topic contains the following sections that describe software requirements and MySQL installation and configuration for the AMC:

Software Requirements for MySQL Database

To use MySQL database with Advanced Management Console , download and install a version of MySQL Server mentioned in Software Prerequisites and System Requirements for Advanced Management Console Components.

Installing MySQL Database for Advanced Management Console

This topic contains the following sections that describe MySQL installation and configuration setup instructions for Advanced Management Console on different platforms:

Installing MySQL Database on Windows

Installation and Configuration of MySQL database:

  1. To install the MySQL database for AMC, select Server only as installation type and select Server Computer as the configuration type.

  2. Configure MySQL Server as a Windows service.

  3. Follow the instructions in the setup wizard to complete the installation and configuration.

    Setting up MySQL Database for AMC:

  4. Launch the MySQL Command-Line Client. To launch the client, enter the following command in a Command Prompt window: mysql -u root -p .

    The -p option is needed only if a root password is defined for MySQL. Enter the password when prompted.

  5. Create the user (for example, amc) and a strong password:

    mysql> create user 'amc' identified by 'amc';

    To restrict access to a machine (for example, to localhost) for a user, create the user as follows:

    mysql> create user 'amc'@'localhost' identified by 'amc';

  6. Create the database (for example, amcdb) and grant all access to the user (for example, amc):

    mysql> create database amcdb;

    mysql> grant all on amcdb.* to 'amc';

    Note:

    The MySQL database user credentials provided in this topic are examples. The Advanced Management Console doesn’t need to know your MySQL database user credentials. MySQL database user credentials are only required to configure the Data Source connection in the application server.
  7. Configure your MySQL installation to handle large BLOB entries, such as AMC Agent installation bundle and MSI binaries. To handle BLOB entries, edit the MySQL Option Files.

    Any updates to the my.ini MySQL option file must be done by the administrator.

    To edit the my.ini file:

    1. Open the my.ini file in an editor. You must edit the file with administrator privileges.

      By default, the option file is located at %PROGRAMDATA%\MySQL\MySQL Server <version no>\my.ini.

    2. Set the options max_allowed_packet and innodb_log_file_size in my.ini in the [mysqld] section to the values shown:

      [mysqld]
      max_allowed_packet=300M
      innodb_log_file_size=768M
      

      Note:

      Ensure that there are no other values for max_allowed_packet and innodb_log_file_size that override the set value.
    3. Restart the MySQL service to apply changes. MySQL is a Windows Service, so it can be started or stopped from the Windows Service administrator page.

Installing and Configuring MySQL on Linux

The following are example instructions to install and configure MySQL database for the Oracle Linux distribution of Linux operating system:

Note:

The MySQL commands might change from one version to another. For the latest commands, see MySQL Reference Manual.

Before you proceed with installation, ensure that the MySQL YUM repository is added to your system's repository list. This is a one-time operation, which can be performed by installing an RPM provided by MySQL.

  1. Install the MySQL database server package.

    You can use the YUM tool to install MySQL on Oracle Linux: sudo yum install mysql-community-server.

    Note:

    A password is auto-generated for the root user. Use the following command to extract the auto generated password:
    grep 'A temporary password is generated for root@localhost' /var/log/mysqld.log |tail -1
  2. Start the MySQL service:

    sudo systemctl start mysqld

  3. Launch the MySQL Command-Line Client:

    mysql -u root -p

    The -p option is needed only if a root password is defined for MySQL. Enter the password when prompted.

    Note:

    Reset the password, if required, using the following command:
    ALTER USER 'root'@'localhost' IDENTIFIED BY '<strong password>';
  4. Create a user (for example, amc) and a strong password:

    mysql> create user 'amc' identified by '<strong password>';

    To restrict the access to a machine (for example, to localhost for a user) create the user as follows:

    mysql> create user 'amc'@'localhost' identified by '<strong password>';

  5. Create the database (for example, amcdb) and grant all access to the user, for example, amc2 as follows:

    mysql> create database amcdb;

    mysql> grant all on amcdb.* to 'amc2';

    Note:

    The MySQL database user credentials provided in this topic are examples. The Advanced Management Console doesn’t need to know your MySQL database user credentials. MySQL database user credentials are only required to configure the Data Source connection in the application server.
  6. Configure your MySQL installation to handle large BLOB entries, such as AMC Agent installation bundle and MSI binaries. To handle BLOB entries, edit the my.cnf file. For more information, see MySQL Option Files.

    To edit the my.cnf file:

    1. Open the my.cnf file in an editor. You can find the my.cnf file in one of the following locations:

      • /etc/my.cnf

      • /etc/mysql/my.cnf

      • $MYSQL_HOME/my.cnf

      • [datadir]/my.cnf

    2. Set the options max_allowed_packet and innodb_log_file_size in the [mysqld] section to the values shown:
      [mysqld]
      max_allowed_packet=300M
      innodb_log_file_size=768M
      

      Note:

      Ensure that there are no other values for max_allowed_packet and innodb_log_file_size that override the set value.
    3. Restart the MySQL service to apply changes.

      sudo systemctl mysqld restart