OctoPrint service died after APT upgrade

What is the problem?

My Octoprint service (1.4.0) died after APT upgrade, it starts but imediately exits with ERRORCODE 0.
Service status -- Active: active (exited)

What did you already try to solve it?

  1. I've searched all logs, but in APT log there is about 50 upgraded packages at one run - no luck to search here.
  2. I've tried to restart whole box/PC, tried to restart OctoPrint service.
  3. I've tried to search in Octoprint logs - nothing there.
  4. Checked /etc/default/octoprint and /etc/init.d/octoprint for changes made automaticaly with APT - nothing there.
  5. Tried to manually start Octoprint via source activate and octoprint serve -> log is attached. There is some error but it seems like some compatability issue and I don't understand that enough, but it looks most promising after all.

Now I'm definitely lost :frowning:

Complete Logs

octoprint.log, serial.log or output on terminal tab at a minimum, browser error console if UI issue ... no logs, no support! Not log excerpts, complete logs.)

Octoprint logs: logs.zip (4.8 KB)
Service files: service.zip (2.4 KB)
Manual run terminal output: manual_run.log (11.4 KB)

Additional information about your setup

OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ... as much data as possible

OctoPrint ver.: 1.4.0 (upgrade to 1.4.1 always failed)

  • installed manually step by step according to tutorial from Gina
    OS: Ubuntu 20.04.1 LTS
    System: x64 - Intel Celeron N3150 (NUC)

Aditional info:

pi@octobuntu:~/OctoPrint/venv/bin$ python --version
Python 2.7.18rc1

(venv) pi@octobuntu:~/OctoPrint/venv/bin$ python --version
Python 2.7.17

Virtual env Python version differs from system wide Python - I'don't know if that could lead to some problems.

You have a non-standard configuration. This is where i would start looking into your problem.

OSError: [Errno 13] Permission denied: '/media/ext/Octoprint'

I see you have Tasmota installed as well. Did you enable any of the options for off on disconnect or anything like that with a command to shutdown octoprint?

Yes both - autoconnect with delay and autodisconnect :wink:
To non standard config: system runs on SSD so timelapses were saved on external drive mounted on /media/ext/
I've tried to unsecurely fix the problem by chmod -R 777 /media/ext/ - but after service restart nothing changes :frowning:

Tasmota plugin looks like a dead end, it is DIASABLED in safe mode so it doesn't start.

FIXED by Python3 migration script at: https://github.com/cp2004/Octoprint-Upgrade-To-Py3
Rebuild of venv helps and OctoPrint works again ...and as a bonus all is migrated to Python3 :slight_smile:

Thanks for help.

1 Like

One of my many superpowers is helping people without knowing.... Great that your issue is solved, and the migration went successfully

First migration went wrong from this link: https://get.octoprint.org/py3/upgrade.py
But with freshly downloaded script from GitHub it worked like a charm.

I've already known that all plugins are already compatilbe with Python 3 and planned the migration, but with broken OctoPrint I had nothing to loose, so I gave it a shoot :slight_smile:

Script done it's job and also (as side effect) fix broken venv - that was probably the main strange problem.

1 Like

It often happens after an update, I am left here with 'run this reinstall OctoPrint command' in so many threads.

Similar to turn it off and on again :wink:

1 Like