OctoPrint Directory doesn't exist even though it list in with DIR command

Hi All,

Brand new user, falling at the first hurdle...

I have just setup installed Octopi onto a Raspberry Pi 1 Model B that i had laying around
I can ping it on the network and I can SSH into it.

I followed the 'Getting started with OctoPrint on the Raspberry Pi 1, 2 and 3!' video on you tube and expanded the filesystem to use the whole SD card.
Basically I got up to 7mins31secs in the video.

When I now enter the ip address of the pi into my web browser i get an error screen saying ' The OctoPrint server is currently not running'

I can't see the log file because the OctoPrint directory doesn't exist even though it lists it with DIR command.

how can the directory appear in the DIR command but the CD command doesn't let me navigate to it (it does let me navigate to the other directories in the same root?

Cheers

Steve

Hi @megamef!

octoprint is a hidden folder. Try ls -a instead of DIR.
Hidden folders and files start with a .

1 Like

Thanks for the quick reply. Yep I can see more directories now, the OctoPrint directory (along with the others I could see before) is blue but i still can't navigate to it because it says it doesn't exist so i still can't get to the log file. :disappointed:

Octopi_Error

The name is .octoprint, not octoprint. Try cd .octoprint.

2 Likes

Ok I replied too quickly! I see the actual directory is .octoprint not octoprint (very sneaky). So I've found the log and I'm posting it below. It doesn't make sense to me but hopefully someone smarter than me can tell me where I'm going wrong...

Can you send the entire log file? The details may be hidden lower down and we can't see.

2019-04-11 11:40:21,556 - octoprint.startup - INFO - ******************************************************************************
2019-04-11 11:40:21,568 - octoprint.startup - INFO - Starting OctoPrint 1.3.10
2019-04-11 11:40:21,572 - octoprint.startup - INFO - ******************************************************************************
2019-04-11 11:40:30,334 - octoprint.plugin.core - INFO - Loading plugins from /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins, /home/pi/.octoprint/plugins and installed plugin packages...
2019-04-11 11:40:44,048 - octoprint.plugin.core - INFO - Found 15 plugin(s) providing 15 mixin implementations, 17 hook handlers
2019-04-11 11:40:44,656 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval
2019-04-11 11:40:45,177 - octoprint.server - INFO - Intermediary server started
2019-04-11 11:40:45,190 - octoprint.plugin.core - INFO - Loading plugins from /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins, /home/pi/.octoprint/plugins and installed plugin packages...
2019-04-11 11:40:49,989 - octoprint.plugin.core - INFO - Found 15 plugin(s) providing 15 mixin implementations, 17 hook handlers
2019-04-11 11:40:50,005 - octoprint.printer.profile - ERROR - Profile _default does not exist, creating _default again and setting it as default
2019-04-11 11:40:51,063 - octoprint.filemanager.storage - INFO - Initializing the file metadata for /home/pi/.octoprint/uploads...
2019-04-11 11:40:51,076 - octoprint.filemanager.storage - INFO - ... file metadata for /home/pi/.octoprint/uploads initialized successfully.
2019-04-11 11:40:56,058 - octoprint.util.pip - ERROR - Error while discovering pip command
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 148, in trigger_refresh
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 181, in _setup_pip
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 435, in _get_pip_command
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 254, in autodetect_pip
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1462, in run
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1071, in run
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1187, in run_node
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1333, in run_command_node
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 655, in run
  File "/usr/lib/python2.7/subprocess.py", line 390, in __init__
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 567, in _execute_child
  File "/usr/lib/python2.7/subprocess.py", line 1023, in _execute_child
  File "/usr/lib/python2.7/pickle.py", line 1388, in loads
  File "/usr/lib/python2.7/pickle.py", line 864, in load
  File "/usr/lib/python2.7/pickle.py", line 977, in load_string
  File "/home/pi/oprint/lib/python2.7/encodings/__init__.py", line 100, in search_function
  File "/home/pi/oprint/lib/python2.7/encodings/string_escape.py", line 1
