MotionEye on RasPi1 with BullsEye missing

Hello,
I want to install MotionEye on my RasPi1, but I can’t find the 136. What am I doing wrong?

  • Device model : RPi B (armv6l)

Many thanks and friendly greetings.

I guess it’s blocked on your device. Can be checked by running

dietpi-software list | grep 136

Hello,
I see:

DietPi v7.4.2 : 13:51 - Di 17.08.2021

  • Device model : RPi B (armv6l)


root@DietPi:~# dietpi-software list | grep 136
ID 136 | =0 | MotionEye: Web interface & surveillance for your camera | +FFmpeg +Build-Essential DISABLED for Debian bullseye | https://dietpi.com/docs/software/camera/#motioneye
root@DietPi:~#

What can be done?

Many thanks and greetings.

you are running the new Debian Bullseye image if I’m not mistaken and the software title is disabled.

DISABLED for Debian bullseye

Probably you would need to use Buster.

REMOVED OBSOLETE LINK

Same problem, why is motioneye disabled in bullseye?

Because it’s not yet supported?

MichaIng
I guess you know the exact reason

Time to fix this :wink:
But first let’s await the reason why it’s not supported yet.
I am on a Pi3B+ BTW.

Probably it’s Motioneye and not DietPi :wink:

It is disabled, since it requires the soon 2 years deprecated Python 2, while on Bullseye only Python 3 is shipped, and we won’t hack an insecure Python version back in.

I checked back, and while this is still true for the latest release and what pip/PyPI ships, at least there is a Python 3 branch now: https://github.com/ccrisan/motioneye/tree/python3

So while it may not be stable yet, but in theory pip can pull it from there directly. I also checked piwheels.org, and they list a wheel there, for “any” Python 3 version: https://piwheels.org/project/motioneye/
But the green batches are missing to indicate on which distro version it is functional :thinking:.

Time to retest :slight_smile:.

Ha! Now i remember the “old” python2 problem with motioneye!
Time to move to python3. :roll_eyes:
Tell me what to test and i test it. Maybe by PM?

@The_Raven:
Thanks for your support.

MichaIng
Can you give me a hint how to install Motioneye using python3?

MichaIng
I simply followed the install steps from our script on a RPi3B+ 32bit ARMv7 Bullseye.

root@DietPi3:~# pip3 install -U motioneye
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple/
Collecting motioneye
  Downloading https://www.piwheels.org/simple/motioneye/motioneye-0.42.1-py3-none-any.whl (792 kB)
     |████████████████████████████████| 792 kB 774 kB/s
Collecting jinja2
  Downloading https://www.piwheels.org/simple/jinja2/Jinja2-3.0.1-py3-none-any.whl (133 kB)
     |████████████████████████████████| 133 kB 1.5 MB/s
Collecting pillow
  Downloading https://www.piwheels.org/simple/pillow/Pillow-8.3.1-cp39-cp39-linux_armv7l.whl (1.1 MB)
     |████████████████████████████████| 1.1 MB 791 kB/s
Collecting pycurl
  Downloading https://www.piwheels.org/simple/pycurl/pycurl-7.44.1-cp39-cp39-linux_armv7l.whl (286 kB)
     |████████████████████████████████| 286 kB 1.5 MB/s
Collecting tornado<6,>=3.1
  Downloading https://www.piwheels.org/simple/tornado/tornado-5.1.1-cp39-cp39-linux_armv7l.whl (457 kB)
     |████████████████████████████████| 457 kB 763 kB/s
Collecting MarkupSafe>=2.0
  Downloading https://www.piwheels.org/simple/markupsafe/MarkupSafe-2.0.1-cp39-cp39-linux_armv7l.whl (25 kB)
Installing collected packages: MarkupSafe, tornado, pycurl, pillow, jinja2, motioneye
Successfully installed MarkupSafe-2.0.1 jinja2-3.0.1 motioneye-0.42.1 pillow-8.3.1 pycurl-7.44.1 tornado-5.1.1
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
root@DietPi3:~#

But service is not able to start at the end.

root@DietPi3:~# journalctl -u motioneye.service
-- Journal begins at Tue 2021-07-13 19:29:24 CEST, ends at Wed 2021-08-18 12:08:13 CEST. --
Aug 18 12:08:12 DietPi3 systemd[1]: Started motionEye Server.
Aug 18 12:08:12 DietPi3 meyectl[5519]: Traceback (most recent call last):
Aug 18 12:08:12 DietPi3 meyectl[5519]:   File "/usr/local/bin/meyectl", line 5, in <module>
Aug 18 12:08:12 DietPi3 meyectl[5519]:     from motioneye.meyectl import main
Aug 18 12:08:12 DietPi3 meyectl[5519]:   File "/usr/local/lib/python3.9/dist-packages/motioneye/meyectl.py", line 28, in <module>
Aug 18 12:08:12 DietPi3 meyectl[5519]:     import settings
Aug 18 12:08:12 DietPi3 meyectl[5519]: ModuleNotFoundError: No module named 'settings'
Aug 18 12:08:13 DietPi3 systemd[1]: motioneye.service: Main process exited, code=exited, status=1/FAILURE
Aug 18 12:08:13 DietPi3 systemd[1]: motioneye.service: Failed with result 'exit-code'.
root@DietPi3:~#

