ODBC 5.1 Driver connection fail

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Kurt Jakobsen
    New Member
    • Jun 2007
    • 38

    ODBC 5.1 Driver connection fail

    Hi,
    I have a MySql 5.0 database installed on a remote server.
    Until yesterday I have successfully communicated with it from other computers via ODBC 5.1 Driver.
    What happened yesterday was that an application stopped on a data verification check (application specific) and the application was left with the connection open waiting for me to click ok on a warning. Since I had left for the day, the connection was left until this morning.
    Then I found the dabase server crashed and I had to reinstall it to get it up and running again. And now it runs with aspx pages (so the ping test is passed ok). But I cannot get access from odbc from any of the computers.

    Any idea what I can do?
  • coolsti
    Contributor
    • Mar 2008
    • 310

    #2
    I am curious what platform you are working on.

    If my database server crashes, I certainly would not reinstall it again. I would just stop and restart the server service. Perhaps you have done something in your reinstall that changed a configuration.

    You may want to try to uninstall your ODBC 5.1 driver from the machine you are trying to connect from completely and reinstall it again. Or maybe try the older version and see if that works (3. something I think it is).

    Comment

    • Kurt Jakobsen
      New Member
      • Jun 2007
      • 38

      #3
      Hi,
      I am using xp. I've reinstalled the MySql server without that it seems to help. I've also run the myisamchk without it seem to help anything.
      The only thing that helped was to run mysqladmin shutdown and then mysqld --skip-grant-tables which leaves it completely open.
      The windows services does not manage to start nor stop the MySql service.

      Comment

      • coolsti
        Contributor
        • Mar 2008
        • 310

        #4
        I have only a little experience with Mysql on windows. Perhaps the proper way to shut down and restart the mysql in XP is with its own program, this mysqladmin. However, a complete reboot of the computer (if this is possible without interrupting other user activity) will do the trick to.

        Sounds like if you can only connect if you skip the grant tables that something is amiss with your mysql users setup and their grant permissions. You could see what the mysql user and password is for your ODBC connection, and if you can take a peek at the tables in the "mysql" database, you can maybe see if the combination of host, user and password seem correct (ok, you probably cannot compare the password directly in these tables as they are encrypted but you may be able to compare using the Password() function in Mysql). Then of course you need to see if the corresponding grants are correct. Remember, it is not a matter of the username in Mysql, but the combination of Username and Host that matters. If you have the correct mysql username but the host is not the same as the ODBC driver is saying it is, your connection would be refused.

        Comment

        Working...