I would like to know if there are any way (under Linux, of course) to declare an interface as down if I got more than X % of packets errors or more than X % of collisions.
Any idea ?
No, there is nothing "out of the box" I am aware of. However, you could probably do this with a little custom script run from crontab.
You could e.g. parse the output of
However, I don't really see this as a good idea. For one thing, pulling the interface out under processes that might be using it will most likely cause problems.
Could you explain why you feel this is necessary? What problem are you trying to solve? A different solution might be more approriate.
You almost certainly want to use bonding or something; this sorts out high-availability networking for you.