Wednesday, April 04, 2007

I uninstalled sqlite on my Linux box !!!

Well I somehow felt I could yum erase sqlite since I do not need it. Well I did not see the dependencies that would be removed too! The result:

yum, rpm, php, httpd, rpm-python and many related packages all Erased !!! OMG I said. :P

I am not very friendly with Linux as yet at this level. I knew I had screwed all hopes of getting that box in clean shape. I searched the net for "reinstll RPM", "install RPM" and similar. Got a link to How to reinstall rpm

In case you can not reach to it, it says something like:

I guess you could try :
- Copying the "rpm2cpio" binary from another machine
- Copying the rpm package locally
- Running something like :
cd /
rpm2cpio /path/to/rpm-4.*.rpm | cpio -dimv

Then you could clean up what you just did (in case it's a different version of rpm, mainly) :
rpm -e --justdb --nodeps rpm
rpm -Uvh /path/to/rpm-4.*.rpm


That gave me some hope. I followed the instructions. Switched to root user, went to / and executed rpm2cpio with the downloaded rpm of RPM itself. RPM

Then got an error about librpm shared lib missing. So downloaded librpm. Now rpm works!!!

Now I just searched for the latest versions of rpms for getting yum up and running. This included sqlite, python-sqlite, rpm-python, yum-metadata-parser, urlgrabber, etc. And finally installed yum !!!

I mainly used for searching rpms

Well thats it: I am almost saved :D

No comments:

Post a Comment