Updating system

In which order should one update/upgrading the FreeBSD components [freebsd (components, world and kernel), pkg, ports] to preserve the integrity of the system?
 
If upgrading from source and using manually built ports (I use poudriere), I usually make sure ports are upgraded and built, then build world+kernel then install kernel then world (as /usr/src/UPDATING and other documentation suggests), rebuild incompatible ports such as for kernel modules, then I rebuild the newer version of the ports from the same ports tree without updating the tree any further yet, then if successful it is safe to do the final `cd /usr/src;make delete-old-libs` for final cleanup.
Many older FreeBSD version ports can continue to run before their rebuild to the newer version is installed. By not updating the tree I find I can normally rebuild ports such as 3rd party kernel modules and install them without it causing many other things to be removed during the `pkg upgrade` step though I don't know if/when it 'should' work that way. This leaves me with a working system while I wait for poudriere to rebuild my usually tracked ports (on the same machine) which often takes days to build.
In my experience it is always best to just do a full rebuild of all installed packages instead of such partial steps as pkg has left me with library mismatches over some upgrades now and other upgrades later when not all of a dependency tree built properly the first time. Pkg said everything was fine but the errors went away when forcing reinstall of packages and their dependencies so obviously something wasn't. This has not yet hit me when doing smaller changes like just kernel modules and when keeping the ports tree at the same version as it was last successfully built from for the older FreeBSD version.
I haven't performed a poudriere run on the FreeBSD version that is newer than the host before the host is upgraded as poudriere warned against it. I presume users either do that anyways, do a run in a virtual machine with already updated guest, or (like me) tolerate downtime while waiting on builds after upgrading the host.
 
… then build world+kernel then install kernel then world (as /usr/src/UPDATING and other documentation suggests), rebuild incompatible ports such as for kernel modules, then I rebuild the newer version of the ports from the same ports tree without updating the tree any further yet, then if successful it is safe to do the final `cd /usr/src;make delete-old-libs` …

Omitting `make delete-old`?
 
I omitted a 'lot' of my routine steps, though UPDATING covers make-delete-old, etcupdate, and others. I need to get back to that email where someone asked about upgrading from 8-stable to something modern which will have all sorts of fun steps beyond my routine but haven't had access to the machine i did some testing for it.
 
Back
Top