Setting up OctoPrint on a Raspberry Pi running Raspberry Pi OS (Debian)

https://docs.octoprint.org/en/master/configuration/config_yaml.html

@user8374585 Works great, thanks for that.

I've followed the tutorial and when I run the serve command this is the last I see:

2020-10-29 00:22:59,937 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/webassets...

2020-10-29 00:22:59,938 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/.webassets-cache...

2020-10-29 00:23:00,636 - octoprint.server - INFO - Shutting down intermediary server...

2020-10-29 00:23:00,773 - octoprint.server - INFO - Intermediary server shut down

2020-10-29 00:23:00,775 - octoprint.events - INFO - Processing startup event, this is our first event

2020-10-29 00:23:00,776 - octoprint.events - INFO - Adding 0 events to queue that were held back before startup event

2020-10-29 00:23:00,779 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...

2020-10-29 00:23:00,783 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder...

2020-10-29 00:23:00,798 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue

2020-10-29 00:23:00,809 - octoprint.server.util.watchdog - INFO - ... initial scan done.

2020-10-29 00:23:00,839 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on raspberrypi for SSDP

I'm assuming it's supposed to be running, but when I go to 127.0.0.1:5000 or http://raspberrypi:5000/ the browser just keeps loading forever and nothing happens.

Updated 2020-11-03 to use Python 3 instead of 2 for installation.

3 Likes

shouldn't this be
python3 -m venv venv
to properly use python 3 instead of defaulting back to python 2?

You are right, I thought I'd added the --python=python3 to it, but yes by default that will create the venv using Py2. Will have to test it later today, to make sure there are no extra dependency steps etc.

Post has been updated to address this issue, now uses venv

1 Like

Having done an absolute **** tonne of research and work on this, I finally got the correct info to get RPi_Cam_Web_Interface working with Octoprint :smiley:

Install settings for RPi_Cam_Web_Interface:

Cam subfolder: html
Autostart: yes
Server: nginx
Webport: 8080
User: Your username here
Password: your password here
jpglink: yes
php: 7.3

Webcam settings for Octoprint:

Stream url: http://your ip here/html/cam_pic_new.php
Snapshot url: http://your ip here/html/cam.jpg
Path to FFMPEG: /usr/bin/ffmpeg

The main benefit of this is being able to have security on the camera feed.

I've not actually done a build yet to test these (still building my printer) but if someone could test? Everything looks fine from Octoprint settings but the proof is in the pudding so to speak.

1 Like

So stumbled across this in a forum.
Alot cooler than i thought.

Wondering if anyones used it in ubuntu or on android os?

I have an older UDOO board i would like to apply to my workspace. Has lvds and camera support.

Ubuntu is easy, pretty much just substitute the user pi for whatever you setup on ubuntu. Can't commend on android OS.

Hi.
I've installed OctoPrint on Raspbian OS Desktop and all seems to work fine, but when I go to Pluguin manager says:

The pip command could not be found or does not work correctly for this installation of OctoPrint - please consult the log file for details and if necessary configure it manually. No installation and uninstallation of plugin packages is possible while pip is unavailable.

I've checked python2 and python3 and both have pip installed. Any idea?

PS: I want to say thanks who updated this installation guide.

1 Like

Are there any details to be found here? Please upload the octoprint.log.

Here you have..

