# portupgrade analog



## bagas (Aug 7, 2021)

Hello.
I thought, what is the best way to update the software on the server at the moment.
See what's new in /usr/ports/UPDATE.
Now I'm updating like this portupgrade -arR
My system FreeBSD 12.2-13.0.


----------



## chrcol (Aug 9, 2021)

Here is what I did when going from 11 to 12.

reinstall ruby, ruby-bdb and portupgrade. `portupgrade -if`
reinstall lang/perl
reinstall lang/pythonXX replace XX with version

the usual p5 packages method broke, I didnt know whether it was due to OS upgrade or a perl problem, I used this to get round the problem.  It removed all p5 modules to prevent rebuild errors.

`pkg info -o \* |while read pk pt;do pkg list $pt | grep site_perl/.\*\\.so\$ | while read so;do echo "$so";break;done;done | xargs rm`

then ran `portupgrade -vfk p5*` twice to reinstall them and make sure the double dependencies were good.

then all py packages.

`portupgrade -fvkx pythonXX py*`

then reinstalled ccache

at this point I did the mass port recompile, portupgrade only supports one exclusion flag, on my system excluding all the p5 ports saved the most time as were already done above, python was all redone, same with ruby, portupgrade wont break as you took care of it at start.

`portupgrade -aifvkx p5*` ideally twice, remove i for non interactive.

spamassassin was broken so `rm -rf /var/db/spamassassin/compiled/*` followed by an `sa-update` and `sa-compile`

After all this delete-old-libs might be safe.


----------



## bagas (Aug 10, 2021)

chrcol said:


> Here is what I did when going from 11 to 12.
> 
> reinstall ruby, ruby-bdb and portupgrade. `portupgrade -if`
> reinstall lang/perl
> ...


This information is off topic.
I want to abandon portupgrade and use more up-to-date software to update the software on the system at the moment.


----------



## sidetone (Aug 10, 2021)

I use ports-mgmt/portmaster.


----------



## bagas (Aug 10, 2021)

sidetone said:


> I use ports-mgmt/portmaster.


Portmaster installs programs both the packages themselves and from ports (sources).
So, there will be no conflict if programs are installed on the system from packages and from ports (sources)?


----------



## sidetone (Aug 10, 2021)

bagas said:


> Portmaster installs programs both the packages themselves and from ports (sources).
> So, there will be no conflict if programs are installed on the system from packages and from ports (sources)?


Dependency only packages aren't a problem, as portmaster can be set to use those.

Sometimes there's a problem with mixing ports and packages, but I easily work around that. By reinstalling, or keeping different types of ports categorized in the simplest way between what's in pkg and ports form. For instance, I'll use packages for Xorg, and perhaps build from ports for the rest.

A lot of people say, not to mix ports and packages, but I've been able to use both, and save time compiling. The important thing, if one is to mix ports and packages is to be sure both are of the same current or quarterly branch.


----------



## bagas (Aug 10, 2021)

Stability is important to me.
I also have this opinion - (A lot of people say, not to mix ports and packages).


----------



## Minbari (Aug 10, 2021)

bagas said:


> A lot of people say, not to mix ports and packages.


Unless you know what you are doing, obviously is not your case, so stay with quarterly repository (packages or ports) for a stable system.


----------



## Alain De Vos (Aug 10, 2021)

I used portmaster. I used portmanager. Then I switched to poudriere. I thought this is cool.
Now I run poudriere in a jail, which is really cool.
On my desktop I have 2000 ports compiled from source. And for maybe for 1% i did a manual config with option file in order to avoid conflict.
Ooh, I use quarterly. I have everything compiled from source and zero binary packages.


----------



## chrcol (Aug 11, 2021)

bagas said:


> This information is off topic.
> I want to abandon portupgrade and use more up-to-date software to update the software on the system at the moment.



Sorry, that wasnt obvious from your question.


----------



## bagas (Aug 11, 2021)

Alain De Vos said:


> I used portmaster. I used portmanager. Then I switched to poudriere. I thought this is cool.
> Now I run poudriere in a jail, which is really cool.
> On my desktop I have 2000 ports compiled from source. And for maybe for 1% i did a manual config with option file in order to avoid conflict.
> Ooh, I use quarterly. I have everything compiled from source and zero binary packages.


As I understand it, poudriere is needed only in one case, when the jail uses a common ports directory for all jail.
Do I understand correctly?


----------



## tingo (Aug 12, 2021)

FWIW, ports-mgmt/pkg_replace is a good replacement for portupgrade. Usage is slightly different.


----------

