portupgrade -af before freebsd-update

Hi all,

In the handbook it states to run portupgrade -af before, and during the upgrade.

This process will remove old object files and libraries which will break most third party applications. It is recommended that all installed ports either be removed and re-installed or upgraded later using the ports-mgmt/portupgrade utility. Most users will want to run a test build using the following command:

# portupgrade -af

This will ensure everything will be re-installed correctly. Note that setting the BATCH environment variable to yes will answer yes to any prompts during this process, removing the need for manual intervention during the build process.

I was just curious to why this is mentioned, I actually started to run it earlier, and while all my apps are working, I did watch a few stop errors related to libtool2 roll by, nothing big.

Anyhow, I didnt set it all to yes, and after answering ok to some config screens for a couple hrs, then dozing off, I woke to a still unfinished portupgrade of all.

I just dont understand why this is even needed, if my apps are working now, and I upgrade to 8.0, wouldnt it be easier to use compat7, and/or just portupgrade the broken afterwards, I dont really see the point in upgrading apps just to break them again, and its also a bit hard to fix a stop error, when all the packages are forcefully being upgraded.

Honestly, Id almost be even more tempted to just pkg_deinstall -af or pkg_delete -af, and just wipe them clean and start fresh, rather then run portupgrade what calls for a total of 3* times during the upgrade.

I can understand more so to running it later in the install as mentioned, but then I also remembered that I dont run the nvidia-settings from ports, but rather one from nvidia, per their instructions, and I certainly dont want it upgraded.

Is there a real important reason for all of this, or is it just in there as a measure for describing how to update the entire system, and not just the OS version?

*Edit, sorry I misread, it only says to run portupgrade -af twice.
 
I asked this question before on mailing-list. But still confused a little bit.

If you "upgrade" 6 ==> 7 or 7 ==> 8, then you need "make deinstall portupgrade", "make install portupgrade" and then run "portupgrade -af".
I think that some ports need some lib that is included in userland, let us assume you run 6 and you want upgrade to 7, when you build a ports then the ports linked to a lib in 6's userland.
After you "upgrade" 6 ==> 7 this ports still assume it is linked to the lib in 6's userland.
Sometimes the lib's interface are same, but sometimes are not.
So you need rebuild everything, even the portupgrade program itself.
I remenber someone told me if I use portmaster instead of portupgrade then I can run "portmaster -af", because portmaster is a script not binary.

But you "update" from 7.2-p1 ==> 7.2-p2 this procedure is not required.

I can't be sure about this. :(

"update" vs "upgrade"
 
I've a lot of ports installed. So this may not apply...
Some version bumps, major, I had to hurriedly
rebuild piecemeal a whole lot of them to, say, use
a browser again.
_7 stable > _8 stable, however, 95 percent of
everything still worked. (I tend to use manual
reinstalls from a script, or use...)
Code:
portmaster -d category/port category/port category/port
 
fender0107401,

Youre right, I ended up just running freebsd-update after I had aborted the first run of portupgrade -af, and sure enough there were some lib's in userland that ended up missing, when I went to run portupgrade the second time, it complained, but running pkgdb -F and fixing them seemed to have solved it. I never manually deinstalled portupgrade, but it was definitely upgraded, while I was running portupgrade though.

Thank you for the information.

jb_fvwm2,

I kind of wondered if most would still run. I didnt get very far into the first portupgrade, before aborting, and there really wasnt a whole lot to fix.

Thank you too.


Just some random babble...I started portupgrade around 11:30 last night, it just now finshed at 9:30 tonight - 5 hours for sleeping when a config screen came up. I know people have spent longer building than that, but I was starting to wonder if it was ever going to finish, lol. Old P4 2.4 HT.

540 packages built, started out with 502, before the portupgrade.

Section in the manual talks about right of passage for new users building their own kernel, that was cake compared to this, and I only technically ran portupgrade once, would have been days. The actual freebsd-update by itself went quick though.

Edit: Was running a custom kernel during the update. btw. Had said I wasnt going to upgrade my 7.2, but I couldnt resist the fun.

Edit2: well, about half the applications I use, and the nvidia drivers arent/wasnt working, and Im pretty sure it isnt related to not running the first portupgrade, pkg_deinstall -af would have been a lot quicker.....and now my process count is back into the 100's. Bah. Kernel build might help

Edit3: Building a new custom kernel did drop everything back down, also performance does seem to be better on 8.0
 
Back
Top