Inside the system, running on virtual machine, I can access the running server at 127.0.0.1:5000.
Although the 'remote' address of the vm is 192.168.56.101 (ping and ssh work fine), I cannot access the server with 192.168.50.101:5000 neither from the virtual machine nor from the local one.
I guess there's something preventing remote connections.
Here's /etc/network/interfaces:
auto eth1
iface eth1 inet static
address 192.168.56.101
netmask 255.255.255.0
ufw is inactive.
How do I fix this problem?
the output is 127.0.0.1:5000 0.0.0.0:* LISTEN. This means the server doesnot listen to addresses other tha localhosts?
I tried ufw allow 5000, no result
-m iprange --src-range 10.1.1.4-10.1.1.10to the iptables command. This example limits connections to a few boxes on my local network, namely 10.1.1.4 to 10.1.1.10, inclusive. (Hopefully some clown who happens to get one of those IPs won't try port 5000 at the next net café I wander into. ) – Michael Scheper Nov 19 '15 at 06:46iptables ...worked for me. But I'm just curious that I was being able to run my flask app yesterday but today I got this error. I couldn't even locallycurl localhost:5000(which saidconnection refused), let alone remote connection! I was willing to know why all of a sudden such a thing happens and is it possible that this happens in the future and how can I prevent it? – imans77 Feb 11 '19 at 14:25