Menu

#5 Avoid "setting unknown option …" on ethernet interfaces

open
nobody
None
5
2020-02-12
2011-04-06
Anonymous
No

Hi,

I recently saw that my OpenWRT router (using munin-lite) was causing some errors in my munin logs. The problem is that when running ethtool on some ethernet interfaces from which one cannot get the speed, it spits out some error message on stderr that get transmitted as plotting data…
The following patch fixes that, by redirecting stderr to /dev/null when calling ethtool. (I did not do it for the second call too, because I think that if it passes the first call, the second one is ok)
BTW, maybe another solution would be not to pass /dev/stderr as plotting data altogether, but I'll let you decide.

Regards,
Benjamin

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.