[diskless] pkg takes 100% of a CPU

Eduardo Morras emorrasg at yahoo.es
Sun Apr 8 11:03:20 UTC 2018


On Sat, 07 Apr 2018 08:19:51 -0600
Ian Lepore <ian at freebsd.org> wrote:

> On Sat, 2018-04-07 at 11:50 +0200, BERTRAND Jol wrote:
> > Steven Hartland a crit:
> > > 
> > > When we?ve seen it using 100% it?s been doing comprehension stuff
> > > which usually finishes you just have to wait. Not sure if that?s
> > > what you?re seeing?
> > 	Yesterday, I have killed pkg after more than 100 hours of
> > CPU time...
> > 
> > 	Best regards,
> > 
> > 	JB
> 
> For me, pkg(8) quit working on systems that have /var/db mounted from
> nfs long ago, maybe as much as a year ago at this point. I mentioned
> it on irc, and was told "It's probably something to do with locking",
> but I already have boot.nfsroot.options="nolockd" in loader.conf
> (because that's pretty much the only option because the rc(8) system
> was broken years ago when it comes to nfsroot).

Is the db is on netbsd side? If yes, sqlite db over nfs are pita
because nfs lies about file locking. It's true that it works 99% of
time, the problematic part is the 1%. Documentation talks about
incorrect NFS implementation, but a correct implementation can fail too
because network latency, separate memory data between clients and
server or different filesystem semantics; or all of them.

https://www.sqlite.org/faq.html#q5

https://stackoverflow.com/questions/9907429/locking-sqlite-file-on-nfs-filesystem-possible#9962003



> 
> -- Ian

---   ---
Eduardo Morras <emorrasg at yahoo.es>


More information about the freebsd-hackers mailing list