Results 1 to 5 of 5
  1. #1

    Corrupt database, how can I replace it?

    Think I had a bad sector on my drive:

    looks like the MYI for hydro_whos_online is corrupt?

    any clues how I can replace it?

    Many thanks.

    1016 Can't open file: 'hydro_whos_online.MYI' (errno: 145)
    in:
    [delete from hydro_whos_online where time_last_click < '1161431208']

    Seggie
    ~?&gt;#segFault...
    ------------------
    </div><table border=\'0\' align=\'center\' width=\'95%\' cellpadding=\'3\' cellspacing=\'1\'><tr><td>QUOTE </td></tr><tr><td id=\'QUOTE\'>segmentation fault - An error in which a running Unix program attempts to access memory not allocated to it and terminates with a segmentation violation error and usually a core dump.</td></tr></table><div class=\'signature\'>

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Corrupt database, how can I replace it?

    Try doing a repair on the database via phpMyAdmin ...

    If that does not work the table can be rebuilt with:
    PHP Code:
    DROP TABLE IF EXISTS whos_online;
    CREATE TABLE whos_online (
      
    customer_id int(11) default NULL,
      
    full_name varchar(64NOT NULL default '',
      
    session_id varchar(128NOT NULL default '',
      
    ip_address varchar(15NOT NULL default '',
      
    time_entry varchar(14NOT NULL default '',
      
    time_last_click varchar(14NOT NULL default '',
      
    last_page_url varchar(255NOT NULL default '',
      
    host_address text NOT NULL,
      
    user_agent varchar(255NOT NULL default '',
      
    KEY idx_ip_address_zen (ip_address),
      
    KEY idx_session_id_zen (session_id),
      
    KEY idx_customer_id_zen (customer_id),
      
    KEY idx_time_entry_zen (time_entry),
      
    KEY idx_time_last_click_zen (time_last_click),
      
    KEY idx_last_page_url_zen (last_page_url)
    TYPE=MyISAM
    NOTE: if using database prefixes you would need to alter the table name from:
    whos_online

    to be:
    yourprefix_whos_online

    in two places before running that in the SQL box ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3

    Idea or Suggestion Re: Corrupt database, how can I replace it?

    Thanks Ajeh, that worked great.

    Really appreciate your help sir,

    now I just need figure out how to upgrade to latest version ;)

    peace and thanks.

    Seggie
    ~?&gt;#segFault...
    ------------------
    </div><table border=\'0\' align=\'center\' width=\'95%\' cellpadding=\'3\' cellspacing=\'1\'><tr><td>QUOTE </td></tr><tr><td id=\'QUOTE\'>segmentation fault - An error in which a running Unix program attempts to access memory not allocated to it and terminates with a segmentation violation error and usually a core dump.</td></tr></table><div class=\'signature\'>

  4. #4
    Join Date
    Nov 2005
    Posts
    27
    Plugin Contributions
    0

    Default Re: Corrupt database, how can I replace it?

    Hi,
    I am posting here as maybe I have a like database problem. When going to the store front (it isn't live, though) I get the following: (also the admin areas seem to be working except the catalog section which throws a lot of info at me but I am weak on Greek :-) )

    -------
    1016 Can't open file: 'products.MYI'. (errno: 145)
    in:
    [select distinct m.manufacturers_id as id, m.manufacturers_name as name from products p, products_to_categories p2c, manufacturers m where p.products_status = 1 and p.manufacturers_id = m.manufacturers_id and p.products_id = p2c.products_id and p2c.categories_id = '0' order by m.manufacturers_name]
    ----------

    I have no knowledge of doing stuff in tables in mySql but if I know that this is most likely a database crash I can inquire of my server to take a look at that.

    Also, anyone recommend any book on learning how to do things to the database as suggested above in a step-by-step fashion from where you do this and how not to screw it up? :-)

    Thanks,
    Rand

  5. #5
    Join Date
    Nov 2005
    Posts
    27
    Plugin Contributions
    0

    Default Re: Corrupt database, how can I replace it?

    Hello, again.
    Just wanted to say it must have been a database crash, the server people 'rebuilt' or 'repaired' it and all seems okay now. I also inquired of them of any book about mySql and/or phpMyadmin panel that might help me do this stuff myself.
    Thanks,
    Rand

 

 

Similar Threads

  1. How can I replace this header?
    By mikeel100 in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 14 Jul 2013, 05:52 PM
  2. Database corrupt?? Site down!
    By gemohler in forum General Questions
    Replies: 7
    Last Post: 22 Nov 2010, 12:48 AM
  3. How can I replace the tagline text with an image?
    By rstevenson in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 7 Mar 2007, 04:59 PM

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