[talk] Why am I no longer able to install FreeBSD packages?

James E Keenan jkeenan at pobox.com
Tue Apr 10 13:55:20 EDT 2018


On 04/10/2018 10:57 AM, Shawn Webb wrote:
> On Tue, Apr 10, 2018 at 09:27:10AM -0400, James E Keenan wrote:
>> Background:
>>
>> Since October 2016 I have run FreeBSD-11.0 in a VMWare VM (currently, VMWare
>> Workstation 14 Player).  Broadly speaking, I've used this almost entirely
>> for QA purposes for Perl 5.  I've gotten comfortable installing packages,
>> mainly via 'pkg' but sometimes via 'make install' in the ports tree.  And
>> since Brian Callahan's talk at NYCBUG in January I've had ports accepted in
>> both FreeBSD and OpenBSD.*
>>
>> But in the last week, whenever I try to use 'pkg' to install libraries on
>> FreeBSD, I am likely to get a message like this:
>>
>> #####
>> $ sudo pkg install shared-mime-info
>> Updating FreeBSD repository catalogue...
>> Fetching meta.txz: 100%   944 B   0.9kB/s    00:01
>> Fetching packagesite.txz:  100%    6 MiB   3.2MB/s    00:02
>> Processing entries:   0%
>> pkg: Newer FreeBSD version for package libxfce4util:
>> - package: 1101001
>> - running kernel: 1100122
>> pkg: repository FreeBSD contains packages for wrong OS version:
>> FreeBSD:11:amd64
>> Processing entries: 100%
>> Unable to update repository FreeBSD
>> Error updating repositories!
>> #####
>>
>> Now, I have the feeling that this is related to the age of my version of
>> FreeBSD.**  I have spent hours doing internet searches on these message,
>> have called 'pkg clear -a' repeatedly as per the results of those searches
>> yet still experienced this problem.  But I confess I do not understand
>> FreeBSD's release cycle at all.  So here are my questions:
>>
>> Questions:
>>
>> * What exactly is "wrong" about my OS?
>>
>> * Did that "wrong" status come into being on some specific date (e.g., April
>> 1)?
>>
>> * What configuration files on my system do I need to examine to get data on
>> this situation?
>>
>> * Can I change those configuration files to say, in effect, "Don't worry
>> about 11.1 ports; continue to direct me to 11.0 ports"?
>>
>> * If not, is my FreeBSD-11.0 installation now basically hopeless when it
>> comes to installing packages?
>>
>> * If that is the case, can I upgrade to 11.1 within the VM -- and what risks
>> would that entail?
> 
> Hey Jim,
> 
> We've been hit with this pretty hard in HardenedBSD. FreeBSD
> introduced a new feature in pkg(8) that places a guard when your
> system's KBI is older than the KBI of the package build. FreeBSD now
> wants to enforce updating the base OS prior to updating installed
> packages.
> 
> `uname -K` will tell you what version the kernel is at.
> 
> So, these are the steps you'll need to take to update:
> 
> 1. Update base (either via src compile or freebsd-update, whichever
>     you prefer)
> 2. reboot
> 3. pkg clean -y
> 4. pkg update -f
> 5. pkg upgrade
> 

Wow! Watching 'pkg upgrade' do its thing is truly impressive.  (Not 
least of which is watching my own ports getting installed!)

Thanks.
jimk



More information about the talk mailing list