LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   How to recover from "slackpkg remove" followed by "installpkg"? (http://www.linuxquestions.org/questions/slackware-14/how-to-recover-from-slackpkg-remove-followed-by-installpkg-804969/)

catkin 04-29-2010 08:35 AM

How to recover from "slackpkg remove" followed by "installpkg"?
 
Hello :)

Intending to remove jre-6u16-i586-1 and install jre-6u18-i586-1 on Slackware 13.0 32-bit, I used
Code:

slackpkg remove jre-6u16-i586-1
installpkg jre-6u18-i586-1.txz

This seems to have been the wrong way to do it because, now trying to remove jre-6u18-i586-1
Code:

removepkg jre-6u18-i586-1.txz

ls: cannot access /var/log/packages/jre-6u18-i586-1*: No such file or directory
No such package: /var/log/packages/jre-6u18-i586-1. Can't remove.

ls -l /var/log/packages/jre*
-rw-r--r-- 1 root root 35K 2010-03-09 20:28 /var/log/packages/jre-6u16-i586-1

What was wrong with what I did and how can I clean up?

Best

Charles

Richard Cranium 04-29-2010 08:44 AM

Install the old one again, then upgradepkg jre-6u18-i586-1.txz

sycamorex 04-29-2010 08:50 AM

...or you'd be able to remove it using pkgtool, wouldn't you?

catkin 04-29-2010 08:57 AM

Quote:

Originally Posted by Richard Cranium (Post 3951838)
Install the old one again, then upgradepkg jre-6u18-i586-1.txz

Thanks Mr Head :)

Does it matter which command I use to install jre-6u16-i586-1 again?

Am I right to think you are basing your advice on detailed knowledge of these jre-6u* packages, including knowing that jre-6u16-i586-1 and jre-6u18-i586-1 install the files with the same names?

I actually want to replace jre-6u18-i586-1 with jdk-6u16-i586-1, following our advice 20 hours ago: "Plus the JDK comes with a copy of the JRE; there's really no good reason to have both".

For future reference, do you know what was wrong with the way I removed jre-6u16-i586-1 and installed jre-6u18-i586-1?

Richard Cranium 04-29-2010 09:53 AM

I guess that I'm confused now.

I assumed that the removepkg error was generated by slackpkg. If you ran the slackpkg command first and then ran removepkg yourself, then the error makes sense: slackpkg removed it already so when you tried to do so, removepkg couldn't find it.

In any case, if you have the old package handy, an "installpkg /full/path/unless/it/is/in/./jre-6u16-i586-1.txz" followed by "upgradepkg jre-6u16-i586-1%jdk-6u16-i586-1.txz" (I'm a bit iffy on the upgradepkg syntax; you should check.) should do the trick.

catkin 04-29-2010 10:54 AM

Mystery solved! It turns out that a routine slackpkg update and slackpkg upgrade-all on 9mar10 removed jre-6u18-i586-1 and installed jre-6u16-i586-1. Here's the evidence:
Code:

c@CW8:~$ ls -l /var/log/removed_scripts/jre-6u18*
-rwxr-xr-x 1 root root 1406 2010-02-18 13:58 /var/log/removed_scripts/jre-6u18-i586-1-upgraded-2010-03-09,20:28:23
c@CW8:~$ ls -l /var/log/packages/jre-6u16*
-rw-r--r-- 1 root root 34969 2010-03-09 20:28 /var/log/packages/jre-6u16-i586-1

So I'm OK to simply remove jre-6u16-i586-1 and install jdk-6u16-i586-1. Phew!

Thanks for helping :)


All times are GMT -5. The time now is 01:38 PM.