database disk image is malformed
ryandesign at macports.org
Fri Mar 27 22:30:50 UTC 2020
On Mar 27, 2020, at 17:07, Gael Arnaud wrote:
> Am facing an error with the following message each time I try to install a new port
> Error: rev-upgrade failed: sqlite error: database disk image is malformed (11) while executing query: SELECT id, path FROM registry.files WHERE active = '1' AND binary IS NULL
> Error: Follow https://guide.macports.org/#project.tickets to report a bug.
> I Guess, I need to uninstall and reinstall macport, but before doing such a drastic step, I wanted to be sure there were no other ways to avoid this long and fastidious process..
There have been a few previous reports of this, and yes, in those cases, uninstalling and reinstalling was necessary, since there isn't a known way to uncorrupt a corrupted database. You could wait and see if somebody else has a better suggestion but I'm not sure there is one.
SQLite is very old and well-tested software. On good hardware it should not corrupt databases, so the corruption could indicate a hardware problem, such as with your disk or memory. Or, if you are running in a virtual machine and the VM crashed or was turned off unexpectedly, it could indicate that the VM does not properly guarantee that writes to the virtual disk are propagated to the physical disk immediately.
More information about the macports-users