How do I access port 8100 from a VM?
I want to access port 8100 on a linux VM. I am running lubuntu. I have tried multiple questions already and none of them seem to work:
Connection refused on port 8100 -I tried following this question, and created all the iptables that they had but Safari still cannot connect to the server.
https://askubuntu.com/questions/166068/port-seems-to-be-open-but-connection-refused - This answer doesn't really answer anything.
https://stackoverflow.com/questions/19034542/how-to-open-port-in-centos - This seems relevant but also does not work.
Here are commands that I run and none seem to help.
$ netstat -an | grep "LISTEN "
tcp 0 0 127.0.1.1:53 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:8100 0.0.0.0:* LISTEN
tcp6 0 0 :::35729 :::* LISTEN
This is my iptable:
$ sudo iptables -L -n
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:8100
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:8100
I create the rules with these commands:
sudo iptables -A INPUT -p tcp -m tcp --dport 8100 -j ACCEPT
sudo iptables -A OUTPUT -p tcp -m tcp --dport 8100 -j ACCEPT
I tried to use UWF and it seems that port 8100 is active:
$ sudo ufw status verbose
Status: active
Logging: on (low)
Default: deny (incoming), allow (outgoing), disabled (routed)
New profiles: skip
To Action From
-- ------ ----
8100/tcp ALLOW IN Anywhere
80 ALLOW IN Anywhere
443 ALLOW IN Anywhere
8100/tcp (v6) ALLOW IN Anywhere (v6)
80 (v6) ALLOW IN Anywhere (v6)
443 (v6) ALLOW IN Anywhere (v6)
On my vm the network is setup as a bridge so the ipaddress is 10.0.0.63. Then on my computer (not the vm) I go to 10.0.0.63:8100 and I should get what is being served on port 8100 but I get an error when I use Safari/Chrome/Firefox Cannot connect to server.
What am I missing?