简体   繁体   English

如何在没有pom.xml文件的OpenShift中安装MYSQL JDBC DRIVER?

[英]How to install MYSQL JDBC DRIVER in OpenShift without pom.xml file?

I am trying to deploy OpenGTS_2.6.0 on OpenShift online where I have Tomcat7 MySQL-5.5 and Ant Cartridge 0.1.So I don't know how to install the mysql jdbc driver into tomcat and java directory and my project is ant based not a maven based project. 我正在尝试在具有Tomcat7 MySQL-5.5和Ant Cartridge 0.1的OpenShift在线上部署OpenGTS_2.6.0。基础项目。

>Version: 2.6.0
[WARN_|DBProvider.loadJDBCDriver:806] JDBC driver class not found: com.mysql.jdbc.Driver
[WARN_|DBProvider.loadJDBCDriver:806] JDBC driver class not found: org.gjt.mm.mysql.Driver
[WARN_|DBProvider.loadJDBCDriver:806] JDBC driver class not found: org.mariadb.jdbc.Driver
[ERROR|DBProvider.loadJDBCDriver:827] -------------------------------------------------------------------------
[ERROR|DBProvider.loadJDBCDriver:832] Install the JDBC jar file in one of the following directories:
[ERROR|DBProvider.loadJDBCDriver:834]  > /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.91/jre/lib/ext
[ERROR|DBProvider.loadJDBCDriver:834]  > /usr/java/packages/lib/ext
[ERROR|DBProvider.loadJDBCDriver:843] (NOTE: The installed jar file permissions must also be world-readable)
[ERROR|DBProvider.loadJDBCDriver:844] -------------------------------------------------------------------------
[ERROR|DBAdmin.execCommands:940] SQLException message: No suitable driver found for jdbc:mysql://localhost:3306/
[ERROR|DBAdmin.execCommands:941] ==> SQLException: DB create error [jdbc:mysql://localhost:3306/]
[ERROR|DBAdmin.execCommands:941] Message:   No suitable driver found for jdbc:mysql://localhost:3306/
[ERROR|DBAdmin.execCommands:941] SQLState:  08001
[ERROR|DBAdmin.execCommands:941] ErrorCode: 0
[DBAdmin.execCommands:941] java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost:3306/
java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost:3306/
        at java.sql.DriverManager.getConnection(DriverManager.java:596)
        at java.sql.DriverManager.getConnection(DriverManager.java:215)
        at org.opengts.dbtools.DBConnection.getConnection(DBConnection.java:662)
        at org.opengts.dbtools.DBConnection.createStatement(DBConnection.java:772)
        at org.opengts.dbtools.DBConnection.createStatement(DBConnection.java:760)
        at org.opengts.dbtools.DBConnection._executeUpdate(DBConnection.java:1014)
        at org.opengts.dbtools.DBConnection.executeUpdate(DBConnection.java:969)
        at org.opengts.dbtools.DBConnection.executeUpdate(DBConnection.java:950)
        at org.opengts.dbtools.DBProvider.createDatabase(DBProvider.java:1699)
        at org.opengts.dbtools.DBAdmin.execCommands(DBAdmin.java:929)
        at org.opengts.db.DBConfig._main(DBConfig.java:1833)
        at org.opengts.db.DBConfig.main(DBConfig.java:1948)

Straight from the Tomcat documentation : 直接来自Tomcat文档

Before you proceed, don't forget to copy the JDBC Driver's jar into $CATALINA_HOME/lib. 在继续之前,请不要忘记将JDBC驱动程序的jar复制到$ CATALINA_HOME / lib中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM