Page 1 of 1

Access denied for user 'agnitas'@'localhost' (using password

Posted: Fri May 09, 2008 8:10 pm
by em4u
Please can someone help me. I am getting this message:

An error occurred
Cause: javax.servlet.ServletException: org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; Cannot create PoolableConnectionFactory (Access denied for user 'agnitas'@'localhost' (using password: YES)); nested exception is org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Access denied for user 'agnitas'@'localhost' (using password: YES))

Everything else appears to be working have I missed something in the installation manual.

Posted: Fri May 09, 2008 9:32 pm
by maschoff
OpenEMM can not access the database. Please try this:

Code: Select all

#mysql -u root -p
>GRANT DELETE, INSERT, UPDATE, LOCK TABLES, SELECT, ALTER, INDEX, CREATE TEMPORARY TABLES, DROP, CREATE ON openemm.* TO 'agnitas'@'localhost' IDENTIFIED BY 'openemm';
>FLUSH PRIVILEGES;
>quit
This creates user agnitas with the necessary permissions in case the user does not exist already. Does this work?

Posted: Sat May 10, 2008 12:47 am
by em4u
Thanks very much - it's certainly moved us on a big step. I am, now getting the error below: From my browser

An error occurred
Cause: javax.servlet.ServletException: org.springframework.jdbc.BadSqlGrammarException: Hibernate operation: could not execute query; bad SQL grammar [select emmlayout0_.layout_id as layout1_6_, emmlayout0_.company_id as company2_6_, emmlayout0_.header_url as header3_6_, emmlayout0_.footer_url as footer4_6_, emmlayout0_.base_url as base5_6_, emmlayout0_.normal_color as normal6_6_, emmlayout0_.highlight_color as highlight7_6_ from emm_layout_tbl emmlayout0_ where emmlayout0_.company_id=0 and emmlayout0_.layout_id=?]; nested exception is java.sql.SQLException: Table 'openemm.emm_layout_tbl' doesn't exist

Posted: Sat May 10, 2008 11:43 am
by maschoff
Seems to be that you have not created the database yet, because OpenEMM can not find table emm_layout_tbl. Therefore:

Code: Select all

# mysqladmin -u root -p create openemm
# mysql -u root -p openemm < openemm.sql

Posted: Sat May 10, 2008 10:21 pm
by em4u
Thank you very much for all you help. It worked and we are able to access our server remotely. We are now going to start to learn how to "drive" it. Really appreciate your quick response. :lol: :P :wink:

My solution

Posted: Sat Dec 19, 2009 7:02 pm
by churchill
You should create 2 databases and import corresponding sql script:
1. openemm_cms <-- openemm_cms.sql
2. openemm <-- openemm-6.X.sql

Hope it can help you!

Churchill