Octoprint will not start after canceling a print

Im not really sure where to start with this one.

So everything was fine until I canceled a print so I could start another. After I confirmed to cancel it just froze. I rebooted the octoprint and the printer and when it came back I got an error saying octoprint couldnt connect to the printer. I dont remember the exact error it just wasnt talking to my Prusa Mk3.

I checked for updated and there was one 1.3.1 I think. I updated it and restarted it. Nothing.

I can SSH into it and it seems to still be stuck on the last print. I tried to Sudo restart and now all I see is the " The OctoPrint server is currently not running" I can still SSH but Im not sure what to do next.

Below is whats displayed for the last few things I tried.

Preformatted textpi@octopi2:~ ps -ef | grep -i octoprint | grep -i python pi 639 1 40 00:39 ? 00:15:29 /home/pi/oprint/bin/python2 -m o ctoprint analysis gcode --speed-x=10200 --speed-y=10200 --max-t=10 --throttle=0. 01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_ MK3.gcode pi 1000 1 25 00:51 ? 00:06:47 /home/pi/oprint/bin/python2 -m o ctoprint analysis gcode --speed-x=10200 --speed-y=10200 --max-t=10 --throttle=0. 01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_ MK3.gcode pi 1254 1 21 01:04 ? 00:02:50 /home/pi/oprint/bin/python2 /hom e/pi/oprint/bin/octoprint serve --host=127.0.0.1 --port=5000 pi 1346 1254 11 01:07 ? 00:01:10 /home/pi/oprint/bin/python2 -m o ctoprint analysis gcode --speed-x=10200 --speed-y=10200 --max-t=10 --throttle=0. 01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_ MK3.gcode pi@octopi2:~ sudo service octoprint restart
pi@octopi2:~ ps -ef | grep -i octoprint | grep -i python pi 639 1 39 00:39 ? 00:16:16 /home/pi/oprint/bin/python2 -m octoprint analysis gcode --speed-x=10200 --speed-y=1 0200 --max-t=10 --throttle=0.01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_MK3.gcode pi 1000 1 26 00:51 ? 00:07:34 /home/pi/oprint/bin/python2 -m octoprint analysis gcode --speed-x=10200 --speed-y=1 0200 --max-t=10 --throttle=0.01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_MK3.gcode pi 1346 1 12 01:07 ? 00:01:31 /home/pi/oprint/bin/python2 -m octoprint analysis gcode --speed-x=10200 --speed-y=1 0200 --max-t=10 --throttle=0.01 --throttle-lines=100 /home/pi/.octoprint/uploads/8mm/Super8-48pcs_0.15mm_PET_MK3.gcode pi 1676 1 25 01:20 ? 00:00:05 /home/pi/oprint/bin/python2 /home/pi/oprint/bin/octoprint serve --host=127.0.0.1 -- port=5000 pi@octopi2:~ ~/.octoprint/logs/octoprint.log
-bash: /home/pi/.octoprint/logs/octoprint.log: Permission denied
pi@octopi2:~ $ sudo service octoprint restartPreformatted text

You might also try shutting down the Raspberry (by remoting into it and running sudo poweroff), turn off the printer then turn on the printer and unplug/replug the power for the Pi.

I tried that a few times. Last time it came on for a second then the server disconnected again. I did "sudo shutdown -r now" turned off the printer, unplugged and plugged back and restated and got the error below.

"Looks like something went wrong during startup, the server is gone again. You should check octoprint.log ."

Well I finally got back to the terminal but I still cant connect to the printer. I get this as the error.

"Unexpected error while connecting to serial port: /dev/ttyAMA0 SerialException: '[Errno 11] Could not exclusively lock port /dev/ttyAMA0: [Errno 11] Resource temporarily unavailable' @ comm.py:_openSerial:2611 (hook default)"

Disconnect the printer and see if OctoPrint will at least load. Try to start it in Safe Mode as well.