portmaster -af fails due to dead port - HELP

Polytropon freebsd at edvax.de
Fri Jul 3 21:34:01 UTC 2015

On Fri, 03 Jul 2015 16:53:25 -0400, William F. Dudley Jr. wrote:
> Thanks to everybody for their help.
> I am now much further along in my upgrade, which was complicated by the 
> fact that
> this is a running server, and I didn't want to interrupt the users more 
> than a little
> bit, so "delete all the ports, install all the packages" was less than 
> ideal for me.

Couldn't you have a maintenance session in scheduled downtime
when you know the load is low (over night or at the weekend)?

Just a suggestion from my own experience: When I encounter the
need for a _massive_ upgrade, I usually do a new installation
on a separate system, disk, chroot environment or something
like that and prepare and _check_ everything, then migrate
the configuration. When "switch over" time has arrived, then
I replace the "whole system". Of course I schedule a downtime
for this (much fewer time than for the update work) and make
sure no users are logged in.

> (And this is just barely above "hobby level" stuff, so I don't have the 
> luxury of
> building up a new machine and cutting over to it after it's ready.  The 
> upgrade has
> to be done in place.)

A separate environment will do. If you don't use ZFS - no
problem. Building and installing can go to a different
path than /usr/local, so running software is not affected.
With chroot or jails it can be done.

> I have found that I can replace the old ports with packages a little bit 
> at a time,
> thus minimizing the outages.

This is also possible. Only when the build process has
been successful, the installed package will be removed.
Usually already _running_ programs aren't affected, but
maybe you encounter problems when a dynamically loaded
library (as a dependency) has been updated.

> The various bits of help with commands has been invaluable to me, and 
> though I might
> have eventually figured this all out on my own, your help has greatly 
> sped the process.

I'd like to mention that reading the "pkg primer" as
well as at least having a look at the available manpages
is very helpful, too. You don't have to remember the
content of all manpages, but know that they are there,
and which pages contain what information (in case you
need to look for something specific). EXAMPLES sections
are also worth reading.

> I may sound like I'm some kind of noob, but in reality I've been running 
> FreeBSD since very
> early on (pre-2000), but always as a "hobby", since being sysadmin 
> wasn't my day job.

No need for an excuse. Many things have been changed in
FreeBSD recently. The ports tree is "all different", a
new versioning tool has been introduced, the Makefiles
changed, "staging" of ports is there, pkg, ...

> So I've upgraded FreeBSD over many, many versions.  And historically, 
> upgrading the ports
> was always a giant pain in the neck.  Now, it seems, the binary package 
> management is finally
> working, and once I get all these legacy port builds out of the way, 
> upgrades should be
> much simpler in the future.

Definitely: with pkg this now works well for 99.9% of
the cases. Both the system and the ports now support
binary updating, and unless there is a good reason
why you want to build from source, it's probably the
way to go for most users.

Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

More information about the freebsd-questions mailing list