Damaged database?
Adam Dershowitz
dersh at alum.mit.edu
Sat Feb 23 08:49:08 PST 2013
On Feb 23, 2013, at 1:09 AM, Ryan Schmidt wrote:
> On Feb 23, 2013, at 01:23, Adam Dershowitz wrote:
>
>> I just tried to restore my full /opt/local directory using timemachine from about two weeks ago. If I then do a sync and try to upgrade gst-plugins-base, the same thing happens. It first successfully upgrades a bunch of different things. Finally, it gets to gst-plugins-base and gives the same error. I also restored from about a month ago, and get the identical results. I have done many upgrades during that time period. So, it seems that there is something wrong in the sqlite database that just relates to gst-plugins-base. And that it has been there for a while.
>> Short of doing a full reinstall of all my ports, any other thoughts about how to repair that single entry? I would think that all I really want to do is to delete the appropriate entries from the database and to do a corresponding forced uninstall of gst-plugins-base. But, I am not sure how to get that to work.
>> Any suggestions?
>
> I'm not sure what's going on... if you want to try forcibly uninstalling gst-plugins-base the way to do so would be:
>
> sudo port -f uninstall gst-plugins-base
>
>
I guess I wasn't clear. The problem is that the upgrade was trying to do that, and it was failing. And trying it explicitly also makes it fail:
$ sudo port -f uninstall gst-plugins-base
---> Unable to uninstall gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Uninstall forced. Proceeding despite dependencies.
---> Deactivating gst-plugins-base @0.10.36_2+universal
---> Unable to deactivate gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Deactivate forced. Proceeding despite dependencies.
Error: org.macports.deactivate for port gst-plugins-base returned: sqlite error: database disk image is malformed (11) while executing query: SELECT actual_path FROM registry.files WHERE id=? AND active ORDER BY actual_path
Please see the log file for port gst-plugins-base for details:
/opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_gst-plugins-base_0.10.36_2+universal/gst-plugins-base/main.log
Warning: Failed to execute portfile from registry for gst-plugins-base @0.10.36_2+universal
---> Deactivating gst-plugins-base @0.10.36_2+universal
---> Unable to deactivate gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Deactivate forced. Proceeding despite dependencies.
Error: org.macports.uninstall for port gst-plugins-base returned: sqlite error: database disk image is malformed (11) while executing query: SELECT actual_path FROM registry.files WHERE id=? AND active ORDER BY actual_path
Warning: Failed to execute portfile from registry for gst-plugins-base @0.10.36_2+universal
---> Unable to uninstall gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Uninstall forced. Proceeding despite dependencies.
---> Deactivating gst-plugins-base @0.10.36_2+universal
---> Unable to deactivate gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Deactivate forced. Proceeding despite dependencies.
Error: org.macports.deactivate for port gst-plugins-base returned: sqlite error: database disk image is malformed (11) while executing query: SELECT actual_path FROM registry.files WHERE id=? AND active ORDER BY actual_path
Please see the log file for port gst-plugins-base for details:
/opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_gst-plugins-base_0.10.36_2+universal/gst-plugins-base/main.log
Warning: Failed to execute portfile from registry for gst-plugins-base @0.10.36_2+universal
---> Deactivating gst-plugins-base @0.10.36_2+universal
---> Unable to deactivate gst-plugins-base @0.10.36_2+universal, the following ports depend on it:
---> webkit-gtk @1.10.2_0+video
---> wine-devel @1.5.21_0
Warning: Deactivate forced. Proceeding despite dependencies.
Error: port uninstall failed: sqlite error: database disk image is malformed (11) while executing query: SELECT actual_path FROM registry.files WHERE id=? AND active ORDER BY actual_path
But, if I just choose some other random port to force uninstall it works fine. So, it seems that there is something wrong with just some database entry for gst-plugins-base. And the problem has been in my database for at least a month. But it is not causing any other problems, that I can see, other then just not being able to upgrade that one port.
--Adam
More information about the macports-users
mailing list