pkg_info and an active /usr/ports is slow
b. f.
bf1783 at googlemail.com
Mon Dec 27 03:35:25 UTC 2010
> Just wondering about the interaction of pkg_info (no args) and having a
> ports directory.
>
> Without it it's blazing fast, with it it is just slow and sometimes just
> breaks during the listing.
>
> There is nothing in the man page about it reading the ports directory or
> why it would want or need to.
Are you sure that this is actually the case? From a cursory look at
the source code
( /usr/src/usr.sbin/pkg_install/info/* ), I don't see how the mere
presence of a populated PORTSDIR could affect "pkg_info", at least for
the most recent version (
# pkg_info --version
Package tools revision: 20101012
). Of course, if by "active" you mean that you are in the process of
building, installing, or removing a port or package while running
"pkg_info" at the same time, then this obviously would slow down both,
because, apart from the usual delays involved in time-sharing, both
may be attempting to simultaneously read and/or write to PKG_DBDIR, or
other parts of the same disk. It is best to avoid such a situation.
b.
More information about the freebsd-questions
mailing list