busybox ping patch for selecting interface
|Reported by:||Bob Keyes||Owned by:||developers|
|Priority:||normal||Milestone:||Barrier Breaker 14.07|
It's useful to be able to select which interface a ping will go out over. This is most useful for when you have multiple upstreams, on of which is preferred. Say for instance, you have your own cable modem but have arranged with your neighbor to use his DSL modem in case you have a problem with your cable modem. It's easy enough to know when your modem is broken, and to change the default route to be your interface to your neighbor's cable modem. The problem is knowing when to switch back, without temporarily changing the default route back to your cable modem and trying it. With this patch, you can ping out to some central location on the Internet every so often over your cable modem, while the rest of your traffic flows over your neighbor's dsl modem. When your ping finally gets responses, you can switch the default route back over to your cable modem.
the usage will be
ping -n eth1 126.96.36.199
where eth1 is the interface you want to ping over and 188.8.131.52 is the destination.
Patch is attached.