Hello, I'm getting this error when I run the update.php:

PDOException: SQLSTATE[HY000]: General error: 11 database disk image is malformed: DELETE FROM {cache_page} ; Array ( ) at cache_clear_all() (line 176 de /home/user/domain.com/includes/cache.inc).

Everything works fine but I can't disable caching or clear cache. The problem was caused when updating modules.

Any idea about how to fix the database?

Comments

dpovshed’s picture

Hi Jorge!

Can you please try to open database by any convenient tool and execute command

DELETE FROM cache_page;

via the tool? Will you get the same error? Of course better to turn off your webserver first to prevent any collision.

If it works I think it might have sense to repeat DELETE for all tables started with cache_ and then perform VACUUM command.

A simplest SQL lite tool can be added as an extension to Firefox - it is good enough to do so.

Good luck, let us know the results.

Jorge Navarro’s picture

Hi Dennis!!

I have tried to open the database and I'm getting this error from the tool:

SQLiteManager: Error in opening file .ht.sqlite - either the file is encrypted or corrupt
Exception Name: NS_ERROR_FILE_CORRUPTED
Exception Message: Component returned failure code: 0x8052000b (NS_ERROR_FILE_CORRUPTED) [mozIStorageService.openUnsharedDatabase]

There is another way to open the database?

dpovshed’s picture

Hey Jorge,

thanks for posting this! Surely there is a lot of ways to open database (unless it is badly corrupted)

So next thing I suggest is to find a tool which can open your DB - I believe the one downloaded from main SQLite site could be a best option. I do not know what OS you're using, but I hope you can find appropriate version here
http://www.sqlite.org/download.html

These hints, for example, might be useful:
http://community.spiceworks.com/how_to/show/1468

Idea is to open the DB and perform integrity check, and then to clear all caches.
Also I recommend not to open your file directly in its location - .ht.sqlite but to make a copy first. You never know, where repair may lead you to.

Please let me know - is this approach work for you?

dpovshed’s picture

Status: Active » Closed (fixed)

Six weeks of silence - I assume this is not actual anymore, so closing.

Jorge Navarro’s picture

Finally I have fixed the problem using phpliteadmin (http://code.google.com/p/phpliteadmin/) dropping the table cache_page and creating a newone with the same fields.

Thank's!!

dpovshed’s picture

Thank you Jorge for sharing final solution here on drupal.org!

Good chance this thread might be useful to someone else with similar case.

Cheers!