octoprint.log
2021-02-19 17:32:27,750 - octoprint.startup - INFO - ******************************************************************************
2021-02-19 17:32:27,751 - octoprint.startup - INFO - Starting OctoPrint 1.5.3
2021-02-19 17:32:27,751 - octoprint.startup - INFO - ******************************************************************************
2021-02-19 17:32:27,900 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity changed from offline to online
2021-02-19 17:32:27,982 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity state is currently: online
2021-02-19 17:32:27,982 - octoprint.util.connectivity.connectivity_checker - INFO - Connecting to 8.8.8.8:53 is working
2021-02-19 17:32:27,982 - octoprint.util.connectivity.connectivity_checker - INFO - Resolving octoprint.org is working
2021-02-19 17:32:28,299 - octoprint.startup - INFO - Blacklist processing done, adding 12 blacklisted plugin versions: roomtemp (any), GcodeEditor (0.1.1), GcodeEditor (0.2.0), GcodeEditor (0.2.1), GcodeEditor (0.2.2), GcodeEditor (0.2.3), GcodeEditor (0.2.4), GcodeEditor (0.2.5), GcodeEditor (0.2.6), GcodeEditor (0.2.8), gcodeleveling (0.1.0), gcodeleveling (0.1.1)
2021-02-19 17:32:28,306 - octoprint.plugin.core - INFO - Loading plugins from /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins, /home/pi/.octoprint/plugins and installed plugin packages...
2021-02-19 17:32:28,467 - octoprint.plugin.core - INFO - Plugin Pi Support Plugin did not pass check, not loading.
2021-02-19 17:32:28,496 - octoprint.startup - INFO - Added settings overlay from plugin firmware_check
2021-02-19 17:32:28,496 - octoprint.plugin.core - INFO - Found 16 plugin(s) providing 16 mixin implementations, 32 hook handlers
2021-02-19 17:32:28,517 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval
2021-02-19 17:32:28,519 - octoprint.server - INFO - Intermediary server started
2021-02-19 17:32:28,522 - octoprint.filemanager.storage - INFO - Initializing the file metadata for /home/pi/.octoprint/uploads...
2021-02-19 17:32:28,523 - octoprint.filemanager.storage - INFO - ... file metadata for /home/pi/.octoprint/uploads initialized successfully.
2021-02-19 17:32:28,523 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_SHOW (needs: "Need(method='role', value='plugin_action_command_notification_show')")
2021-02-19 17:32:28,523 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_CLEAR (needs: "Need(method='role', value='plugin_action_command_notification_clear')")
2021-02-19 17:32:28,523 - octoprint.server - INFO - Added new permission from plugin action_command_prompt: PLUGIN_ACTION_COMMAND_PROMPT_INTERACT (needs: "Need(method='role', value='plugin_action_command_prompt_interact')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_READ (needs: "Need(method='role', value='plugin_announcements_read')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_MANAGE (needs: "Need(method='role', value='plugin_announcements_manage'), Need(method='role', value='plugin_announcements_read')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_ADMIN (needs: "Need(method='role', value='plugin_appkeys_admin')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin backup: PLUGIN_BACKUP_ACCESS (needs: "Need(method='role', value='plugin_backup_access')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin firmware_check: PLUGIN_FIRMWARE_CHECK_DISPLAY (needs: "Need(method='role', value='plugin_firmware_check_display')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin logging: PLUGIN_LOGGING_MANAGE (needs: "Need(method='role', value='plugin_logging_manage')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_MANAGE (needs: "Need(method='role', value='plugin_pluginmanager_manage')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_INSTALL (needs: "Need(method='role', value='plugin_pluginmanager_manage'), Need(method='role', value='plugin_pluginmanager_install')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CHECK (needs: "Need(method='role', value='plugin_softwareupdate_check')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_UPDATE (needs: "Need(method='role', value='plugin_softwareupdate_update')")
2021-02-19 17:32:28,524 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CONFIGURE (needs: "Need(method='role', value='plugin_softwareupdate_configure')")
2021-02-19 17:32:28,538 - octoprint.plugins.softwareupdate - INFO - Loaded version cache from disk
2021-02-19 17:32:29,377 - octoprint.util.pip - INFO - Using "/home/pi/OctoPrint/venv/bin/python3 -m pip" as command to invoke pip
2021-02-19 17:32:30,181 - octoprint.util.pip - INFO - Version of pip is 18.1
2021-02-19 17:32:30,181 - octoprint.util.pip - INFO - pip installs to /home/pi/OctoPrint/venv/lib/python3.7/site-packages (writable -> no), --user flag needed -> no, virtual env -> yes
2021-02-19 17:32:30,182 - octoprint.util.pip - INFO - ==> pip ok -> NO!
2021-02-19 17:32:30,182 - octoprint.util.pip - ERROR - Cannot use this pip install, can't write to the install dir and also can't use --user for installing. Check your setup and the permissions on /home/pi/OctoPrint/venv/lib/python3.7/site-packages.
2021-02-19 17:32:30,189 - octoprint.plugin.core - INFO - Initialized 16 plugin implementation(s)
2021-02-19 17:32:30,191 - octoprint.plugin.core - INFO - 16 plugin(s) registered with the system:
|  Action Command Notification Support (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/action_command_notification
|  Action Command Prompt Support (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/action_command_prompt
|  Announcement Plugin (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/announcements
|  Anonymous Usage Tracking (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/tracking
|  Application Keys Plugin (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/appkeys
|  Backup & Restore (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/backup
|  Core Wizard (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/corewizard
|  Discovery (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/discovery
|  Error Tracking (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/errortracking
|  File Check (2020.8.7) (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint_file_check
|  Firmware Check (2021.2.4) (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint_firmware_check
|  GCode Viewer (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/gcodeviewer
|  Logging (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/logging
|  Plugin Manager (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/pluginmanager
|  Software Update (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate
|  Virtual Printer (bundled) = /home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/virtual_printer
Prefix legend: ! = disabled, # = blacklisted, * = incompatible
2021-02-19 17:32:30,275 - octoprint.environment - INFO - Detected environment is Python 3.7.3 under Linux (linux). Details:
|  hardware:
|      cores: 4
|      freq: 3600.0
|      ram: 4053127168
|  os:
|      bits: 32
|      id: linux
|      platform: linux
|  python:
|      pip: '18.1'
|      version: 3.7.3
|      virtualenv: /home/pi/OctoPrint/venv
2021-02-19 17:32:30,280 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/webassets...
2021-02-19 17:32:30,286 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/.webassets-cache...
2021-02-19 17:32:30,380 - octoprint.server - INFO - Shutting down intermediary server...
2021-02-19 17:32:30,501 - octoprint.server - INFO - Intermediary server shut down
2021-02-19 17:32:30,502 - octoprint.events - INFO - Processing startup event, this is our first event
2021-02-19 17:32:30,502 - octoprint.events - INFO - Adding 1 events to queue that were held back before startup event
2021-02-19 17:32:30,502 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...
2021-02-19 17:32:30,507 - octoprint.plugins.softwareupdate - INFO - Fetching check overlays from https://plugins.octoprint.org/update_check_overlay.json
2021-02-19 17:32:30,508 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder...
2021-02-19 17:32:30,508 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue
2021-02-19 17:32:30,517 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2021-02-19 17:32:30,528 - octoprint.server.util.watchdog - INFO - ... initial scan done.
2021-02-19 17:32:30,721 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2021-02-19 17:32:31,359 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on raspberry._http._tcp.local.' for _http._tcp.local.
2021-02-19 17:32:32,166 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on raspberry._octoprint._tcp.local.' for _octoprint._tcp.local.
2021-02-19 17:32:32,169 - octoprint.server - INFO - Listening on http://0.0.0.0:5000 and http://[::]:5000
2021-02-19 17:32:32,169 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on raspberry for SSDP
2021-02-19 17:32:32,187 - octoprint.server.util.sockjs - INFO - New connection from client: 192.168.1.80
2021-02-19 17:32:32,204 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2021-02-19 17:32:32,238 - octoprint.server.util.flask - INFO - Passively logging in user Adri from 192.168.1.80
2021-02-19 17:32:32,239 - octoprint.access.users - INFO - Logged in user: Adri
2021-02-19 17:32:32,701 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2021-02-19 17:32:33,176 - octoprint.util.pip - INFO - Using "/home/pi/OctoPrint/venv/bin/python3 -m pip" as command to invoke pip
2021-02-19 17:32:33,177 - octoprint.util.pip - INFO - pip installs to /home/pi/OctoPrint/venv/lib/python3.7/site-packages (writable -> no), --user flag needed -> no, virtual env -> yes
2021-02-19 17:32:33,177 - octoprint.util.pip - INFO - ==> pip ok -> NO!
2021-02-19 17:32:33,177 - octoprint.util.pip - ERROR - Cannot use this pip install, can't write to the install dir and also can't use --user for installing. Check your setup and the permissions on /home/pi/OctoPrint/venv/lib/python3.7/site-packages.
2021-02-19 17:32:33,177 - octoprint.plugin - ERROR - Error while calling plugin softwareupdate
Traceback (most recent call last):
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugin/__init__.py", line 271, in call_plugin
    result = getattr(plugin, method)(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/util/__init__.py", line 1890, in wrapper
    return f(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 172, in on_after_startup
    self._check_environment()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 310, in _check_environment
    and get_comparable_version(versions["pip"])
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/util/version.py", line 158, in get_comparable_version
    if "-" in version_string:
TypeError: argument of type 'NoneType' is not iterable
2021-02-19 17:32:33,196 - octoprint.server.preemptive_cache - INFO - Preemptively caching / (ui _default) for {'base_url': 'http://192.168.1.80:5000/', 'path': '/', 'query_string': 'l10n=en'}
2021-02-19 17:32:34,387 - octoprint.server.preemptive_cache - INFO - ... done in 1.19s
2021-02-19 17:32:34,387 - octoprint.server.preemptive_cache - INFO - Preemptively caching / (ui _default) for {'base_url': 'http://localhost:5000/', 'path': '/', 'query_string': 'l10n=en'}
2021-02-19 17:32:34,433 - octoprint.server.preemptive_cache - INFO - ... done in 0.05s
2021-02-19 17:33:02,867 - octoprint - ERROR - Exception on /plugin/softwareupdate/check [GET]
Traceback (most recent call last):
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 2447, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1952, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1821, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/_compat.py", line 39, in reraise
    raise value
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1950, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1936, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/server/util/flask.py", line 1539, in decorated_view
    return func(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/access/permissions.py", line 183, in _decorated
    rv = f(*args, **kw)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 1057, in check_for_update
    )(view)()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/server/util/flask.py", line 1306, in decorated_function
    response = f(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 946, in view
    data = self._storage_info.get(key)
AttributeError: 'SoftwareUpdatePlugin' object has no attribute '_storage_info'
2021-02-19 17:33:02,872 - tornado.access - ERROR - 500 GET /plugin/softwareupdate/check (192.168.1.80) 30100.67ms
2021-02-19 17:33:02,980 - octoprint.server.util.sockjs - INFO - User Adri logged in on the socket from client 192.168.1.80
2021-02-19 17:33:14,890 - octoprint.server.util.flask - INFO - Passively logging in user Adri from 192.168.1.80
2021-02-19 17:33:14,890 - octoprint.access.users - INFO - Logged in user: Adri
2021-02-19 17:33:14,927 - octoprint.server.util.sockjs - INFO - Client connection closed: 192.168.1.80
2021-02-19 17:33:16,410 - octoprint.server.util.sockjs - INFO - New connection from client: 192.168.1.80
2021-02-19 17:33:16,427 - octoprint.server.util.flask - INFO - Passively logging in user Adri from 192.168.1.80
2021-02-19 17:33:16,427 - octoprint.access.users - INFO - Logged in user: Adri
2021-02-19 17:33:17,145 - octoprint.server.util.sockjs - INFO - User Adri logged in on the socket from client 192.168.1.80
2021-02-19 17:33:47,276 - octoprint - ERROR - Exception on /plugin/softwareupdate/check [GET]
Traceback (most recent call last):
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 2447, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1952, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1821, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/_compat.py", line 39, in reraise
    raise value
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1950, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/flask/app.py", line 1936, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/server/util/flask.py", line 1539, in decorated_view
    return func(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/access/permissions.py", line 183, in _decorated
    rv = f(*args, **kw)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 1057, in check_for_update
    )(view)()
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/server/util/flask.py", line 1306, in decorated_function
    response = f(*args, **kwargs)
  File "/home/pi/OctoPrint/venv/lib/python3.7/site-packages/octoprint/plugins/softwareupdate/__init__.py", line 946, in view
    data = self._storage_info.get(key)
AttributeError: 'SoftwareUpdatePlugin' object has no attribute '_storage_info'
2021-02-19 17:33:47,280 - tornado.access - ERROR - 500 GET /plugin/softwareupdate/check (192.168.1.80) 30098.13ms

I fixed the problem as I seen the log.

chwon -R pi OctoPrint

Thanks!

1 Like

I'm setting this up on a debian linux laptop, so I'm not using a Pi. I'm providing this info for others if they run into this issue.

I had issues with the haproxy configuration since things apparently change after a certain version. I'm running version 2.2.9-1

While this probably doesn't affect the Pi, it might eventually.

I got these warnings and errors:

[WARNING] 051/085546 (3107) : unexpected character 'i' after the timer value '15min', only (us=microseconds,ms=milliseconds,s=seconds,m=minutes,h=hours,d=days) are supported. This will be reported as an error in next versions.
[WARNING] 051/085546 (3107) : unexpected character 'i' after the timer value '15min', only (us=microseconds,ms=milliseconds,s=seconds,m=minutes,h=hours,d=days) are supported. This will be reported as an error in next versions.
[NOTICE] 051/085546 (3107) : haproxy version is 2.2.9-1
[NOTICE] 051/085546 (3107) : path to executable is /usr/sbin/haproxy
[ALERT] 051/085546 (3107) : parsing [/etc/haproxy/haproxy.cfg:28] : The 'reqrep' directive is not supported anymore since HAProxy 2.1. Use 'http-request replace-path', 'http-request replace-uri' or 'http-request replace-header' instead.
[ALERT] 051/085546 (3107) : parsing [/etc/haproxy/haproxy.cfg:33] : The 'reqrep' directive is not supported anymore since HAProxy 2.1. Use 'http-request replace-path', 'http-request replace-uri' or 'http-request replace-header' instead.
[ALERT] 051/085546 (3107) : Error(s) found in configuration file : /etc/haproxy/haproxy.cfg
[ALERT] 051/085546 (3107) : Fatal errors found in configuration.

I fixed it by changing the haproxy.cfg to:

global
        maxconn 4096
        user haproxy
        group haproxy
        daemon
        log 127.0.0.1 local0 debug

defaults
        log     global
        mode    http
        option  httplog
        option  dontlognull
        retries 3
        option redispatch
        option http-server-close
        option forwardfor
        maxconn 2000
        timeout connect 5s
        timeout client  15m
        timeout server  15m

frontend public
        bind :::80 v4v6
        use_backend webcam if { path_beg /webcam/ }
        default_backend octoprint

backend octoprint
        http-request replace-path ^([^\ :]*)\ /(.*)     \1\ /\2
        option forwardfor
        server octoprint1 127.0.0.1:5000

backend webcam
        http-request replace-path /webcam/(.*) /\1
        server webcam1  127.0.0.1:8080

I found these changes at Making OctoPi build on Ubuntu 64bit so we have 64bit builds Β· Issue #711 Β· guysoft/OctoPi Β· GitHub

I have installed OctoPrint according to the guide at the top of this page and everything appeared to go without any errors or warnings. I setup autostart according to the guide and the service starts on bootup and can be restarted, stopped and started by the appropriate commands. The only problem is when opening the web interface I get nothing. No feedback no nothing. It just times out. I have been using OctoPrint for 4 or 5 years and always installed from the octopi image. This time I did not want to erase my pi. The browser I am using is running another instance of OctoPrint on a seperate rPi. I am using winSCP and Putty to investigate as these are headless

The command "ps -ef | grep -i octoprint | grep -i python" returns:
pi 1966 101 4.3 144592 38796 ? Ssl 15:56 0:04 /home/pi/OctoPrint/venv/bin/python3 /home/pi/OctoPrint/venv/bin/octoprint
pi 1981 0.0 1.7 22644 15344 ? R 15:56 0:00 /home/pi/OctoPrint/venv/bin/python3 -m pip --version
The command "curl -D - localhost:5000" puts out more than 100 pages of HTML.

Hopefully someone may take a look at this info and be able to help an old man out. Thanks for any insight provided.

octoprint.log (117.4 KB)

I'm at the point where when I click Test for the Snapshot URL, I get a snapshot of what the webcam is seeing.

When I click Test for the Stream URL, however, I don't see what the webcam sees.

How would I go about fixing this :confused:

Thanks!

What URLs have you entered?

Stream URL: /webcam/?action=stream

Snapshot URL: http://127.0.0.1:8080/?action=snapshot

I'm running Octoprint, manual installation, on a Thinkpad running kubuntu. The camera is generic.

Thanks for the reply.

You probably need to check the haproxy section then, since the webcam URL is using that.

If you try http://your-ip:8080/?action=stream, it should work because this is not using haproxy. However, to avoid the port and make it relative you need that proxy section complete.

1 Like

So I put in the full link that you posted and now it's working.

http://192.168.1.3:8080/?action=stream

Thanks!