When I want to print "large" files the server crashes

What is the problem?

[I solved the problem myself, still posting because most of the post was written and this might help others. Feel free to comment if you have something to add.]
Hi,

I've been using OctoPrint almost since the day I got my 3D printer a year ago and everything was working great. Recently I tried to print "large" files (over 100Mo, somewhere over 20 hours of print) and when I start the print from the web interface it starts, sets the starting temperatures for bed and nozzle and then i got the popup saying that the server is down and that the interface will try to reconnect.

Checking via SSH i can see that the service crashed, and I can start it again.
The last message i have from the octoprint.log is always:
octoprint.util.comm - INFO - Changing monitoring state from "Starting" to "Printing"

I tested with small prints and it works fine. I also tested with older prints generated 7 months ago and they work fine. I did not change my slicer settings or version except for the print parameter since a long time. I could start a 48h/120MB print without problems

After a lot of trials, errors, restart of the service, Pi Zero, browser etc. I removed 2 plugins and disabled a third one. I remove Octolapse and Printing Time Genius (but it was from the first batch of removal so i'm not sure at all they were part of the problem) and I disabled "Pause Management".
If i enable Pause Management then the problem comes back.

As far as i know there was no pause in the g-codes I was printing...

What did you already try to solve it?

Update Octoprint. print in safe mode, reboot/restart everything

Have you tried running in safe mode?

Yes, it worked so i went back to normal mode and tried to enable/disable plugins until it worked

Did running in safe mode solve the problem?

Yes, but i still had to run some test to go back to normal, with 3 less plugins

Additional information about your setup

OctoPrint version 1.10.2 OctoPi version 1.0.0 running on Pi Zero W 2 printer Ender 3 Max Neo V2 (or something like that firmware From Creality, 1.4.7 from novembre 2022 browser I tried Chrome, Chromium, Firefox, Edge operating system Windows 11 or Debian12 with Gnome

Happy printing everybody

I made that plugin and would be interested in knowing why it may be causing issues. I can't think of any specific reason why the plugin would cause OctoPrint to crash and never did during all the testing I did during development of the plugin. Would have to enable serial logging in OctoPrint's settings to get the total picture of what was actually triggering the crash/communication drop.

Hi,
I'll be happy to help you troubleshoot the (my) problem.
I started a few days print so I will need some time.

Please let me know what you want me to provide you and I'll update you as soon as I can.

More information about the bug:
When I start the print Octoprint sets the temp on the printer
I can see the temp changing for a few seconds on the interface
Then the interface freezes and the popup pops
Printer keeps the nozzle and bed at the set temperatures

Log only shows the line I cited before.

I could also provide you at least one g-code that makes the program crash.

yeah, an example gcode file would be a good start. you should be able to zip it up and upload here. also, make sure you download the gcode file from OctoPrint's file list to share, because there are other plugins that could potentially change what's in what you send to OctoPrint.

Hi,

I will provide those as soon as the print I'm working on finishes.

Please let me know all the stuff you want as I plan to do a complete reinstall of octopi/octoprint soonish (2-3 weeks from now) without backups and hopefully be able to use all the plugins again.

a full system info bundle and a gcode file that crashes downloaded from OctoPrint's file list should be sufficient.

Hi,

I ran into what seems to be otherr problems so i did a clean reinstall of Octopi.
Unfortunatelly "Pause Management" plugin seems to crash the octoprint service as before.

Step by step of what I did today:

  • Flash the sd card of the pi zero with latest octopi from rpi-imager
  • Do the initial setup of octoprint via web interface
  • install some plugins (Dashboard, bed visualizer, navbar, PSU controler, resource monitor, Wifi Status and Pause Management, maybe some others too)
  • Try to print the gcode linked below
    Result : Preheat starts and then the server crashes.
    Last lines from "sudo service octoprint status":
    Sep 12 03:30:58 octopi octoprint[12454]: 2024-09-12 03:30:58,520 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
    Sep 12 03:30:58 octopi octoprint[12454]: 2024-09-12 03:30:58,545 - octoprint.util.comm - INFO - Changing monitoring state from "Starting" to "Printing"
    Sep 12 03:31:00 octopi octoprint[12454]: 2024-09-12 03:31:00,690 - octoprint.util.comm - INFO - Printer seems to support the busy protocol, will adjust timeouts and set busy interval accordingly
    Sep 12 03:31:40 octopi octoprint[12454]: 2024-09-12 03:31:40,198 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
    Sep 12 03:31:43 octopi systemd[1]: octoprint.service: Main process exited, code=killed, status=11/SEGV
    Sep 12 03:31:43 octopi systemd[1]: octoprint.service: Failed with result 'signal'.
    Sep 12 03:31:43 octopi systemd[1]: octoprint.service: Consumed 1min 30.607s CPU time.

See the linked bundle for more details

When I deactivate the plugin in plugin management and reload everything then the print starts and everything seems to be fine (I stop it because I do not need to print it again).

Just to be clear, I do not want to point at the plugin as being the source of this problem, like most things in programs it's probably just part of something and it's the first thing that I found. I know that software development is hard.

Hope I can help with the information provided.

If you need me to try other stuffs let me know. Please note that "Pause Management" is not needed for me at the moment so I can live without it.

Have a good day.

your share from google drive is blocked...

Hope the wetransfer link works:

Thanks that link did work for me. The seg fault error that you're seeing in the service status is something I haven't been able to reproduce (assuming it happens right away), even using the large file provided in the zip. I'm 5 minutes into the baby groot giant zip using the virtual printer on my test machine without problems. I'll add these other plugins you mention and see if there is any difference, could be plugin conflict.

Ok.

Yes it was happening at the very beginning of the print, usually during the heat up process. Timestamps show less than a minute between print starting and crash happening.

I thought at some point that this might be related to memory due to the size of the file so I monitored the memory usage via top command through SSH but it stayed at normal levels.

It's probably related to plugins conflict on large files on my setup and will probably be hard to reproduce.
Again if you need me to run some test I'd be happy to contribute.

Cool. Well, I got all the plugins installed that you had, with the exception of WiFi Status (that's a linux only plugin and my test system is running in Windows) and it's still not crashing. I'd be curious to know if the same issue happens for you with only Pause Management enabled and the others disabled?

Oh...and FYI...you might like UI Customizer as an alternative to Themeify, it's still being actively developed and adds a lot more options than just changing the color...

Hi,

I disabled:

  • Bed visualizer
  • Dashboard
  • G-Code viewer
  • Navbar temp plugin
  • Print time genius
  • PSU control and PSU control - TP Link
  • Resources Monitor
  • Themify
  • WiFi Status
  • UI Customizer

and enabled:

  • Pause Management

Seems to be working this way. Still trying with same Baby Groot Giant gcode.

I then tried activating plugins keeping Pause Management to see where the conflict is:

  • UI Customizer (works)
  • Bed visualizer (works)
  • Dashboard (Works)
  • G-Code viewer (Works)
  • Navbar temp plugin (Works)
  • Print time genius (Works)
  • PSU control and PSU control - TP Link (Works)
  • Resources Monitor (Works)
  • WiFi Status (Works)

So I switched back to Themify to test and it works also...

I'm now back to UI Customizer. and it's still working...

Not much to add, I can't reproduce it anymore it seems... At least I moved from an old UI plugin to a recent and maintained one...

1 Like