[sudo-workers] Is there a way to avoid get_net_ifs() when the information won't be used?

Todd C. Miller Todd.Miller at courtesan.com
Thu Jan 23 12:37:53 MST 2014


On Thu, 23 Jan 2014 10:58:20 -0800, Rick Jones wrote:

> A run-time switch would be splendid.

I'll implement that in the next sudo release.

> I've gone ahead and fired-up a FreeBSD 9.2-RELEASE VM, and created 8000 
> "gre" interfaces (without IPs assigned, just "ifconfig greN create")and 
> while there was a slight increase in time for sudo (unpatched 1.8.9p4) 
> of a few milliseconds, it wasn't nearly as bad as under Linux.  I'm 
> going to spin-up a similar, Ubuntu 13.10 VM to get a better A/B 
> comparison (everything I've mentioned thusfar has been bare-iron, but I 
> don't have the luxury of running FreeBSD on bare-iron) and perhaps 
> mention it to the Linux netdev folks.  Would you like to be cc'd on that 
> message?

The first __sysctl() is probably to get the size and the other is
to fill it in.  I think it is worth mentioning to Linux net-dev.
It may be possible to use recvmsg() with a scatter-gather buffer
instead of repeated calls.

 - todd


More information about the sudo-workers mailing list