E
E
eidikos2019-09-27 03:40:24
SSH
eidikos, 2019-09-27 03:40:24

Why is connection refused when connecting via external ip, but everything works via local?

The laptop is running a virtual machine with centos (vmware, bridged connection).

The problem is that in the terminal, when connecting via ssh to the vm via external ip, it says connection refused, but if you connect via local ip, then everything is fine, while through a phone that is also on the local network, it connects via both external and internal ip .

Previously, everything worked like clockwork, but it stopped after one of the OS reinstallations on vm.
Port 22 for example, the situation is similar on all ports, but ping from a computer via external ip passes.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Artem @Jump, 2019-09-27
Tag

Because HairpinNat needs to be configured if you want to go to the external IP from the local network.

A
Andrey Barbolin, 2019-09-27
@dronmaxman

When connecting from a laptop, you need to look at the contents of /var/log/auth.log.
Have you tried changing the LAN IP on the virtual machine?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question