DX Unified Infrastructure Management

  • 1.  NMS5.0 on RHEL5 with MySQL

    Posted Dec 17, 2010 07:43 PM

    Hi guys,

     

    In preparation for a customer trial next week I am trying to get a test install going with a couple of RHEL5 virtual machines.  On one machine I have installed MySQL and it appears to be working.  From the second machine where I want to install NMS I am testing the database connection and have come up against a problem.

     

    I am able to telnet to the MySQL box ok on port 3306 so I know I am getting through to the service but when I run my NMS install I get the following error:

     

    ERROR 1045 (28000): Access Denied for user 'root'@'support-3c-vm36.nimsoft.no' (Using password = YES)

     

    I have checked the SQL server for permissions by doing a lookup on the USER table and verified the privileges are set to what I expect.  I have also verified the password for the root user and that is correct.

     

    I am by no means an expert on MySQL or even Linux so even though I have exhausted my avenues of solving this, there must be something really simple that I have not stumbled over yet.  Please do feel free to offer any hints or advice, no matter how basic or whacky.

     

    Thanks,

    Simon.



  • 2.  Re: NMS5.0 on RHEL5 with MySQL

    Posted Dec 17, 2010 09:16 PM

    Are the MYSQL permissions allowing remote connections or just localhost? Usually by default only localhost permissions are allowed. Here is a link related to MYSQL permissions Database Permissions



  • 3.  Re: NMS5.0 on RHEL5 with MySQL

    Posted Dec 20, 2010 11:51 AM

    Hi,

     

    Bryan is right. MySQL can allow/deny access to individual user logins from different machines. The error you are seeing says that user root is not allowed access from that machine (at the right side of the @ sign ).

     

    Also note: a user may have a different password for different IP's, so its a bit tricky.



  • 4.  Re: NMS5.0 on RHEL5 with MySQL

    Posted Dec 20, 2010 05:01 PM
    Hi guys,

    We have come up against the same error whilst installing on the customer site today. We are running NMS and MySQL on the same box and have made sure that 'root' on locahost is in the USER table. The current workaround is to startup the MySQL server with the option "--skip-grant-tables" which is a naughty workaround at best.

    Simon.


  • 5.  Re: NMS5.0 on RHEL5 with MySQL

    Posted Dec 21, 2010 11:59 AM

    Hi,

     

    The option you are describing is used for resetting the root user password on the mysql database.

     

    http://dev.mysql.com/doc/refman/5.0/en/resetting-permissions.html

     

    I do not recommend that you run with this setting. I think there is something wrong with the root users's granted permissions, where he can log in from and whether he needs a password.

     

    try this query for example,

     

    SELECT host,user,password FROM user where user = 'root';

     

    run it from the mysql system database. How many rows do you see? do you see one for localhost and one for % or for your hostname? The point is, that these two things are not the same:

     

    mysql -Uroot -p

    prompt for pwd...

    status;

    server will print out status, among other things,

     

    Current user:           root@localhost

     

    here I will be logging on localhost using the password for user + localhost row.

     

    If I type this;

     

    mysql -h vanlin01 -Uroot -p

     

    I will login to the machine vanlin01, even though that is the machine I am sitting on (localhost), mysql server looks at me as logging in from another machine.

     

    Current user:           root@vanlin01.nimsoft.no

    I am by no means mysql expert. I just remember having troubles setting up permissions to login as well as the permissions needed to create triggers. But I thought we had this documented now by the help from Pythian consultants. I have't seen the documentation myself.

     

    Typically, I needed to type query like this;

     

    GRANT SELECT ON *.* TO userxxx@hostyyy IDENTIFIED BY 'secret password' ;

     

    Or use the mysql administrator or mysql workbench to manage priviliges and grant tables.

     

     

    Geir.