Slackpkg Broken: 'gpg error'
I've been installing Slack 12.2 the last few days and so far everything has gone well. Until today.
I've been using slackpkg to apply updates to packages as well as install additional packages, usually from slackware-current.
Today I updated the glibc packages as well as a few others (what they were, I couldn't be 100% sure). slackpkg didn't seem to like this and start causing problems- specifically giving all kinds of 'gpg errors'. I then actually accidentally removed the glibc packages (which were upgraded to those in slackware-current) completely from the system. After about an hour or so of playing with it, reinstalling the glibc packages from Slack 12.2 as well as reinstalling a few other packages like findutils and pkgtools, everything seemed to be up and running again- except for slackpkg.
slackpkg continues to give me grief. Using 'slackpkg search' specifically almost ALWAYS returns "No package contains the selected pattern." If I look at my /var/lib/slackpkg/pkglist file, it only contains a handful (like 5) of packages that *are* part of slackware-current (which is what I have selected in /etc/slackpkg/mirrors), but some of which are NOT the actual packages installed on the system.
For example, pkglist has both pkgtools 12.34567890 and slackpkg 2.71.2 listed. But I only have pkgtools 12.1.0 and slackpkg 2.70.5 installed- as seen in pkgtool. I have completely removed and reinstalled (from the Slack 12.2 disc) slackpkg several times, each time making sure to remove any directories or files left behind (at /etc/slackpkg and /var/lib/slackpkg) after removing the package with removepkg.
I've tried setting mirrors to a 12.2 mirror and doing 'slackpkg update' there first and then changing it to slackware-current and doing slackpkg update again but to no avail. Somehow slackpkg seems to 'know' which packages were previously installed from slackware-current and only populates pkglist with those packages.
Again, when I try and do something like 'slackpkg search firefox', or even something that I know is already installed, like 'slackpkg search bash', I get: "No package contains the selected pattern."
If I try and search for one of the packages listed in the pkglist file, like 'slackpkg search slackpkg', it does return with: "[ upgrade ] - pkgtools-12.1.0-noarch-7 --> pkgtools-12.34567890-noarch-5"
But when I go to perform the upgrade with 'slackpkg upgrade pkgtools', I get something like this:
Does anyone have any suggestions? I've contemplated formatting and start installing from scratch again (I'm not *that* far along yet) but would really rather not if it can be avoided.
Any help would be greatly appreciated!
Rule of thumb: *do not* mix Slackware-12.2 and Slackware-current. Some -current packages will work with Slackware 12.2, others won't. And some packages you install from -current can make other packages from 12.2 unusable, so sooner or later you will mess up your system.
To (try to) go back to a clean Slackware 12.2 installation:
- make sure your slackpkg package is the one shipped with 12.2
- make sure the un-commented mirror in /etc/slackpkg/mirrors is for slackware-12.2
- run slackpkg update gpg then slackpkg update
- run slackpkg clean-system to remove all -current packages
- run slackpkg install-new to re install slackware-12.2 packages previously replaced by -current ones
To update to slackware-current from slackware 12.2 (credit Robby Workman on that):
1. Set your preferred slackware-current mirror by uncommenting the relevant line in /etc/slackpkg/mirrors.
2. Update package list: # slackpkg update
3. Install new packages: # slackpkg install-new
4. Upgrade all installed packages: # slackpkg upgrade-all
5. Run the above again (due to recent switch from TGZ to TXZ packages): # slackpkg upgrade-all
6. Remove unneeded packages: # slackpkg clean-system
7. Repeat steps 2, 3, 4 and 6 once or twice a week to ensure that you are always in sync with the "current" development.
And remember : once you run current, you won't be able to go back to 12.2, at least not easily.
If you have enough resource and want to play with -current whilst keeping -12.2 for production, install VirtualBox and run -current in a virtual machine.
Thanks for the quick response. Everything was going alright until I ran 'slackpkg clean-system'. I forgot to mention that I *did* do a clean-system earlier, which I suspect may have caused more damage than good.
Anyways, this is what I'm getting when I run clean-system:
Any thoughts where to go from here? Or am I destined to reinstall from scratch?
Yeah as Didier said, you've hosed things by mixing stable with -current :(
Looks like xargs that's giving you the trouble with slackpkg. You can try setting DIALOG=off in your slackpkg.conf.
That's what I was afraid of. I've looked high and low for a way out of this mess but nothing seems to work.
I took the plunge and reinstalled everything from scratch. This time I'll make a backup after I install it so if it happens again it isn't such a chore.
I figured that even if I hacked at it enough to make it 'work' that there could still be something else broken 'behind the scenes' that might creep up on me later on. I wasn't very far along in installing Slack when I screwed it up so I figured reinstalling at this point and ensuring things work is a lot better than getting everything setup and having it blow up on me 6 months down the road.
Thanks for the input though. If anyone else has this same issue and finds a solution for it, feel free to append it here.
You should write an article for DistroWatch.com to encourage people to mess their systems that way. :D
Sorry about the posting on an old thread but Ive been working on the same problem for a couple days. It was a pain to get fixed. Hear is the steps I used to fix the gpg error.
find you $/var/cache/packages/ and look for gnupg-1.4.9-i486-1
then go to $/root/.gnupg/ and look for the gpg.conf
edit $nano gpg.conf
uncommit the lines
save the file.
Then go to your slack repo and download a copy of gnupg2-2.0.9-i486-1
now you can run you $slackpkg update gpg
everything should go fine.
What i think happens and im not tottaly sure is that the gpg scripts have a lock on them. Once the lock it set for the settings and gpg It can not be changed.
Its what worked for me.
Well assuming you were getting the same error as the OP then what is happening is an error from xargs
The problem is usually caused by a glibc mismatch from mixing current packages with older versions.
|All times are GMT -5. The time now is 04:32 AM.|