An issue someone already faced and reported on Motioneye GitHub https://github.com/ccrisan/motioneye/issues/1208#issuecomment-734874856

Answer from end of 2020

I did the Python 2 to 3 port, but I stopped with it (I don’t see a merge happen anytime soon)

More and more I remember this annoying thing with python2…
I think python2 has different syntaxes than python3. Because of this a py2 script does NOT work with py3.
There is a way to bring back py2 to bullseye, but it is absolutely the wrong way. The correct way is to move it to py3.

BTW: I hate python :face_with_raised_eyebrow:

Edit: Here is how to bring back pip2 to bullseye, but i am not sure if this source is trusty. https://blog.emacsos.com/pip2-in-debian-11-bullseye.html
Dirty if you ask me.

Honestly I don’t think we will bringt back Python2 on Bullseye. To bad that MotionEye is not working on the transition to Python3 :roll_eyes:


Anyway it’s working using Python2 on Bullseye

motion.service

● motion.service - Motion detection video capture daemon
     Loaded: loaded (/lib/systemd/system/motion.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2021-08-18 15:03:33 CEST; 52s ago
       Docs: man:motion(1)
   Main PID: 5940 (motion)
      Tasks: 4 (limit: 2178)
        CPU: 2.588s
     CGroup: /system.slice/motion.service
             └─5940 /usr/bin/motion

Aug 18 15:03:33 DietPi3 systemd[1]: Started Motion detection video capture daemon.
Aug 18 15:03:33 DietPi3 motion[5940]: [0:motion] [NTC] [ALL] conf_load: Processing thread 0 - config file /etc/motion/motion.conf
Aug 18 15:03:33 DietPi3 motion[5940]: [0:motion] [NTC] [ALL] conf_load: Processing thread 0 - config file /etc/motion/motion.conf
Aug 18 15:03:33 DietPi3 motion[5940]: [0:motion] [NTC] [ALL] motion_startup: Logging to file (/var/log/motion/motion.log)
Aug 18 15:03:33 DietPi3 motion[5940]: [0:motion] [NTC] [ALL] motion_startup: Logging to file (/var/log/motion/motion.log)

motioneye.service

 motioneye.service - motionEye Server
     Loaded: loaded (/etc/systemd/system/motioneye.service; disabled; vendor preset: enabled)
     Active: active (running) since Wed 2021-08-18 15:03:54 CEST; 30s ago
   Main PID: 5961 (meyectl)
      Tasks: 5 (limit: 2178)
        CPU: 2.192s
     CGroup: /system.slice/motioneye.service
             ├─5961 /usr/bin/python2 /usr/local/bin/meyectl startserver -c /etc/motioneye/motioneye.conf
             └─5972 /usr/bin/python2 /usr/local/bin/meyectl startserver -c /etc/motioneye/motioneye.conf

Aug 18 15:03:54 DietPi3 systemd[1]: Started motionEye Server.
Aug 18 15:03:55 DietPi3 meyectl[5961]:     INFO: hello! this is motionEye server 0.42.1
Aug 18 15:03:56 DietPi3 meyectl[5961]:     INFO: main config file /etc/motioneye/motion.conf does not exist, using default values
Aug 18 15:03:56 DietPi3 meyectl[5961]:     INFO: cleanup started
Aug 18 15:03:56 DietPi3 meyectl[5961]:     INFO: wsswitch started
Aug 18 15:03:56 DietPi3 meyectl[5961]:     INFO: tasks started
Aug 18 15:03:56 DietPi3 meyectl[5961]:     INFO: mjpg client garbage collector started
Aug 18 15:03:57 DietPi3 meyectl[5961]:     INFO: server started

At least web interface is working. I could not test it further as I don’t have any camara

root@DietPi3:/var/log# ss -tulpn | grep LISTEN
tcp   LISTEN 0      1000         0.0.0.0:22        0.0.0.0:*    users:(("dropbear",pid=473,fd=4))
tcp   LISTEN 0      128          0.0.0.0:8765      0.0.0.0:*    users:(("meyectl",pid=5961,fd=12))
tcp   LISTEN 0      4096       127.0.0.1:8080      0.0.0.0:*    users:(("motion",pid=5940,fd=7))
tcp   LISTEN 0      4096       127.0.0.1:8081      0.0.0.0:*    users:(("motion",pid=5940,fd=5))
tcp   LISTEN 0      1000            [::]:22           [::]:*    users:(("dropbear",pid=473,fd=5))
root@DietPi3:/var/log#

I am trying to install motioneye. But it does not work. :thinking:

pip3 install -U motioneye

Works, but i don’t get a service “motioneye”. Looks like i miss something. Any idea?

first you would need to install Python2 :wink:

and to install MotionEye

python2 -m pip install -U motioneye

Personally I hacked dietpi-software to get Python2 along with Python3 :sunglasses:

Too fast sorry… :stuck_out_tongue:
What is needed?

apt install python2

What else?

give me some time. I will create a small how-to next days. Just need to find time.

Perfect, THX. :smiley:
I can test it, have 6 cameras connected to 3 pi’s managed by a central debian server. :wink:
But it really should be moved to py3! We need someone to poke the motioneye team :stuck_out_tongue: