nxdbmgr not working with mysql
-
Hello
Initializing mysql DB with nxdbmgr is showing this message:
/ # /opt/bin/nxdbmgr init /opt/share/netxms/sql/dbinit_mysql.sql
NetXMS Database Manager Version 0.2.31Configuration file OK
Unable to connect to database netxms@localhost as netxmsThe following was the configuration in mysql:
/tmp/netxms-0.2.31/contrib # mysql -U mysql -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2323475
Server version: 5.1.25-rc-standard-log Source distributionType 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> CREATE DATABASE netxms;
Query OK, 1 row affected (0.00 sec)mysql> GRANT ALL ON netxms.* TO netxms IDENTIFIED BY 'PaSsWd';
Query OK, 0 rows affected (0.01 sec)mysql> \q
ByeConfiguration in netxmsd.conf:
DBDriver = /opt/lib/libnxddr_mysql.so
#
# DBServer
#
DBServer = localhost
#
# DBName
DBName = netxms
#
# DBLogin
#
DBLogin = netxms
#
# DBPassword
#
DBPassword = PaSsWdMay be the initialization script is complaining because password in command line is not allowed in mysql configuration?
-
Hi!
If you are connecting to localhost, you should grabt access to database in this way:
GRANT ALL ON netxms.* TO netxms@localhost IDENTIFIED BY 'PaSsWd';
Because MySQL threats localhost connections differently. (MySQL page where this behavior is explained: http://dev.mysql.com/doc/refman/5.1/en/adding-users.html).
Best regards,
Victor -
Thank you Victor
You are right, now is working fine:
/ # /opt/bin/nxdbmgr check
NetXMS Database Manager Version 0.2.31Configuration file OK
Checking database:
* Checking node objects... [PASSED]
* Checking interface objects... [PASSED]
* Checking network service objects... [PASSED]
* Checking cluster objects... [PASSED]
* Checking template to node mapping... [PASSED]
* Checking object properties... [PASSED]
* Checking event processing policy... [PASSED]
* Checking collected data... [PASSED]
Database doesn't contain any errors
Database check completed
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login