Octoprint starting in Safe Mode

What is the problem?
Octoprint's only starting in safe mode since 2 days.

What did you already try to solve it?
Deinstall some plugins/rebooted

Logs (octoprint.log, serial.log or output on terminal tab, browser error console ...)
octoprint (1).log (153.8 KB)

Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ...)
I'm using the newest version of octopi with an ender 3 and original melzi board.
Firmware is flashed with Octoklipper, allowing it to run a bltouch.

I really can't see anything in the logs so any help is highly appreciated.
Thanks in advantage!
Nico F.

Hi @NicoF!

There a some warnings and errors. I found these in your log file (and there are more):

2019-08-15 18:30:03,774 - octoprint.plugins.pi_support - WARNING - This Raspberry Pi is reporting problems that might lead to bad performance or errors caused by overheating or insufficient power.
!!! UNDERVOLTAGE REPORTED !!! Make sure that the power supply and power cable are capable of supplying enough voltage and current to your Pi.

(multiple times)

2019-08-16 10:05:53,158 - octoprint.util.comm - WARNING - Received an error from the printer's firmware: Printer is not ready
| Last lines in terminal:
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: M105
| Recv: ok T:0
| Send: G28
| Recv: // Printer is not ready
| Recv: // The klippy host software is attempting to connect.  Please
| Recv: // retry in a few moments.
| Recv: !! Printer is not ready

(multiple times)

2019-08-15 18:29:45,094 - octoprint.environment - ERROR - Unexpected error while detecting environment
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/environment.py", line 51, in run_detection
    plugin_result = self._detect_from_plugins()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/environment.py", line 128, in _detect_from_plugins
    "environment data from plugin {}".format(implementation._identifier),
AttributeError: 'PiSupportPlugin' object has no attribute '_identifier'
2019-08-15 18:29:45,098 - octoprint.environment - ERROR - Error logging detected environment
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/environment.py", line 142, in log_detected_environment
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/environment.py", line 157, in _format
    return u"Detected environment is Python {} under {} ({}). Details:\n{}".format(environment["python"]["version"],
KeyError: 'python'

2019-08-15 18:30:29,385 - octoprint.plugins.astroprint - ERROR - Error getting camera status: HTTPConnectionPool(host='', port=8080): Max retries exceeded with url: /?action=snapshot (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x68f79690>: Failed to establish a new connection: [Errno 111] Connection refused',))
2019-08-15 19:42:47,910 - octoprint.plugins.astroprint - INFO - There was an error loading /home/pi/.octoprint/data/astroprint/print_files.yaml:
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint_astroprint/AstroprintDB.py", line 49, in getPrintFiles
    with open(self.infoPrintFiles, "r") as f:
IOError: [Errno 2] No such file or directory: '/home/pi/.octoprint/data/astroprint/print_files.yaml'

2019-08-16 08:39:48,801 - octoprint - ERROR - Exception on /plugin/astroprint/initialstate [GET]
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask/app.py", line 1817, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask/app.py", line 1477, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask/app.py", line 1381, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask/app.py", line 1475, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask/app.py", line 1461, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/flask_principal.py", line 199, in _decorated
    rv = f(*args, **kw)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint_astroprint/__init__.py", line 422, in initialstate
    "connected" : True if self.cameraManager.cameraActive else False,
AttributeError: 'NoneType' object has no attribute 'cameraActive'

2019-08-16 09:50:31,155 - octoprint.util.comm - ERROR - Unexpected error while reading from serial port
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/comm.py", line 2739, in _readline
    ret = self._serial.readline()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/comm.py", line 4844, in readline
    c = self.read(1)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/serial/serialposix.py", line 501, in read
    'device reports readiness to read but returned no data '
SerialException: device reports readiness to read but returned no data (device disconnected or multiple access on port?)

So, you need a more powerful power supply.
Check your Klipper installation.
Disable the astroprint plugin.


Yeah, I have that since the beginning of my OP installation but ignored it since I have an official RPI Power supply with the 3b+ running ..

I've deinstalled the Astroprint and Octoklipper plugin and it works again, but within the octoklipper reinstallation I got an error with pip. Have to invest some time on this. Anyway thanks alot!

Maybe you should rma your power supply if you still have warranty
If I remember correctly the undervoltage warning starts at 4.6V and less.

Doesn't it depend on the ampere even more?

But the Key problem on my Raspi is rather the fact that pip throws an error after the Octoklipper installation even tho I install it via the UI. After the attempt to install the Binding I get an 500 - internal Server error and the UI and a SSH connection via Putty isn't reachable anymore.
That's weird

Indirectly. The less power a power supply provides, the higher is the inner resistance.
The more power the Pi needs, the lower is the inner resistance. Optimal is when both inner resistance would be the same, but rarley happen.
When the Pi sucks more Amperes than the PS can provide, the Voltage drops.
For it is more easy to measure the Voltage than the Current, it is done that way.


Allright makes sense yeah

Having problems with Safe Mode and Astroprint as well.
As soon as I install the plugin the rpi boots in safe mode.

Thanks for this, I moved my printer and used a random usb plug I had laying around. I kept getting the safe mode message and I searched online. Yours is the second post I found and sure enough, it was an old 1A charger. I put in a newer one and the message went away. Thanks again.

1 Like