Random Crashes with Unkown Reason

What is the problem?

I often (about every 2-3 prints, depending on length it seems) encounter that the OctoPrint server is unavailable. Before I disabled some plugins It even crashed mid print. Maybe its just luck that recent prints didn't crash but rather after prints.

As an example: I finished my last print yesterday night and when I woke up today and wanted to print another part I could not connect to octopi.local. Also SSH is not available.

What did you already try to solve it?

I disabled some non-essential plugins but like I said it still crashes from time to time.

Also I updated and upgraded all firmware on the RP

Have you tried running in safe mode?

Not yet I will try after the current print

Did running in safe mode solve the problem?

Remains to be seen.

Systeminfo Bundle

octoprint-systeminfo-20210929093624.zip (31.1 KB)


It seems the system crashed on 9/28 at around 22:45. I came back at 8:56.

octoprint (3).log (117.5 KB)

serial (4).log (7.3 KB)

Additional information about your setup

  • OctoPrint version: 1.6.1
  • OctoPi version 0.18.0
  • RP: RP 3B+
  • printer Prusa i3 MK3S+
  • webcam Logitech C270
  • firmware 3.10.0-4481
  • browser Chrome
  • operating system Windows 10 Pro

This sounds like OS / hardware issue. Some thoughts:

  • Have you checked the os level logs?
  • Also try monitoring the temperature of the chip. There are some plugins for that, ex: Navbar Temp Plugin
  • is the powersupply strong enough? Are you getting power related warnings? there is a standard (included) plugin for that

I will post the os level logs as soon as I get home later.

I have the named plugin installed. The highest temp. I've ever seen was 38.6°C if I remember correctly. But I can't be 100% sure because I never looked at the temp. shortly before a crash. Also I want to mention that the RP3B+ has heat spreaders and gets actively cooled by a fan.

I can ensure that power supply is not the problem since I am using the official RP power supply. I once tried to power the RP with GPIO pins but octoprint immediately warned me about low power so I swapped back. I never received this warning when using the official power supply.

other options

  • check/replace the sd card in pi: might be dying
  • try with a fresh pi image
  • can you connect monitor to it, to check if os is still responsive locally?

The µSD card is 1 month old, so I doubt it's malfunctioning. But if so what can I do to check if the µSD card is the reason except for buying a new one and try with that?

If the other things doesn't work I will do that but I hoped that the logs could narrow the problem down so I wont repeat it even if I reinstall octopi...

That is a great idea. Next time it crashes (hopefully never) I will plug my monitor (HDMI) to it. Also I will check if I can connect my PC to the RP after the crash with a USB cable. Currently the RP runs remotely with WiFi.

If you can, try running the RPi with an ethernet cable rather than over WiFi. It doesn't look specifically like the OS/OctoPrint crashed, but more that it lost network connection. Right before there's a sudden restart in the logs (2021-09-28 17:40, restarts at 17.17 - time traveling), OctoEverywhere is complaining it can't reach the server.

You were right! Today it "crashed" again and I connected the RP to my router via lan cable and I could log to octopi.local again. It seems only the WiFi connection fails... But it is very strange that the RP can't reconnect... I can ensure that the internet connection / router was up the whole time, since I had a online meeting without any interruption simultaneously.

Also it happened right after I change filament. Does this has something to do with the disconnection?

A possible solution I can think of is to let RP retry more times and for longer since the RP connects perfectly fine after a restart. I will look up how to change this setting.

I can't say on that one, sorry.

Raspberry Pi's WiFi dying is a fairly well-known and documented problem at this point. There's a number of topics about the wifi disconnecting on this forum, if you are searching for network disconnects instead of crashing as your post was named, which probably led to you not finding them.

You could try something like this:

It attempts to restart the network service (or something) if it detects it can't connect. It does need some manual configuring, make sure you check the listing.

I'm not sure if the RPi will reconnect on it's own, whatever settings you configure, as it is more of a software problem (as far as we understand).

If you can keep the network cable plugged in permanently, then that is a viable solution - the disconnects don't seem to happen wired, only wifi.