Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[paho-dev] Problem with routing


I am writing a Python 3.4 application that uses Paho as the MQTT client library. It has been working mostly fine, but I have now encountered a sudden problem and I wonder if someone on this list could assist me with it.

I am connecting to a server over ethernet and there is a company's firewall between my software and the server. It has worked fine for the 1,5 years I have been doing this development, except for two occasions, which seem similar to me. The first time the problem occured, the IT support was able to fix it in a day by doing something about NAT. Now the problem came back, and while it looks the same to me, the IT support hasn't been able to fix it again. There is a suspect that some router would have been replaced and that would have altered some settings, but that's just a guess.

What happens is that when I call Paho's connect(), trying to bind to a particular IP address (the device has several network interfaces), connect() just won't return. Ever.

When that happens and I attempt to make sure the ethernet connection works in general by pinging, I get this:
ping -I eth1
PING ( from eth1: 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=52 time=22.5 ms
From icmp_seq=1 Redirect Host(New nexthop:
From icmp_seq=2 Redirect Host(New nexthop:
64 bytes from icmp_seq=2 ttl=52 time=22.8 ms
From icmp_seq=3 Redirect Host(New nexthop:
64 bytes from icmp_seq=3 ttl=52 time=25.4 ms

What catches my attention is this: "Redirect Host(New nexthop:". When everything works fine, that won't appear. I'm just not enough a network guy to say anything more. I am just stating what I am seeing.

Just for the sake of comparison, this is what I get when I ping the same address via a mobile connection that Paho uses with no problem:
ping -I wwan0
PING ( from wwan0: 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=55 time=883 ms
64 bytes from icmp_seq=2 ttl=55 time=357 ms

Does anyone have any idea of what might be going on? Is there something I can do to fix this in how I use Paho? Or is this something about Paho, and if it is, could it be something the community might want to fix?

Best Regards,
Antti Gärding

Back to the top