Jon (LabKey DevOps) responded: |
2017-04-04 12:22 |
Hello Atul,
According to the error, you do not have a labkeyDataSource resource in your labkey.xml file, which is triggering the error.
The error is unrelated to your mySqlDataSource unless you accidentally removed the main labkeyDataSource resource entry in your XML file.
Can you check your labkey.xml file and make sure you have a labkeyDataSource resource element?
Regards,
Jon |
|
atul sharma responded: |
2017-04-04 23:53 |
Dear Jon,
I have added labkeyDataSource which was removed when mySqlDataSource have been added.(Now both the resources are mentioned)
Now the server is connected, but when I go to Schema Browser->Schema Administartion->New External Schema.
The field named "Data Source" is pre-populated with labkey and There is no option for mysql Data Source.
What shall I do? Please Suggest.
I have a database in mysql and the database have tables. |
|
Jon (LabKey DevOps) responded: |
2017-04-05 00:13 |
Hi Atul,
Can you provide us with your labkey.xml file and your labkey.log file?
The log file should state whether the connection was successful and the xml file will show us if you've configured things properly or not.
Feel free to remove or obscure the password from the xml file before you send it to us.
Regards,
Jon |
|
atul sharma responded: |
2017-04-05 01:15 |
Dear Jon,
PFA
Regards
Atul |
|
|
adam responded: |
2017-04-05 07:08 |
Your log shows that the MySQL connection failed with this root exception:
java.lang.ClassNotFoundException: com.yyy.tomcat.jndi.EncryptedDataSourceFactory
Your DataSource configuration now specifies factory="com.yyy.tomcat.jndi.EncryptedDataSourceFactory" and Tomcat/JNDI can't find this class. I suggest you return to the standard MySQL DataSource configuration you posted initially, which didn't include this property.
If you're sure you need this factory, then you'll need to get it on the class path, perhaps by adding its jar to your /tomcat/lib folder. We aren't familiar with "EncryptedDataSourceFactory"; you'll need to contact the developer of this class if you need help configuring it.
Adam |
|
atul sharma responded: |
2017-04-06 01:57 |
Dear Adam,
The configuration is set to standard MySql Data Source.
Please Find labkey.xml and log file.
MySql DataSource option is still not visisble.
PFA |
|
|
Jon (LabKey DevOps) responded: |
2017-04-07 19:06 |
Hi Atul,
The error in the log clearly states why it failed. The cause was due to a username/password failure.
Please confirm that your credentials are correct for the SQL server you're trying to connect to as an External DataSource.
Regards,
Jon
ERROR DbScope 2017-04-06 12:02:16,495 localhost-startStop-1 : Cannot connect to DataSource "mySqlDataSource" defined in labkey.xml. This DataSource will not be available during this server session.
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Could not create connection to database server. Attempted reconnect 3 times. Giving up.)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createPoolableConnectionFactory(BasicDataSource.java:1549)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1388)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044)
at org.labkey.api.data.DbScope.<init>(DbScope.java:309)
at org.labkey.api.data.DbScope.addScope(DbScope.java:1084)
at org.labkey.api.data.DbScope.initializeScopes(DbScope.java:1052)
at org.labkey.api.module.ModuleLoader.initializeDataSources(ModuleLoader.java:917)
at org.labkey.api.module.ModuleLoader.doInit(ModuleLoader.java:330)
at org.labkey.api.module.ModuleLoader.init(ModuleLoader.java:240)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4908)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5602)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:899)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:875)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:679)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1966)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: 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:423)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:404)
at com.mysql.jdbc.Util.getInstance(Util.java:387)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:917)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:896)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:885)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:860)
at com.mysql.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:2163)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2088)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:806)
at com.mysql.jdbc.JDBC4Connection.<init>(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:423)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:404)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:410)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:328)
at org.apache.tomcat.dbcp.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:38)
at org.apache.tomcat.dbcp.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:1556)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createPoolableConnectionFactory(BasicDataSource.java:1545)
... 24 more
Caused by: java.sql.SQLException: Access denied for user 'root'@'172.21.205.146' (using password: YES)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:963)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3966)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3902)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:875)
at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1712)
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1228)
at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2253)
at com.mysql.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:2104)
... 38 more |
|