Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

possibility of regulation (and turnoff) for pkg_has_updates / monopolization of pkg by pkgng via pkg-version #91

Open
olevole opened this issue Feb 6, 2019 · 1 comment

Comments

@olevole
Copy link

olevole commented Feb 6, 2019

For system with lot of packages execution of:

https://github.com/xaque208/puppet-pkgng/blob/2.1.1/lib/facter/pkg_updates.rb#L8:

50338  1  S      0:00.01 /usr/sbin/pkg version -ql<
50339  1  D      0:00.12 /usr/sbin/pkg version -ql<

for pkg_has_updates facts always lock pkg for a long time and user can do anything with pkg. The problem is the slow 'pkg version' execution when ports not installed (and fetchindex not performed).
For example, on a PC with desktop role (KDE5) and 1746 packages this operation may take ~ 20 minutes (no ssd, one hdd).

More details: freebsd/pkg#1739

it would be nice to regulate this behavior and be able to turn off. Or try to find another solution, for example pkg dry-run:

pkg upgrade -Unq

or

pkg version -RU

olevole pushed a commit to olevole/puppet-pkgng that referenced this issue Feb 6, 2019
Using of ports tree (even with the presence of INDEX-XX) to determine outdated packages
is incredibly slow. In addition ports may have the updated version while pkg still not.
Since we work with pkg and not the ports we need to fix the source to repo

Fixes for issue voxpupuli#91
@zachfi
Copy link
Contributor

zachfi commented Feb 13, 2019

That is a lot of packages. My largest box has 263. +1 to this change.

olevole pushed a commit to olevole/puppet-pkgng that referenced this issue Feb 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants