java.net.ConnectException: Connection refused
Posted: Sun Oct 01, 2006 7:15 pm
Setup everything as per install doc (except sendmail stuff - see other posts)
Created a db user called openemm, and a database called openemm. Database creation worked except the last two statements which tried to grant privileges to "agnitas". I ignored these errors as the script didnt create the user, and there is no mention of it in the install instructions, so assumed it was a mistake. I dont want to (and cant - dont have root password) run the db under the root user.
When I hit my domain on port 8081, I get a nice error:
Ein Fehler ist aufgetreten
Ursache: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'Ruler' defined in ServletContext resource [/WEB-INF/cronContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.FatalBeanException: Could not instantiate class [org.agnitas.backend.RulerImpl]; constructor threw exception; nested exception is org.agnitas.util.ConfigException: Database setup failed: java.lang.Exception: Error initializing database connection: com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception: ** BEGIN NESTED EXCEPTION ** java.net.SocketException MESSAGE: java.net.ConnectException: Connection refused STACKTRACE: java.net.SocketException: java.net.ConnectException: Connection refused at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:156) at com.mysql.jdbc.MysqlIO.(MysqlIO.java:284) at com.mysql.jdbc.Connection.createNewIO(Connection.java:2555) at com.mysql.jdbc.Connection.(Connection.java:1485) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266) at java.sql.DriverManager.getConnection(DriverManager.java:525) at java.sql.DriverManager.getConnection(DriverManager.java:171) at org.agnitas.backend.DBase.(DBase.java:91) at org.agnitas.backend.Data.mkDBase(Data.java:295) at org.agnitas.backend.Data.setupDatabase(Data.java:305) at org.agnitas.backend.Data.(Data.java:1025) at org.agnitas.backend.RulerImpl.mkData(RulerImpl.java:95) at org.agnitas.backend.RulerImpl.(RulerImpl.java:106) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
:
stuff deleted
:
I hacked around a bit and found a file in WEB-INF/classes called emm.properties. I notice there is a user called agnitas with a password of openemm!
I created this user in plesk for the db openemm.
I then did:
mysql -u openemm -p openemm
(enered password)
and at the mysql> prompt tried:
GRANT DELETE, INSERT, UPDATE, LOCK TABLES, SELECT, CREATE TEMPORARY TABLES ON openemm.* TO 'agnitas'@'localhost' IDENTIFIED BY 'openemm';
But get:
ERROR 1044 (42000): Access denied for user 'openemm'@'%' to database 'openemm'
I tried stopping and starting OpemEMM with the new user defined for the DB, but get the same "Ein Fehler ist aufgetreten..." when I hit the url.
Created a db user called openemm, and a database called openemm. Database creation worked except the last two statements which tried to grant privileges to "agnitas". I ignored these errors as the script didnt create the user, and there is no mention of it in the install instructions, so assumed it was a mistake. I dont want to (and cant - dont have root password) run the db under the root user.
When I hit my domain on port 8081, I get a nice error:
Ein Fehler ist aufgetreten
Ursache: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'Ruler' defined in ServletContext resource [/WEB-INF/cronContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.FatalBeanException: Could not instantiate class [org.agnitas.backend.RulerImpl]; constructor threw exception; nested exception is org.agnitas.util.ConfigException: Database setup failed: java.lang.Exception: Error initializing database connection: com.mysql.jdbc.CommunicationsException: Communications link failure due to underlying exception: ** BEGIN NESTED EXCEPTION ** java.net.SocketException MESSAGE: java.net.ConnectException: Connection refused STACKTRACE: java.net.SocketException: java.net.ConnectException: Connection refused at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:156) at com.mysql.jdbc.MysqlIO.(MysqlIO.java:284) at com.mysql.jdbc.Connection.createNewIO(Connection.java:2555) at com.mysql.jdbc.Connection.(Connection.java:1485) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266) at java.sql.DriverManager.getConnection(DriverManager.java:525) at java.sql.DriverManager.getConnection(DriverManager.java:171) at org.agnitas.backend.DBase.(DBase.java:91) at org.agnitas.backend.Data.mkDBase(Data.java:295) at org.agnitas.backend.Data.setupDatabase(Data.java:305) at org.agnitas.backend.Data.(Data.java:1025) at org.agnitas.backend.RulerImpl.mkData(RulerImpl.java:95) at org.agnitas.backend.RulerImpl.(RulerImpl.java:106) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
:
stuff deleted
:
I hacked around a bit and found a file in WEB-INF/classes called emm.properties. I notice there is a user called agnitas with a password of openemm!
I created this user in plesk for the db openemm.
I then did:
mysql -u openemm -p openemm
(enered password)
and at the mysql> prompt tried:
GRANT DELETE, INSERT, UPDATE, LOCK TABLES, SELECT, CREATE TEMPORARY TABLES ON openemm.* TO 'agnitas'@'localhost' IDENTIFIED BY 'openemm';
But get:
ERROR 1044 (42000): Access denied for user 'openemm'@'%' to database 'openemm'
I tried stopping and starting OpemEMM with the new user defined for the DB, but get the same "Ein Fehler ist aufgetreten..." when I hit the url.