dw-0 / kiauh

Klipper Installation And Update Helper
GNU General Public License v3.0
3.4k stars 491 forks source link

Add warning/option when installing Crowsnest w/ mjpegstreamer in tandem #374

Closed wolfnacht44 closed 2 months ago

wolfnacht44 commented 1 year ago

Is your feature request related to a problem? Please describe

I didn't notice it, and realized ignorance with my issue at hand, during my migration to crowsnest from mjpeg-streamer initially mjpeg-streamer and crowsnest initially conflict upon installation enabling debug showed an issue with bind address, uninstalling mjpeg-streamer, or changing crowsnest port solved the issue

crowsnest: ERROR: Start of camera-streamer [cam rpi] failed! added for google crawlers

Describe the solution you'd like

  1. detection of mjpeg-streamer installation via kiauh.sh
  2. prompt "are you migrating from/to crowsnest/mjpeg-streamer"?
  3. prompt to auto uninstall crowsnest/mjpeg-streamer IF user responds [Y]es
  4. prompt WARNING stating conflict between the services if user enters [N]o - similar to installing fluidd/mainsail in tandem

Describe alternatives you've considered

Simply offering a Warning in place of the conflict described above Ability to prompt for port change in config when installing either service if conflict is detected( IF user enters No at point 2 or 3- I believe this would be more complex)

Additional information

mjpeg-streamer installed via kiuah.sh

had to enable debug level logging to find the root cause not realizing that Crowsnest and MJPEG-streamer were trying utilize the same port(8080)

Less knowledgeable users would be stuck on this particular issue when migrating or "testing" the different services in tandem, utilizing the script for its ease of use.

this is a thought I'd bring up incase there IS an issue with it in the future

verbose logging level tail in crowsnest

[08/22/23 11:39:16] crowsnest: INFO: Configuration of Section [cam rpi] looks good. Continue ... [08/22/23 11:39:18] crowsnest: Starting camera-streamer with Device /base/soc/i2c0mux/i2c@1/imx477@1a ... [08/22/23 11:39:18] crowsnest: ERROR: Start of camera-streamer [cam rpi] failed!

debug loging level tail in crowsnest

[08/22/23` 11:40:31] crowsnest: DEBUG: camera-streamer [cam rpi]: Parameters: --http-port=8080 --camera-path=/base/soc/i2c0mux/i2c@1/imx477@1a --camera-type=libcamera --camera-format=YUYV --camera-snapshot.height=1080 --camera-width=640 --camera-height=400 --camera-fps=15 --rtsp-port=8554 --camera-auto_reconnect=1 [08/22/23 11:40:32] crowsnest: DEBUG: camera-streamer [cam rpi]: bind: Address already in use [08/22/23 11:40:32] crowsnest: DEBUG: camera-streamer [cam rpi]: /home/pi/crowsnest/bin/camera-streamer/camera-streamer Version: (ef8f6a4) [08/22/23 11:40:32] crowsnest: DEBUG: camera-streamer [cam rpi]: xargs: /home/pi/crowsnest/bin/camera-streamer/camera-streamer: exited with status 255; aborting

dw-0 commented 2 months ago

The Crowsnest Installer will check for the conflict itself nowadays. Closing.