There are 2 types of errors to fix:

DUPLICATE ENTRY

* user warning: Duplicate entry '1819798' for key 1 query: INSERT INTO accesslog (title, path, url, hostname, uid, sid, timer, timestamp) values('', 'node', 'http://sourdough.com/privatemsg/view/1357', '58.96.41.137', 0, '4c36586c7ee8a686aa4b0bebac5ce9aa', 3157, 1221214283) in /home/_user/public_html/includes/database.mysql.inc on line 172.

* user warning: Duplicate entry '1819798' for key 1 query: INSERT INTO accesslog (title, path, url, hostname, uid, sid, timer, timestamp) values('User account', 'user/login', 'http://sourdough.com/', '58.96.41.137', 56, 'ae9de2e6fb51d0f3110086fa5bb2be9c', 1583, 1221214340) in /home/_user/public_html/includes/database.mysql.inc on line 172.

AND WATCHDOG

* user warning: Table 'watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, severity, link, location, referer, hostname, timestamp) VALUES (56, 'user', 'Session opened for Wishstik.', 0, '', 'http://sourdough.com/user/login?destination=', 'http://sourdough.com/', '58.96.41.137', 1221214340) in /home/sourdoug/public_html/includes/database.mysql.inc on line 172.

* user warning: Table 'watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, severity, link, location, referer, hostname, timestamp) VALUES (74, 'content', 'bakery: updated Bakery Page.', 0, 'view', 'http://sourdough.com/node/1346/edit', 'http://sourdough.com/node/1346/edit', '58.96.41.137', 1221087009) in /home/_user/public_html/includes/database.mysql.inc on line 172.

This seems like a really simple job. It looks like you're just clearing out the watchdog/access tables? Feel free to give me a quote (through comments) and I'll give you the login details.

Comments

fax8’s picture

Just run the following queries:

DELETE FROM accesslog;

REPAIR TABLE watchdog;

Warning: the first query will delete everything you have in your accesslog.

------------
www.varesano.net - Fabio Varesano Personal Homepage

bib_boy’s picture

I had the same problem and went to the accesslog in phpmyadmin -> operations and then add one to the auto-increment value. Seemed to work ok.

maedi’s picture

Thanks bib_boy, I'll try that next time this error happens.

criznach’s picture

If the table is marked as crashed, then adding one doesn't really fix the problem. I'd still truncate it and repair it, or drop it and re-create a new empty table from a backup. The data in that table is not critical to the operation of your site. As the title implies, it contains a log of access to your nodes.