LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Red Hat (https://www.linuxquestions.org/questions/red-hat-31/)
-   -   System hangs when using "rpm" command (https://www.linuxquestions.org/questions/red-hat-31/system-hangs-when-using-rpm-command-88447/)

doncrawley 09-02-2003 11:44 AM

System hangs when using "rpm" command
 
My RedHat 9 system hangs when using most "rpm" commands. I first noticed it when attempting to install VNC, but it seems to hang when using any rpm command. I've tried using the command "rpm --rebuilddb", but it hangs then, too.

DrOzz 09-02-2003 11:50 AM

type:
rm -rf /var/lib/rpm/__db*
rpm -vv --rebuilddb

that should help ya...

doncrawley 09-02-2003 11:56 AM

Thanks for the tip. When I tried it, it hung after this message:
D: opening db index /var/lib/rpm/Packages rdonly mode=0x0

DrOzz 09-02-2003 12:01 PM

Quote:

Originally posted by kilgen54
rdonly mode=0x0 [/B]
i noticed this part, so is it safe to say you tried this as a normal user?? if so you have to be root..

doncrawley 09-02-2003 12:09 PM

No, I ran it as root. I did, however, figure out what the problem was. When I attempted to delete the db files from /var/lib/RPM/Packages, I didn't use a double underscore in the file name. Once I corrected that, your solution worked. Thanks for your help.

jhibbets 09-03-2003 01:34 AM

This problem should have been fixed in RHL9 (make sure your up2date on your rpm version), however, another common pitfall I see is that people download rpm files with Internet Exploder (spelling is correct) and the browser with insert a "[1]" (or similar) into the filename.

Here is an example:
file name: kernel-smp-2.4.20-20.9.i586.rpm
IE downloaded name: kernel-smp-2.4.20-20.9.[1]i586.rpm


Solution:
rename the file with mv:
mv kernel-smp-2.4.20-20.9.[1]i586.rpm kernel-smp-2.4.20-20.9.i586.rpm

Then install the rpm.... rpm -ivh kernel-smp-2.4.20-20.9.i586.rpm.

Just wanted to bring this common pitfall out, it's hard to notice sometimes.


All times are GMT -5. The time now is 07:45 PM.