What is the problem?
ERR_CONNECTION_REFUSED while accessing octoprint.local (http&https and tested on port 80/8080/5000)
What did you already try to solve it?
curl: (7) Failed to connect to localhost port 443: Verbindungsaufbau abgelehnt
curl: (7) Failed to connect to localhost port 80: Verbindungsaufbau abgelehnt
curl: (7) Failed to connect to localhost port 5000: --> some html output (good)
Logs (syslog, dmesg, ...)
journalctl - xe
Sep 25 20:23:17 octopi haproxy[1429]: [ALERT] 267/202317 (1429) : Fatal errors found in configuration.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Control process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- An ExecStartPre= process belonging to unit haproxy.service has exited.
-- The process' exit code is 'exited' and its exit status is 1.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- The unit haproxy.service has entered the 'failed' state with result 'exit-code'.
Sep 25 20:23:17 octopi systemd[1]: Failed to start HAProxy Load Balancer.
-- Subject: A start job for unit haproxy.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- A start job for unit haproxy.service has finished with a failure.
-- The job identifier is 879 and the job result is failed.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Service RestartSec=100ms expired, scheduling restart.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Scheduled restart job, restart counter is at 5.
-- Subject: Automatic restarting of a unit has been scheduled
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- Automatic restarting of the unit haproxy.service has been scheduled, as the result for
-- the configured Restart= setting for the unit.
Sep 25 20:23:17 octopi systemd[1]: Stopped HAProxy Load Balancer.
-- Subject: A stop job for unit haproxy.service has finished
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- A stop job for unit haproxy.service has finished.
-- The job identifier is 939 and the job result is done.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Start request repeated too quickly.
Sep 25 20:23:17 octopi systemd[1]: haproxy.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- The unit haproxy.service has entered the 'failed' state with result 'exit-code'.
Sep 25 20:23:17 octopi systemd[1]: Failed to start HAProxy Load Balancer.
-- Subject: A start job for unit haproxy.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
-- A start job for unit haproxy.service has finished with a failure.
-- The job identifier is 939 and the job result is failed.
HAPROXY.cfg
global
maxconn 4096
user haproxy
group haproxy
daemon
log 127.0.0.1 local1 debug
tune.ssl.default-dh-param 2048
defaults
log global
mode http
option httplog
option dontlognull
retries 3
option redispatch
option http-server-close
option forwardfor
maxconn 2000
timeout connect 5s
timeout client 15min
timeout server 15min
frontend public
bind :::80 v4v6
bind :::443 v4v6 ssl crt /home/pi/ssl/mydomain.com.pem ca-file /home/pi/ssl/OctoPrintCA.crt
option forwardfor except 127.0.0.1
scheme https code 301 if !{ ssl_fc }
use_backend webcam if { path_beg /webcam/ }
default_backend octoprint
backend octoprint
acl needs_scheme req.hdr_cnt(X-Scheme) eq 0
reqrep ^([^\ :]*)\ /(.*) \1\ /\2
reqadd X-Scheme:\ https if needs_scheme { ssl_fc }
reqadd X-Scheme:\ http if needs_scheme !{ ssl_fc }
option forwardfor
server octoprint1 127.0.0.1:5000
errorfile 503 /etc/haproxy/errors/503-no-octoprint.http
backend webcam
reqrep ^([^\ :])\ /webcam/(.) \1\ /\2
server webcam1 127.0.0.1:8080
errorfile 503 /etc/haproxy/errors/503-no-webcam.http
global
maxconn 4096
user haproxy
group haproxy
daemon
Startup message in ssh
Traceback (most recent call last):
File "", line 1, in
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/init.py", line 6, in
import logging as log
File "/usr/lib/python2.7/logging/init.py", line 26, in
import sys, os, time, cStringIO, traceback, warnings, weakref, collections
File "/usr/lib/python2.7/weakref.py", line 14, in
from _weakref import (
ImportError: cannot import name _remove_dead_weakref
Access OctoPrint from a web browser on your network by navigating to any of:
http://octopi.local
http://192.168.2.112
http://[fd7d:10dc:6c4:1:ce72:4f62:21bf:e186]
http://[2003:ec:6bdd:1078:fb71:dbe4:e3bf:2f67]
https is also available, with a self-signed certificate.
OctoPrint version : unknown
OctoPi version : 0.16.0
status haproxy.service
pi@octopi:~ $ systemctl status haproxy.service
● haproxy.service - HAProxy Load Balancer
Loaded: loaded (/lib/systemd/system/haproxy.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2019-09-25 20:33:59 BST; 16s ago
Docs: man:haproxy(1)
file:/usr/share/doc/haproxy/configuration.txt.gz
Process: 1092 ExecStartPre=/usr/sbin/haproxy -f $CONFIG -c -q $EXTRAOPTS (code=exited, status=1/FAILURE)
Sep 25 20:33:59 octopi systemd[1]: haproxy.service: Service RestartSec=100ms expired, scheduling restart.
Sep 25 20:33:59 octopi systemd[1]: haproxy.service: Scheduled restart job, restart counter is at 5.
Sep 25 20:33:59 octopi systemd[1]: Stopped HAProxy Load Balancer.
Sep 25 20:33:59 octopi systemd[1]: haproxy.service: Start request repeated too quickly.
Sep 25 20:33:59 octopi systemd[1]: haproxy.service: Failed with result 'exit-code'.
Sep 25 20:33:59 octopi systemd[1]: Failed to start HAProxy Load Balancer.
Additional information about your network (Hardware you are trying to connect to, hardware you are trying to connect from, router, access point, used operating systems, ...)
Connecting via Chrome from windows to raspi over wlan. Wlan (with ssh) works fine.