-
Notifications
You must be signed in to change notification settings - Fork 701
(Install On Ubuntu (20.04 ‐ 21.10)
MichaIng edited this page May 2, 2025
·
2 revisions
- Below instructions are for the old Python 2 based version of motionEye.
- Please refer to our new install instructions for the new Python 3 based version: https://github.com/motioneye-project/motioneye#installation
- Please open an issue at https://github.com/motioneye-project/motioneye/issues if you can update below instructions.
- Read the general Installation page first.
- These instructions apply to Ubuntu LTS distributions (20.04). They may work for other Ubuntu distributions (20.10 EOL, 21.04 EOL , 21.10 EOL July 2022) and derivatives (such as Linux Mint) but they may not have been tested. As of 28 Jan, 2022 motionEye has been Development Limbo. Ubuntu 22.04 is currently broken (uses a broken version of libmicrohttpd12 0.9.75-3).
- All commands require root; use
sudobefore each command or become root usingsudo -i. - Install instructions confirmed as of 28 Jan 2022. get-pip.py location correct as of 28 Jan 2022.
-
Update and Upgrade fresh install of Ubuntu 20.04 or newer.
apt update && sudo apt upgrade -y -
Install
ssh,curl,motion,ffmpegandv4l-utils:apt-get install ssh curl motion ffmpeg v4l-utils -y reboot -
Install the python 2.7 and pip2: (enter as separate lines, do not copy/paste as a group)
apt-get install python2 -y curl https://bootstrap.pypa.io/pip/2.7/get-pip.py --output get-pip.py python2 get-pip.py There will be a warning that python 2.7 and pip2 are outdated and will not be updated This is normal and to be expected, as Python 2.7 is beyond EOL, as is pip2. When motionEye is updated to Python3, these messages will go away. -
Install all prerequisites: (enter as separate lines, do not copy/paste as a group)
apt-get install libffi-dev libzbar-dev libzbar0 -y apt-get install python2-dev libssl-dev libcurl4-openssl-dev libjpeg-dev -y -
Install
motioneye, which will automatically pull Python dependencies (tornado,jinja2,pillowandpycurl):pip2 install motioneye -
Prepare the configuration directory:
mkdir -p /etc/motioneye cp /usr/local/share/motioneye/extra/motioneye.conf.sample /etc/motioneye/motioneye.conf -
Prepare the media directory:
mkdir -p /var/lib/motioneye -
Add an init script, configure it to run at startup and start the
motionEyeserver:-
Ubuntu 15.04 or later, systemd-based:
cp /usr/local/share/motioneye/extra/motioneye.systemd-unit-local /etc/systemd/system/motioneye.service systemctl daemon-reload systemctl enable motioneye systemctl start motioneye
-
-
To upgrade to the newest version of motionEye, just issue:
pip2 install motioneye --upgrade systemctl restart motioneye
home | installation | faq
Installation (deprecated)
- Install On Debian (deprecated)
- Install on Debian 11 (Bullseye) (deprecated)
- Install On Ubuntu (20.04 ‐ 21.10) (deprecated)
- Install On Raspbian Buster (deprecated)
- Install on Raspbian Bullseye (deprecated)
- Install On Fedora (deprecated)
- Install On Arch (deprecated)
- Install On Other Distros (deprecated)
- Install In Docker (deprecated)
- Manual Installation (deprecated)