Here is the topology:
-----s0---s1-----
h1 --| |--h2
-----s2---s3-----
h1 pumps a file to h2 using UDP in a reliable way. The link between s0 and s1 may be down. Then it should continue to send the data using only the bottom path. Is there a way to detect that the link is down?
So far I created two python sockets in h1 and two in h2 for each path. Using select.select I can get the ready socket to read ack's. If timeout occurs I can retransmit. However, when the link is down, I cannot know that it is down.