pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Upgrade all installed packages



On 4/17/23 23:03, Marko Bauhardt wrote:
Hi,
I believe this is a beginner question which is asked often.
But I didn‘t found an exactly answer.

I‘m using pkgsrc on a System where I don‘t have Admin permissions. So I installed pkgsrc and a couple of packages in my home dir.
After a while I upgraded pkgsrc to a higher version by switching to the next CVS tag. So I now I want to upgrade my installed packages as well. But how?

I see these options
- going step by step into every package and installing it again
- I read something about bulk installation?
- pkg_comp?

Can you give an advice what the best way is to Upgrade all my installed pkgs from source (compile) as a non-Admin user?

Thanks
Marko

pkgtools/pkg_chk and pkgtools/pkg_rolling-replace (layered on top of pkg_chk) are the basic tools I'm aware of. The difference is pkg_rolling-replace attempts to minimize the number of packages deinstalled at any instant, so the system is more usable during the upgrade process, which can take a long time.

In either case, the tree must be updated separately before running the tool, e.g. "cvs -q up -dP".

To fully automated it, you can install sysutils/auto-admin and run "auto-update-pkgsrc --defaults". This will update the source tree and then run "pkg_chk -su".

I run this overnight as a cron job on my development system and manually on other installations when the time is right.

For cron, run "crontab -e" and add something like the following:

00 01 * * * env PATH=/home/bacon/Pkgsrc/pkg/bin:/home/bacon/Pkgsrc/pkg/sbin:$PATH auto-update-pkgsrc --defaults > /home/bacon/pkgsrc-update.log 2>&1

Adjust the paths above according to your installation.

Run "man 5 crontab" for more info.

Best,

   J


Home | Main Index | Thread Index | Old Index