Hi, I have 3 MEGA's running on my LAN that I can access over the internet with port forwarding. I now have a Yun running with both WIFI and WAN configured as 10.0.1.88 and 10.0.1.89, I can access both via my LAN but the port forwarding does not work. I have no sketch running on the yun, but I would expect to see the yun web control panel over the internet when forwarding to 10.0.1.88. Is there anything special on a Yun that I am not aware about ? Any help would be appreciated Hans
Yun have firewall build in.
iptables -L /etc/init.d/firewall stop iptables -L
if after turn off firewall, system is working then fine tune firewall setting at LUCI.
How are you trying to access it and what port are you forwarding?
Sorry but I don't understand what the Yun internal firewall has to do with port forwarding. If it works with the local address, it should work when my router forwards the WAN address to the LAN address. But I could be wrong, I'm not a pro in this, and that 's why I ask for help. I must admit that I don't understand what to to with the code you propose.
What I do is in my router is forward incoming traffic on port 8889 to 10.0.1.88: 80 I do the same for other arduinos on my lan e.g. 8888 is forwarded to 10.0.1.155:80 and I have web access to this arduino
luxxtek: Sorry but I don't understand what the Yun internal firewall has to do with port forwarding. If it works with the local address, it should work when my router forwards the WAN address to the LAN address. But I could be wrong, I'm not a pro in this, and that 's why I ask for help.
The purpose of the firewall (any firewall for that matter) is to prevent access from outside of your LAN. That is exactly what you are trying to do, accessing your Yun from outside the LAN. You do not have the problem with your Megas, as the Ethernet library doesn't include any firewall features like the whole Ethernet/WiFi functionality of the Yun does, they are always wide open to abuse once forwarded...
I must admit that I don't understand what to to with the code you propose.
The iptables commands just list the forwarding/port rules of the Linino side of the Yun. The second line should disable the the firewall features of the Linino side, which should show in differences between the two iptables -L (-L = "List") commands...
I"ll try to change the firewall but I must admit I don’t know very well where to start, a screendump with the correct settings would be appreciated.
luxxtek: I"ll try to change the firewall but I must admit I don't know very well where to start, a screendump with the correct settings would be appreciated.
Don't have my Yun accessible right now to check but the code that sonnyyu posted, second line, executed on the command line via ssh, should turn the Yun's firewall off...
I stopped the firewall but that did not make any difference. I got help from a "network specialist" and he found out that for some reason the routing table was not complete with the commando below the routing table was completed route add default gw 10.0.1.1 eth1
now I can access the YUN from anywhere, I tested with and without firewall, does not make any difference. I will factory reset my yun tonight and check if the routing table is incomplete by default, maybe this is something that should be explained in a tutorial.
UPDATE: the real problem is that I did not enter the gateway address when setting up the Yun with a static IP address. Entering the gateway address automatically updates the routing tables.