On Tue, 19 Feb 2019 Mathieu Mirmont <m...@parad0x.org> wrote: > Package: irqbalance > Version: 1.5.0-3 > Severity: normal > Tags: patch > > Hi, > > While testing something else in a virtual machine I noticed that > irqbalance exits if it detects a single CPU. When running under runit > the service is continuously restarted. > > I would suggest detecting this case directly from the run script and > stopping the service with sv, something like this: > > ------------------------------------------------------------ > #!/bin/sh > if test $(nproc) = 1; then > echo "Not starting irqbalance: only one CPU detected" > sv stop . > exit 0 > fi > exec /usr/sbin/irqbalance --foreground > ------------------------------------------------------------
Thanks for this. I'm not really knowledgeable on runit, for example I wonder: should we use `sv stop`, `down`, or `exit`? From sv(8) I'd say `sv down` is preferable, but I'm not sure. I need some time to do some proper testing, but we'll get this fixed. Paride