FusionAuth
    • Home
    • Categories
    • Recent
    • Popular
    • Pricing
    • Contact us
    • Docs
    • Login

    MySQL driver is missing while upgrading to version 1.43.0

    Scheduled Pinned Locked Moved
    General Discussion
    3
    4
    462
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      ctorres
      last edited by

      I'm getting the Maintenance Mode Failed error screen and i see the information below in the log file after trying to upgrade from a working instance of version 1.36.0 to version 1.43.0

       MySQL driver is missing but the database configuration is pointing to a MySQL database.
      

      Here is more details about my environment/upgrade process:

      • Running on Kubernetes with MySQL being another container on the same cluster
      • Everything is working fine on version 1.36.0 so the driver is present and the DB connection is correct
      • Originally installed version 1.2x.x and then upgrade to 1.36.0 using Helm
      • Tried to upgrade to version 1.43.0 using Helm and got this error, also tried version 1.42.0 and 1.41.0
      • If i downgrade back to version 1.36.0 it works fine again
      • My Helm repo is the latest:
      NAME                    CHART VERSION   APP VERSION     DESCRIPTION
      fusionauth/fusionauth   0.12.1          1.42.0          Helm chart for FusionAuth
      
      • My parameters files is based of the latest one from here:
      https://raw.githubusercontent.com/FusionAuth/charts/master/chart/values.yaml
      
      • The parameters (for the DB configuration, etc) are the same as before when i upgraded to version 1.36.0
      • I tried to download the JAR file but wget is not available on the server and i cannot install it because the user within the container connection is not a root

      This is the complete log file:

      Defaulted container "fusionauth" out of: fusionauth, wait-for-db (init)
      Starting fusionauth-app...
        --> Logging to /usr/local/fusionauth/logs/fusionauth-app.log
      2023-02-18 01:24:48.827 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Loading FusionAuth configuration file [/usr/local/fusionauth/config/fusionauth.properties]
      2023-02-18 01:24:48.943 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Dynamically set property [fusionauth-app.url] set to [http://10.1.188.223:9011]
      2023-02-18 01:24:48.947 PM INFO  com.inversoft.configuration.BasePropertiesFileInversoftConfiguration -
        - Overriding default value of property [database.mysql.enforce-utf8mb4] with value [true]
        - Overriding default value of property [FUSIONAUTH_APP_RUNTIME_MODE] with value [production]
        - Overriding default value of property [SEARCH_TYPE] with value [database]
      
      2023-02-18 01:24:49.134 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Loading FusionAuth configuration file [/usr/local/fusionauth/config/fusionauth.properties]
      2023-02-18 01:24:49.137 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Dynamically set property [fusionauth-app.url] set to [http://10.1.188.223:9011]
      2023-02-18 01:24:49.141 PM INFO  com.inversoft.configuration.BasePropertiesFileInversoftConfiguration -
        - Overriding default value of property [database.mysql.enforce-utf8mb4] with value [true]
        - Overriding default value of property [FUSIONAUTH_APP_RUNTIME_MODE] with value [production]
        - Overriding default value of property [SEARCH_TYPE] with value [database]
      
      2023-02-18 01:24:49.577 PM INFO  com.inversoft.maintenance.DefaultMaintenanceModeWorkflow -
      
      ---------------------------------------------------------------------------------------------------------
      ---------------------------------- Entering Silent Configuration Mode -----------------------------------
      ---------------------------------------------------------------------------------------------------------
      
      2023-02-18 01:24:49.579 PM ERROR com.inversoft.maintenance.db.DatabaseSilentModeWorkflowTask - Encountered an error while running silent mode
      java.lang.IllegalStateException: MySQL driver is missing but the database configuration is pointing to a MySQL database.
              at com.inversoft.maintenance.db.JDBCMaintenanceModeDatabaseService.lockDatabase(JDBCMaintenanceModeDatabaseService.java:291)
              at com.inversoft.maintenance.db.DatabaseSilentModeWorkflowTask.perform(DatabaseSilentModeWorkflowTask.java:43)
              at com.inversoft.maintenance.DefaultMaintenanceModeWorkflow.performSilentConfiguration(DefaultMaintenanceModeWorkflow.java:47)
              at com.inversoft.maintenance.BaseMaintenanceModePrimeMain.modules(BaseMaintenanceModePrimeMain.java:70)
              at org.primeframework.mvc.BasePrimeMain.hup(BasePrimeMain.java:69)
              at org.primeframework.mvc.BasePrimeMain.start(BasePrimeMain.java:100)
              at io.fusionauth.app.FusionAuthMain.main(FusionAuthMain.java:27)
      2023-02-18 01:24:51.044 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Loading FusionAuth configuration file [/usr/local/fusionauth/config/fusionauth.properties]
      2023-02-18 01:24:51.048 PM INFO  io.fusionauth.api.configuration.DefaultFusionAuthConfiguration - Dynamically set property [fusionauth-app.url] set to [http://10.1.188.223:9011]
      2023-02-18 01:24:51.051 PM INFO  com.inversoft.configuration.BasePropertiesFileInversoftConfiguration -
        - Overriding default value of property [database.mysql.enforce-utf8mb4] with value [true]
        - Overriding default value of property [FUSIONAUTH_APP_RUNTIME_MODE] with value [production]
        - Overriding default value of property [SEARCH_TYPE] with value [database]
      
      2023-02-18 01:24:51.810 PM INFO  com.inversoft.maintenance.MaintenanceModePoller - Poller started to Wait for configuration to be completed.
      2023-02-18 01:24:51.818 PM INFO  io.fusionauth.app.primeframework.FusionHTTPContextAuthSetup - Initializing the FusionAuth HTTP Context.
      2023-02-18 01:24:51.848 PM INFO  org.primeframework.mvc.PrimeMVCRequestHandler - Initializing Prime
      2023-02-18 01:24:51.850 PM INFO  org.primeframework.mvc.PrimeMVCRequestHandler - Initializing Prime
      2023-02-18 01:24:51.852 PM INFO  io.fusionauth.http.server.HTTPServer - Starting the HTTP server. Buckle up!
      2023-02-18 01:24:51.881 PM INFO  io.fusionauth.http.server.HTTPServer - HTTP server listening on port [9011]
      2023-02-18 01:24:51.882 PM INFO  io.fusionauth.http.server.HTTPServer - HTTP server started successfully
      2023-02-18 01:24:51.883 PM INFO  io.fusionauth.http.server.HTTPServer - Starting the HTTP server. Buckle up!
      2023-02-18 01:24:51.884 PM INFO  io.fusionauth.http.server.HTTPServer - HTTP server listening on port [9012]
      2023-02-18 01:24:51.885 PM INFO  io.fusionauth.http.server.HTTPServer - HTTP server started successfully
      

      Please help.

      Thanks

      danD 1 Reply Last reply Reply Quote 0
      • R
        rory.gwgehman
        last edited by

        It seems that the MySQL driver is missing, which is causing the Maintenance Mode Failed error after upgrading FusionAuth from version 1.36.0 to versions 1.41.0, 1.42.0, and 1.43.0.

        Here are some suggestions to help resolve the issue:

        Check the FusionAuth container and ensure that the MySQL driver is present in the classpath. If it is not, try adding it manually to the classpath or update your container image to include the driver.

        Verify that the MySQL container is running and accessible. Check that the database URL, username, and password in your configuration file are correct.

        Check the version of MySQL in the container and make sure it is compatible with the version of the MySQL driver being used by FusionAuth.

        Try upgrading to an intermediate version of FusionAuth first. For example, upgrade to version 1.38.0 before upgrading to 1.43.0, to see if the issue persists.

        If you are still having issues, check the FusionAuth support forums for similar issues or open a ticket with FusionAuth support. They may be able to provide additional guidance or assistance with resolving the issue.

        1 Reply Last reply Reply Quote 0
        • danD
          dan @ctorres
          last edited by

          @ctorres Unfortunately, the MySQL driver can no longer be bundled with FusionAuth due to license concerns.

          From https://fusionauth.io/docs/v1/tech/release-notes#version-1-40-0

          If you are using MySQL or plan to use MySQL you will need to manually download the JDBC connector to allow FusionAuth to connect to a MySQL database. If you are using PostgreSQL, this change will not affect you. See the installation guide for additional information. We apologize in advance for the inconvenience this causes you, but the Oracle GPL licensing model makes it difficult for FusionAuth to easily delivery this capability.

          Here are some instructions on how to create your own Docker image: https://fusionauth.io/docs/v1/tech/installation-guide/docker#limitations

          --
          FusionAuth - Auth for devs, built by devs.
          https://fusionauth.io

          1 Reply Last reply Reply Quote 0
          • C
            ctorres
            last edited by

            Thank you, this worked.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post