SyntaxError: Non-ASCII character '\xf6' in file /home/pi/oprint/lib/python2.7/encodings/string_escape.py on line 1, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details
2019-04-11 11:40:56,135 - octoprint.plugin.core - INFO - Initialized 15 plugin implementation(s)
2019-04-11 11:40:56,960 - octoprint.plugin.core - INFO - 15 plugin(s) registered with the system:
|  Action Command Prompt Support (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/action_command_prompt
|  Announcement Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/announcements
|  Anonymous Usage Tracking (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/tracking
|  Application Keys Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/appkeys
|  Backup & Restore (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/backup
|  Core Wizard (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/corewizard
|  CuraEngine (<= 15.04) (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/cura
|  Discovery (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/discovery
|  Force Login (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/forcelogin
|  Logging (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/logging
|  Pi Support Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/pi_support
|  Plugin Manager (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/pluginmanager
|  Printer Safety Check (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/printer_safety_check
|  Software Update (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/softwareupdate
|  Virtual Printer (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/virtual_printer
2019-04-11 11:40:57,094 - octoprint.environment - INFO - Detected environment is Python 2.7.13 under Linux (linux2). Details:
|  hardware:
|    cores: 1
|    freq: 700.0
|    ram: 388001792
|  os:
|    id: linux
|    platform: linux2
|  plugins:
|    pi_support:
|      model: Raspberry Pi Model B Rev 2
|      octopi_version: tnuvntN
|  python:
|    pip: 19.0.1
|    version: 2.7.13
|    virtualenv: /home/pi/oprint
2019-04-11 11:40:57,147 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/webassets...
2019-04-11 11:40:57,157 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/.webassets-cache...
2019-04-11 11:40:59,369 - octoprint.server - INFO - Shutting down intermediary server...
2019-04-11 11:40:59,824 - octoprint.server - INFO - Intermediary server shut down
2019-04-11 11:40:59,841 - octoprint.events - INFO - Processing startup event, this is our first event
2019-04-11 11:40:59,853 - octoprint.events - INFO - Adding 0 events to queue that were held back before startup event
2019-04-11 11:40:59,876 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...
2019-04-11 11:40:59,898 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue
2019-04-11 11:41:00,012 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi' for _http._tcp
2019-04-11 11:41:00,096 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi' for _octoprint._tcp
2019-04-11 11:41:00,121 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on octopi for SSDP
2019-04-11 11:41:00,307 - octoprint.server - INFO - Listening on http://127.0.0.1:5000
2019-04-11 11:41:01,908 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from https://plugins.octoprint.org/plugins.json
2019-04-11 11:41:03,692 - octoprint.plugins.announcements - INFO - Loaded channel _important from https://octoprint.org/feeds/important.xml in 3.1s
2019-04-11 11:41:11,103 - octoprint.plugins.announcements - INFO - Loaded channel _releases from https://octoprint.org/feeds/releases.xml in 1.2s
2019-04-11 11:41:11,956 - octoprint.util.pip - ERROR - Error while discovering pip command
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 148, in trigger_refresh
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 181, in _setup_pip
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 435, in _get_pip_command
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/pip.py", line 254, in autodetect_pip
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1462, in run
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1071, in run
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1187, in run_node
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 1333, in run_command_node
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/fixes.py", line 24, in decorated_function
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 655, in run
  File "/usr/lib/python2.7/subprocess.py", line 390, in __init__
  File "/home/pi/oprint/local/lib/python2.7/site-packages/sarge/__init__.py", line 567, in _execute_child
  File "/usr/lib/python2.7/subprocess.py", line 1023, in _execute_child
  File "/usr/lib/python2.7/pickle.py", line 1388, in loads
  File "/usr/lib/python2.7/pickle.py", line 864, in load
  File "/usr/lib/python2.7/pickle.py", line 977, in load_string
  File "/home/pi/oprint/lib/python2.7/encodings/__init__.py", line 100, in search_function
  File "/home/pi/oprint/lib/python2.7/encodings/string_escape.py", line 1
SyntaxError: Non-ASCII character '\xf6' in file /home/pi/oprint/lib/python2.7/encodings/string_escape.py on line 1, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details
2019-04-11 11:41:12,083 - octoprint.plugin - ERROR - Error while calling plugin softwareupdate
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/plugin/__init__.py", line 230, in call_plugin
    except Exception as exc:
  File "/home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 102, in on_after_startup
    self._check_environment()
  File "/home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 188, in _check_environment
    and get_comparable_version(versions["pip"]) >= get_comparable_version(MINIMUM_PIP)
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/util/version.py", line 121, in get_comparable_version
    if "-" in version_string:
TypeError: argument of type 'NoneType' is not iterable
2019-04-11 11:41:13,772 - octoprint.plugins.announcements - INFO - Loaded channel _blog from https://octoprint.org/feeds/octoblog.xml in 0.79s
2019-04-11 11:41:14,068 - octoprint.plugins.pluginmanager - INFO - Loaded plugin notices data from https://plugins.octoprint.org/notices.json
2019-04-11 11:41:15,004 - octoprint.plugins.announcements - INFO - Loaded channel _plugins from https://plugins.octoprint.org/feed.xml in 0.51s
2019-04-11 11:41:16,446 - octoprint.plugins.announcements - INFO - Loaded channel _octopi from https://octoprint.org/feeds/octopi.xml in 0.5s
2019-04-11 11:55:44,676 - octoprint.server.heartbeat - INFO - Server heartbeat <3
2019-04-11 11:57:58,866 - octoprint.server - INFO - Shutting down...
2019-04-11 11:57:58,968 - octoprint.events - INFO - Processing shutdown event, this will be our last event
2019-04-11 11:57:59,037 - octoprint.events - INFO - Event loop shut down
2019-04-11 11:57:59,277 - octoprint.server - INFO - Goodbye!


Sorry, took me a while to figure out how to select all the text and copy it

2019-04-11 11:41:00,307 - octoprint.server - INFO - Listening on http://127.0.0.1:5000

Oh noes. Why is is listening on the internal ip address? Did you skip a step? Are you using the wifi interface or ethernet?

1 Like

That's normal on OctoPi since that comes with a reverse proxy in front.

SyntaxError: Non-ASCII character '\xf6' in file /home/pi/oprint/lib/python2.7/encodings/string_escape.py on line 1, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details

This however is not normal. Is that a fresh install? That's very unusual.

octopi_version: tnuvntN

This even more so. Where did you get that image? Either it's not an official OctoPi release, or the flash has become corrupted or the SD card is broken.

2019-04-11 11:57:58,866 - octoprint.server - INFO - Shutting down...

Well, the server is indeed not running, it was shut down gracefully. Why isn't visible from the log though, thoug with the odd other entries and especially that nonsensical OctoPi version I'd say - download a fresh image and reflash.

2 Likes

It comes with a reverse proxy? Is that on by default?

Yes, if it wasn't no OctoPi installation out there would work :wink:

Ok i've completed reinstalled from a formatted SD card and it's the same except now I actually get:
pi 326 1 35 16:41 ? 00:00:46 /home/pi/oprint/bin/python2 /home/pi/oprint/bin/octoprint serve --host=127.0.0.1 --port=5000
back when i type:
ps -ef | grep -i octoprint | grep -i python
I've tried retarting the service as well with:
sudo service octoprint restart
but still no joy

Then share a new log please.

There are times when Notepad++ accidentally replaces the first character of a file with that character if the encoding is incorrectly set, for what it's worth. Although Notepad++ probably wasn't involved, it could be a similar problem if the encoding isn't correct.

Technically, I think the ΓΆ is this character if seen by itself.

Sorry for the distraction, but the original problem seemed interesting to me.

1 Like