Knowledgebase business article search

Cannot connect to the Web Console after Linux MySQL update ESET Remote Administrator (6.x)

Issue

  • The ERA Web Console displays following error message: "Error loading data" after updating Linux ODBC Connector (mysql-connector-odbc) package to version 5.6.40-2.el7 (and later) and restarting the MySQL service  
     

If you were not logged in during the upgrade, the ERA Web Console will not connect to ERA Server and will report the error "Not connected"

You can find following error messages in the ERA Server trace log (located at /var/log/eset/RemoteAdministrator/Server/trace.log):

  • Error: CDataMinersModule [Thread 7f935ebc7700]: Failed to write some logs because: [unixODBC][Driver Manager]Can't open lib 'MySQL ODBC 5.3 Unicode Driver' : file not found (0). Rescheduling.
     
  • Error: CDatabaseModule [Thread 7fb81deef740]: Probing database connection failed. Next connection attempt will be in 10 seconds. 1 more attempt will be made. The database access layer reported: [unixODBC][Driver Manager]Can't open lib 'MySQL ODBC 5.3 Unicode Driver' : file not found (0)

Details

This issue affects all users of:

  • ERA Virtual Appliance
     
  • ERA MDM on Virtual Appliance - If you have deployed ERA MDMCore on ERA Virtual Appliance and you have update MySQL on that appliance, you can have the same problem as was described above. ERA MDMCore component will not be able to connect to its database.
     
  • ERA Virtual Agent Host - If you have deployed ERA Virtual Agent Host and you have update MySQL on that appliance, you can have the same problem as was described above. Error log can be found in /var/log/eset/RemoteAdministrator/VAgentHost/trace.log. ERA Virtual Agent Host component will not be able to connect to its database.
     
  • ERA Proxy VA - If you have deployed ERA Proxy on ERA Virtual Appliance and you have update MySQL on that appliance, you can have the same problem as was described above. Error log can be found in /var/log/eset/RemoteAdministrator/Proxy/trace.log. ERA Proxy component will not be able to connect to its database.
     
  • Linux users who use the same ODBC connector the Virtual Appliance is using

Solution

To verify your current ODBC drivers version, run the following command:

odbcinst -q -d

Drivers with version 5.3.10 or older should be listed.

Important!

MySQL database is supported up to version 5.7 and ODBC driver up to version 5.3.10. Upgrading to a higher version (5.3.11 or 8.x) of MySQL and ODBC driver is not recommended.

After the MySQL has been updated, you need to downgrade the driver.

If you have not updated yet, or after downgrading the driver, you can prevent the issue by freezing the MySQL version.

 


Downgrade the ODBC driver

If you have updated your ODBC driver, you can downgrade it and then prevent it from a further upgrade by freezing the version.

  1. Open your Virtual Machine (when running ERA Virtual Appliance/MDMCore/ERA Proxy/ERA VAH) and log in to Terminal.
     
  2. Stop MySQL service and the respective ERA service:

service mysqld stop

service eraserver stop (ERA Virtual Appliance)

service eramdmcore stop (ERA MDMCore)

service eraproxy stop (ERA Proxy)

service eravagenthost stop (ERA Virtual Agent Host)

systemd users

If your system uses the systemd service manager instead of SysVinit, the service command does not work. To determine your service manager run: 
stat /proc/1/exe 
Your service manager is listed in the first line of the output.

If your system is using systemd, use following commands to stop/restart services (services' names are the same as with SysVinit; replace the rest of the command when stopping/restarting services for other components).

systemctl stop mysqld (stop a service)

systemctl restart eraserver (restart a service)

  1. Unistall the ODBC driver:

    yum remove mysql-connector-odbc.x86_64
     
  2. Download ODBC 5.3.10 driver package:

    wget https://downloads.mysql.com/archives/get/file/mysql-connector-odbc-5.3.10-1.el7.x86_64.rpm
     
  3. Make the package executable:

    chmod +x mysql-connector-odbc-5.3.10-1.el7.x86_64.rpm
     
  4. Install ODBC driver 5.3.10:

    yum localinstall ./mysql-connector-odbc-5.3.10-1.el7.x86_64.rpm
     
  5. Edit the configuration file:

    nano /etc/opt/eset/RemoteAdministrator/Server/StartupConfiguration.ini (ERA Virtual Appliance)

    nano /etc/opt/eset/RemoteAdministrator/MDMCore/startupconfiguration.ini (ERA MDMCore)

    nano /etc/opt/eset/RemoteAdministrator/Proxy/StartupConfiguration.ini (ERA Proxy)

    nano /etc/opt/eset/RemoteAdministrator/VAgentHost/StartupConfiguration.ini (ERA Virtual Agent Host)

    Change 8.0 to 5.3 and save the file.
     
  6. Install YUM Versionlock plugin:

    yum install yum-plugin-versionlock
     
  7. Add MySQL components to the Versionlock:

    yum versionlock mysql-*
     
  8. After the downgrade, if the driver configuration was left unchanged, no further actions are needed.
    If there were any changes in driver configuration, restart MySQL service and the respective ERA component service:

    service mysqld restart

    service eraserver restart (ERA Virtual Appliance)

    service eramdmcore restart (ERA MDMCore)

    service eraproxy restart (ERA Proxy)

    service eravagenthost restart (ERA Virtual Agent Host)

    Wait a minute until the service starts and log in to ERA Web Console.
     

Prevent MySQL from updating

If you have not updated your ODBC driver yet, you can prevent yum from upgrading the ODBC driver and MySQL components by freezing current version.

  1. Open your Virtual Machine (when running ERA Virtual Appliance) and log in to Terminal.
     
  2. Install YUM Versionlock plugin:

    yum install yum-plugin-versionlock
     
  3. Add MySQL components to the Versionlock:

    yum versionlock mysql-*
     
  4. Check if there is the new entry in the Versionlock list:

    yum versionlock list
Important
  • Freezing the version in YUM will prevent MySQL components from future updates.
  • If the Versionlock does not display the MySQL in the list, try running: yum versionlock "mysql-*"

 



Was this information helpful?