I am using CPBM 2.1 with the ACS Connector. The Portal DB user is configured as “cpbm”. When I click on ‘My Services’ I get the following SQL Exception in the cpbm-server.log…it appears to be using the “cloud” user, which does not exist in the DB.
1. Where is this "cloud" user configured? 2. What resource is it trying to acquire?
[2013-09-26 09:40:29.885] WARN chronousRunner$PoolThread-#1 com.mchange.v2.resourcepool.BasicResourcePool com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask@7b64b287 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (30). Last acquisition attempt exception: java.sql.SQLException: Access denied for user 'cloud'@'192.168.56.11' (using password: YES) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1074) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4120) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4052) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:925) at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1704) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1250) at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2465) at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2498) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2283) at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:822) at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47) at sun.reflect.GeneratedConstructorAccessor117.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:532) at com.mysql.jdbc.Util.handleNewInstance(Util.java:411) at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:404) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:317) at com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:134) at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:182) at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:171) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:137) at com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1014) at com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:32) at com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1810) at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)
When configuring the Service Instance, under 'Configuration' there is an 'Advanced Settings' link. Clicking this reveals the configuration fields for accessing the CloudPlatform/Usage databases - by default these contain the 'cloud' user. These fields must be updated to reflect your DB access settings.
I setup my CPBM 2.1 environment using the CPBMcookbook document - Section 2.2 step 8: configures a MySQL user = cpbm to access the CCP databases. Further on in the document on the Service Instance Configuration page it uses the cpbm user for the Cloud JDBC settings, but does not go on to configure any of the Cloud Usage parameters under Advanced Settings.
By default the 'Cloud Usage JDBC Username' is set to 'cloud' and 'Cloud Usage JDBC Hostname' is blank. So yes when following the cookbook, the primary and usage database have access with different username/password.
However the SQL Exception is caused when the 'Cloud Usage JDBC Hostname' is left blank and CPBM uses it's own IP address instead of the 'Cloud JDBC Hostname' value to connect to the Cloud Usage database.