[Slapt-get-user] Fw: Adventures with slapt-get

Mamading Ceesay slapt-get-user@software.jaos.org
Thu, 18 Dec 2003 06:31:19 +0000


The following documents an issue I experienced with slapt-get.  It is not necessarily slapt-get's fault.  However, I had read the FAQ 2-3 times before actually running slapt-get.  If there had been an appropriate entry in the FAQ, I would not have been bit by this.  So please write this up when you have the chance 

Begin forwarded message:

Date: Thu, 18 Dec 2003 05:43:08 +0000
From: Mamading Ceesay <linux@evangineer.force9.co.uk>
To: General Slackware usage <slackware@kurtwerks.com>
Subject: Adventures with slapt-get


On Mon, 24 Nov 2003 16:52:29 +0000
Mamading Ceesay <linux@evangineer.force9.co.uk> wrote:

> 
> I've been thinking about giving slapt-get a whirl on a development box.
> 

I've had a play with it and ran into a nasty little gotcha, which fortunately I have worked out a solution for.

I did the following to get patches on a 9.0 box:

	sudo /sbin/slapt-get --update
	sudo /sbin/slapt-get --upgrade

Actually, I was a bit of a coward and did:

	sudo /sbin/slapt-get --simulate --upgrade 

before doing the real thing.  Despite everything looking good at the dry-run stage, a problem occurred during the run.  slapt-get uses the pkgtools to do the actual package management, it just supplies some extra smarts.  So it was calling upgradepkg, which in turn calls installpkg and removepkg.  upgradepkg complained about not being able to find these programs, which is understandable because I don't have /sbin on my path.  When running admin commands using sudo, I always use absolute paths.  Unfortunately slapt-get didn't pick this up and I have a bunch of packages in /var/log/packages with names like:

samba-2.2.8-i386-1-upgraded-2003-12-18\,03\:22\:42

As far as slapt-get is concerned the packages have been upgraded, but when I checked the actual versions myself, that was clearly not the case.  No amount of playing with slapt-get would fix this, even running "slapt-get --clean" and then slapt-get --upgrade or slapt-get --reinstall pkgname.

The only solution is to rename the affected files in /var/log/packages
stripping out the -upgraded-etc bit and re-running "slapt-get --upgrade"
as root.

So going forward, I need to either add /sbin to my path, if I want to run slapt-get using sudo or I shall have login as root to run it and I rarely login as root if I can avoid it.  This is of course presuming that I continue to run it manually. 

-- 
Mamading Ceesay - SCO delenda est!
Essential reading for all computer users: 
http://www.cl.cam.ac.uk/%7Erja14/tcpa-faq.htm
http://www.fipr.org/intellectual.html


-- 
Mamading Ceesay - SCO delenda est!
Essential reading for all computer users: 
http://www.cl.cam.ac.uk/%7Erja14/tcpa-faq.htm
http://www.fipr.org/intellectual.html