Results 1 to 7 of 7
  1. #1
    Join Date
    Jan 2009
    Posts
    119
    Plugin Contributions
    0

    Default Db_error_not_connected

    Hi,

    I'm getting an error when trying to access either the webshop or the admin section.

    shop front error = Sorry!
    There seems to be a problem connecting to our database. Please give us a few minutes to remedy the problem. Thank you.


    admin error = 0 DB_ERROR_NOT_CONNECTED
    in:
    [select * from zen_project_version WHERE project_version_key = 'Zen-Cart Database' ]
    If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

    i think is this is causing the problem. I went into phpmyadmin and tried to optimise the database (selected all the tables and then selected optimise).

    Unfortunately then I had a power failure and had to leave everything the way it was. I logged onto cpanel from another computer but cannot access phpmyadmin now... and then noticed the connection errors.

    So where do i go from here? I'm assuming that i overloaded things by selecting all the tables and this has messed things up.

    And to make things worse i dont have a backup of my database....

    The second thing i did today... change the includes/configure.php file SQL_CACHE_METHOD from "none" to "file". I copied/changed the file extension of the original one and modified the copy. The original file has been restored (changed the extension back)

    Thanks for any help/ suggestions

    Iddy

  2. #2
    Join Date
    Jan 2009
    Posts
    119
    Plugin Contributions
    0

    Default Re: Db_error_not_connected

    I found the tutorial on this error thanks to the similar thread suggestion below. Dont know what i was doing when i searched earlier.

  3. #3
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Db_error_not_connected

    So problem is solved?

  4. #4
    Join Date
    Jan 2009
    Posts
    119
    Plugin Contributions
    0

    Default Re: Db_error_not_connected

    no still not solved. I'm currently running through repairing the db but it kinda looks like phpmyAdmin is spinning its wheels but getting no where with it so i'll open a support ticket with my hosting company to see if they can help.

  5. #5
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Db_error_not_connected

    Quote Originally Posted by iddy View Post
    no still not solved. I'm currently running through repairing the db but it kinda looks like phpmyAdmin is spinning its wheels but getting no where with it so i'll open a support ticket with my hosting company to see if they can help.
    Good idea. I have a feeling that this will be your only solution,

    Quote Originally Posted by iddy View Post
    I'm getting an error when trying to access either the webshop or the admin section.

    shop front error = Sorry!
    There seems to be a problem connecting to our database. Please give us a few minutes to remedy the problem. Thank you.

    admin error = 0 DB_ERROR_NOT_CONNECTED
    Assuming that no one had messed with your config files (in particular, the DB logon details) this is almost certaintly a server error, and there would be nothing that you could do to fix it. It would be a job for your host.

    Quote Originally Posted by iddy View Post
    [select * from zen_project_version WHERE project_version_key = 'Zen-Cart Database' ]
    If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

    i think is this is causing the problem.
    Not so. That would be just a symptom, not the cause.

    Quote Originally Posted by iddy View Post
    I went into phpmyadmin and tried to optimise the database (selected all the tables and then selected optimise).
    On the other hand, if you could connect to the DB with phpmyadmin, then the server itself is/was actually functional *at that time*.

    Quote Originally Posted by iddy View Post
    Unfortunately then I had a power failure and had to leave everything the way it was.
    A power failure on your local host will have no effect on what the server was doing at the time. It would have continued its task without even a hiccup. <sp>

    Quote Originally Posted by iddy View Post
    I logged onto cpanel from another computer but cannot access phpmyadmin now... and then noticed the connection errors.
    I'm a little confused, I thought your conenction errors started before you optimised the DB and had the power failure.
    Were these the same errors, or different?

    Quote Originally Posted by iddy View Post
    So where do i go from here?
    Enlist the aid of your host.

    Quote Originally Posted by iddy View Post
    I'm assuming that i overloaded things by selecting all the tables and this has messed things up.
    Very unlikely.

    Quote Originally Posted by iddy View Post
    And to make things worse i dont have a backup of my database....
    Rule#1 of computing. Back up everything. Often.
    Rule#2. Make sure you know how to restore using the backups.

    Quote Originally Posted by iddy View Post
    The second thing i did today... change the includes/configure.php file SQL_CACHE_METHOD from "none" to "file". I copied/changed the file extension of the original one and modified the copy.
    Are you sure this wasn't the 1st thig you did? (just asking). The thing is, if you mess up this file, then PHP will have a problem parsing it, with means that it woudn't have been able to read the DB login details, which will produce the exact error that you 1st reported ( 0 DB_ERROR_NOT_CONNECTED)

    Quote Originally Posted by iddy View Post
    The original file has been restored (changed the extension back)

    Thanks for any help/ suggestions

    Iddy
    There are only two possible causes for this error. Your configure files were changed (and something got broke as a result), or the SQL server itself had a serious failure.

    Work with your host so that you can first get phpmyadmin working again, and if you still have problems with zencart (re)check your zencart configuration files.

    The idea of getting phpmyadmin working first is because this is something that only your host can fix. Also, there is nothing that *you* can do to cuase it to fail in the 1st place... IOW, you are taking yourself out of the equation.
    When phpmyadmin is functional you can be pretty confident that the SQL server itself is also fully functional, which is when you'll need to come back to the zencart issues (assuming they aren't fixed at the same time).

    Cheers
    Rod

  6. #6
    Join Date
    Jan 2009
    Posts
    119
    Plugin Contributions
    0

    Default Re: Db_error_not_connected

    Thanks for the detailed reply Rod. My Hosting company sorted it for me. I had exceeded the mysql connection limits. They cleared it and everything works again..

  7. #7
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Db_error_not_connected

    Quote Originally Posted by iddy View Post
    Thanks for the detailed reply Rod. My Hosting company sorted it for me. I had exceeded the mysql connection limits. They cleared it and everything works again..
    I don't now if I should tell you this or not, but your hosting company is telling you porkies.

    Yes, it is true that MySQL has a defined limit on the number of connections it can handle, but this is a *global* option that pertains to *all* users of the database server, not just you or any other specific user.

    http://dev.mysql.com/doc/refman/5.5/...nnections.html

    I can't imagine why they would be trying to place the cause on you (or ZenCart) when the problem was caused by a limitation or problem with their server.

    Cheers
    Rod

 

 

Similar Threads

  1. 0 db_error_not_connected
    By SPembleton in forum General Questions
    Replies: 1
    Last Post: 1 Sep 2011, 11:23 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR