G
G
Georgy Gorbachev2014-04-29 09:34:35
Computer networks
Georgy Gorbachev, 2014-04-29 09:34:35

How to redirect to an available IP?

Good afternoon. Faced such a problem - on the server side there is software through which you can drive in an IP or a domain where it will knock, on the other side a router with 1 wired Internet with a static IP and 2 Usb 3g modem also with a static IP

The essence of the problem - you need to from the server it was knocked on an available Ip, that is, if the Internet suddenly disappears over the wire, then it automatically switched to a 3G modem.
I couldn't find any solutions on google, maybe I'm looking in the wrong place!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
T
throughtheether, 2014-04-30
@stalkerdj

If I understand you correctly, the server needs to be able to access a resource that is accessible via two globally routable IP addresses. The proposed solution is shown in the diagram: 7664f53b1edf4eb09e01ef5955f936bd.png
The bottom line is that we need one more server/vps with a globally routable ("white") IP address. In the diagram, the address is specified as CCCC On this server, you need to install a load balancer that will monitor the availability of the target computer through different addresses (AAAA, BBBB) and accordingly proxy connections/datagrams (if TCP/UDP protocol is used). I implemented a similar scheme using an "iron" load balancer (F5 LTM), but, as far as I know, free haproxy will help in your case. In addition, on the routers closest to the target computer, port-forwarding must be configured accordingly.
Another solution could be a script on the server that monitors the availability of AAAA/BBBB addresses and changes the static DNS records on the server accordingly. The program will need to specify the target host by specifying a name (hostname). Then, in different situations (in terms of the health of the channels), this name will be translated differently into an IPv4 address.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question