News:

We really need your input in this questionnaire

Main Menu

Not able to connect Database

Started by [email protected], December 08, 2009, 02:55:46 PM

Previous topic - Next topic

[email protected]

Hi,
     Iam getting the below error when iam restarting the nxdbr

[root@localhost ~]# /usr/local/bin/nxdbmgr init /usr/local/share/netxms/sql/dbinit_mysql.sql
NetXMS Database Manager Version 0.2.31

Configuration file OK
Unable to connect to database netxms@localhost as netxms

and this is my netxmsd.conf

[root@localhost ~]# cat /etc/netxmsd.conf
#
# Sample configuration file for NetXMS server
#

#
# DBDriver
#
# Database driver to use
#
# UNIX example:
  DBDriver = /usr/local/lib/libnxddr_mysql.so
#
# Windows example:
# DBDriver = mysql.ddr

#
# DBServer
#
# Database server (ODBC source name for ODBC driver)
#
# Example:
DBServer = localhost

#
# DBName
#
# Database name (not used by ODBC driver)
#
# Example:
DBName = netxms

#
# DBLogin
#
# Database user name
#
# Example:
DBLogin = netxms

#
# DBPassword
#
# Database user's password
#
# Example:
DBPassword = trx123

#
# LogFailedSQLQueries
#
# Controls logging of failed SQL queries.
# Possible values: "yes" (default) or "no".
#
# Example:
LogFailedSQLQueries = yes

#
# LogFile
#
# Server's log file. To write log to syslog (or Event Log on Windows),
# use {syslog} as file name.
#
# Examples:
LogFile = {syslog}
LogFile = /var/log/netxms

Can Some one please help me how to fix this

Thanks
Subbu

Victor Kirhenshtein

Hi!

Try to connect to database with MySQL command line client:

mysql -h localhost -u netxms -p netxms

and check error messages.

Best regards,
Victor

[email protected]

Hi ,
      I followed the Procedure instructe below Iam getting the below error , Please help me

root@localhost ~]# mysql -h localhost -u netxms -p netxms

Enter password:
ERROR 1045 (28000): Access denied for user 'netxms'@'localhost' (using password: YES)
[root@localhost ~]# mysql -h localhost -u netxms -p netxms
Enter password:
ERROR 1045 (28000): Access denied for user 'netxms'@'localhost' (using password: YES)
[root@localhost ~]#


Thanks in Advance

Subbu
[/quote]

Victor Kirhenshtein

Your database user netxms does not have access rights to database netxms. Try to grant required rights with the following MySQL query:


GRANT ALL ON netxms.* to netxms@localhost;


Best regards,
Victor

[email protected]

Thanks for the quick response..Its working now


Thanks
Subbu