You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
On a system with multiple network interfaces, I would like to make DNS resolution requests over a specific interface.
I have a problem similar to #14617. Consider a Linux server with 2 interfaces, primary eth0 and a backup internet connection using a LTE modem on eth1. The system's default route is over eth0, and in normal operation all traffic goes over that interface.
If the primary connection is unavailable, I want to be able to make certain requests from my node program over the backup connection. However, the backup connection is metered, so I don't want a systemwide failover; only specific, high-priority requests should go over the backup.
Describe the solution you'd like
This could be accomplished similarly to the localAddress option available to TCP sockets. (There's also bind(port, address) available to UDP sockets.)
Activity
daguej commentedon Aug 18, 2020
If this is reasonable, I'm happy to take a stab at implementing.
jasnell commentedon Aug 18, 2020
/cc @bnoordhuis
dns: add setLocalAddress to Resolver
dns: add setLocalAddress to Resolver
dns: add setLocalAddress to Resolver
dns: add setLocalAddress to Resolver