Can't connect to local host

What is the problem?

after shutting down server, trying to reconnect to localhost:5000, the page wont load and it says "Unable to connect"

What did you already try to solve it?

i uninstalled octoprint and re-installed and the installation said port 5000 is already in use.

Have you tried running in safe mode?

can't open octoprintui to get safe mode

Did running in safe mode solve the problem?


Systeminfo Bundle

You can download this in OctoPrint's System Information dialog... no bundle, no support, unless the reason you couldn't retrieve the bundle is your network issues


Additional information about your setup

Hardware you are trying to connect to, hardware you are trying to connect from, router, access point, used operating systems, ... as much data as possible

i used windows installer to install octoprint, worked great till i had a power outtage, when i got back on i couldn't connect to localhost:5000, so i re-installed windows 10 and downloaded and installed again and worked great, but stupid me decided to shut down server just to see if i can get back on, and nope, can't connect to localhost:5000 printer is a ender 3 v3 se and its conncected to my computer via usb-c.

any logs? I'm not sure where they're located on windows, but I assume somewhere in the OctoPrint folder

Definitely need to check the service wrapper logs in C:\OctoPrint\ and OctoPrint's standard logs. You can validate the service was added in window's services manager and try to start it if it's not running. Make sure the service is setup to start automatically too.

The reason it said port 5000 was already in use was probably because of the registry entry the installer adds for used ports. Early versions of the installer would not remove those on uninstall.

Port 5000 is used by the local haproxy instance to connect internally to the Octoprint application which is ONLY listening on port 5000 for connections from, aka local host. . Connect your browser to port 80 for http to the machines normal IP address, not port 5000. You can see all the open ports and associated IP addresses by typing sudo netstat -tulnp at the machines CLI, which you can get to by using an ssh connection.

In this case, they're using OctoPrint on Windows, via the Windows installer, so haproxy is not in use & netstat will not work.

Well netstat should work on Windows. It's a little different but you can see the open ports and exes associated.

"netstat" will get you a list of ports. Without exes.
"netstat /?" will get the command line options
"netstat -b" gives the ports and exes associated. but requires admin permissions in the terminal.

@rcw88 Also I don't think the standard ~Linux install for Octoprint with HA sets port 5000 for listening. It forwards to the octoprint instance which should be listening on 5000 localhost. HA in my experience for Octoprint install script is by default listening on Port 80 but could be changed. So you are correct to point to 80 but 5000 should also be usable from a localhost instance of a browser.

My bad didn’t notice windows10 in the question. Sounds like the services are not running after reboot or set to auto start on reboot.