Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-4800

Installer uses deprecated MySQL system variable

    XMLWordPrintable

    Details

    • Complexity:
      Low
    • Sprint:
      Platform 2.0 Beta Sprint 1

      Description

      Core fails to install on recent versions of MySQL such as 5.7.9, because the default JDBC URL uses an invalid system variable 'storage_engine'. The system variable should be renamed to default_storage_engine. See https://talk.openmrs.org/t/mysql-sqlexception-unknown-system-variable-storage-engine-on-install/3905 for more details.

      The full stacktrace of the error is:
      com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Could not create connection to database server. Attempted reconnect 3 times. Giving up.
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
      at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
      at com.mysql.jdbc.Util.getInstance(Util.java:386)
      at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1015)
      at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:989)
      at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:975)
      at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:920)
      at com.mysql.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:2395)
      at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2316)
      at com.mysql.jdbc.ConnectionImpl.(ConnectionImpl.java:834)
      at com.mysql.jdbc.JDBC4Connection.(JDBC4Connection.java:47)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
      at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
      at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:416)
      at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:347)
      at java.sql.DriverManager.getConnection(DriverManager.java:664)
      at java.sql.DriverManager.getConnection(DriverManager.java:247)
      at org.openmrs.web.filter.initialization.InitializationFilter.executeStatement(InitializationFilter.java:1153)
      at org.openmrs.web.filter.initialization.InitializationFilter.access$200(InitializationFilter.java:82)
      at org.openmrs.web.filter.initialization.InitializationFilter$InitializationCompletion$1.run(InitializationFilter.java:1388)
      at java.lang.Thread.run(Thread.java:745)
      Caused by: java.sql.SQLException: Unknown system variable 'storage_engine'
      at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1086)
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4237)
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4169)
      at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2617)
      at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2778)
      at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2819)
      at com.mysql.jdbc.StatementImpl.executeUpdate(StatementImpl.java:1842)
      at com.mysql.jdbc.StatementImpl.executeUpdate(StatementImpl.java:1764)
      at com.mysql.jdbc.ConnectionImpl.setSessionVariables(ConnectionImpl.java:5588)
      at com.mysql.jdbc.ConnectionImpl.initializePropsFromServer(ConnectionImpl.java:3563)
      at com.mysql.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:2358)
      ... 16 more

        Attachments

          Activity

            People

            Assignee:
            kristopherschmidt Kristopher Schmidt
            Reporter:
            kristopherschmidt Kristopher Schmidt
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: