Network comprehension question: localhost vs. local IP address

Volker Wysk post at volker-wysk.de
Tue Jun 13 18:46:46 UTC 2017


Hi!

The Moinmoin wiki server can be run without configuration, so you can try it, 
without the hasszle of configuring everything for Apache. It starts a server at 
localhost:8080. This works.

Now I want to try if it works well with my smartphone. I try the address 
http://192.168.178.20:8080/. Here "192.168.178.20" is the IP address of my 
desktop machine, which is being assigned by my Fritzbox router.

I get the following error message from Firefox: "Fehler: Verbindung 
fehlgeschlagen; Firefox kann keine Verbindung zu dem Server unter 
192.168.178.20:8080 aufbauen." Translated back to English: "Error. Connection 
failed. Firefox can't establish a connection to the server running under 
192.168.178.20:8080".

This occurs even when I try to access the 192.168.178.20:8080 address from the 
desktop itself, no other device involved. I, however, can connect to http://
192.168.178.20/.

Now I'm puzzled. What is the difference between localhost and 192.168.178.20? 
Why does it connect to the default HTTP port, but not to 8080?

Bye
Volker





More information about the ubuntu-users mailing list