#Connection refused after packages update?

1 messages · Page 1 of 1 (latest)

red scaffold
#

So I updated all the packages, and everything seems fine.
Played around as I was setting a new probe, rebooting was fine
I switched the printer off and on power on I can no longer access the mainsail client, I get a connection refused error
I can SSH no problem into the RPI
Any ideas where to start looking?
Checked the Moonraker log and it's not updating, last update was at 19:19 (it's 20h here) it is actually updating

tidal nightBOT
#

Ahoi @red scaffold!
It looks like you did not provide all the necessary information we need to help you.
Please upload your logfiles and a detailed description of your problem.
For further information see: https://docs.mainsail.xyz/faq/getting-help/discord#provide-information
Note: We only accept .log and .txt files as log files.
This is an automated message

We are glad to help and chat with you on our Community Discord, but if you need help and want the best support possible you should, follow a few simple rules:

red scaffold
#

printer_data/logs/mainsail-access and log are empty

#

scroll down for last power on at ~20:02

red scaffold
#

i can correctly access http://<printer-ip>:7125/printer/info

#

and the moonraker server at port 7125

#

but the mainsail interface still refuses to connect

true garnet
#

Send a screenshot of the Moonraker website and the failing Mainsail website

red scaffold
true garnet
#

Send the output of systemctl status nginx

red scaffold
#

hm

#

May 22 20:02:23 mainsailos systemd[1]: Starting A high performance web server and a reverse proxy server...
May 22 20:02:23 mainsailos nginx[637]: nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (2: No such file or directory)
May 22 20:02:24 mainsailos nginx[637]: 2025/05/22 20:02:23 [emerg] 637#637: open() "/var/log/nginx/access.log" failed (2: No such file or directory)
May 22 20:02:24 mainsailos nginx[637]: nginx: configuration file /etc/nginx/nginx.conf test failed
May 22 20:02:24 mainsailos systemd[1]: nginx.service: Control process exited, code=exited, status=1/FAILURE
May 22 20:02:24 mainsailos systemd[1]: nginx.service: Failed with result 'exit-code'.
May 22 20:02:24 mainsailos systemd[1]: Failed to start A high performance web server and a reverse proxy server.

#

the /var/log/nginx directory didnt exist, so it was failing to create the log file

true garnet
#

So you fixed it? Otherwise I recommend to reinstall nginx, just to be sure, everything is setup correctly

red scaffold
#

yeah, just creating the nginx dir fixed i

#

ill keep an eye out for errors but a power cycle after creating the dir and its working again

#

i think the nginx dir was removed during an automated log clean up when low on disk space

#

seems weird this kind of error is not handled tbh

#

thanks a lot

#

it seems that the package updates must have caused the low disk space and triggered the clean up, so not a direct result of the upadte

true garnet
red scaffold
#

oh not a system default clean up, i mean some scripts i myself put in place

#

i'd never had an issue with a library failing to work because it's not prepared to create the directory again

true garnet
true garnet
#

This only makes sense, if the workspace is configurable, otherwise it's just wasted resources and computing power

red scaffold
#

well the log dir is not exactly static

#

it's not a waste to handle this error, takes what, 1 ns?

true garnet
#

It's still unnecessary time waste, if you do that during logging. If it's just at startup it's okay

true garnet
#

I thought that directory was static

red scaffold
#

Well it literally means "variable" and it's purpose is to store variable data