Zoneminder Rpi 4

Forum for questions and support relating to the 1.34.x releases only.
Post Reply
mindzone
Posts: 5
Joined: Mon Aug 17, 2020 10:18 pm

Zoneminder Rpi 4

Post by mindzone »

Hello,
I am trying to setup zoneminder at my home and I am having some trouble. If anyone could help it would be greatly appreciated.

MY configuration is not very complicated, but for some reason I am having trouble getting setup. I followed the instructions to install here :
https://wiki.zoneminder.com/Raspberry_Pi_4_-_Raspbian
but i changed settings to port 8000 because i already had raspap installed (thats how my ip cams connect to rpi)

I have :
raspberry pi 4b, 1tb external hard drive, zoneminder, 2 IP cameras

I was able to get zoneminder installed, but playback in the browser application is wonky :
Image
Image

I did a forum search and saw two other people with the same issue, but they resolved it differently with no definite method. Play button doesn't work, time index shows NaN - etc.

trying to export one video works, but attempting to produce a zip, or tar file of a collection of videos just generates an empty archive

today i spent an hour trying to get zoneminder to save to my hard drive. i could not get it to save to my hard drive.
right now i have the function set to "modetect" however ideally i want "mocord"
when i use the Options Page menu in Zoneminder to assign storage to my hard drive, mounted at /media/pi/camdrive, zoneminder still writes to default :: /var/cache/zoneminder/events/
Image
Image

any tips on how to get the playback working? Or how I can get the storage directory to my camdrive?

Thanks.
I did a chown for /media/pi/camdrive
but I have only had this pi since beginning this project. My linux skills are limited but effective.
User avatar
burger
Posts: 390
Joined: Mon May 11, 2020 4:32 pm

Re: Zoneminder Rpi 4

Post by burger »

For saving to the HDD see the wiki:
https://wiki.zoneminder.com/Helpful_use ... stallation

"Using a dedicated Hard Drive"

For the other errors, what do the logs say?
fastest way to test streams:
ffmpeg -i rtsp://<user>:<pass>@<ipaddress>:554/path ./output.mp4 (if terminal only)
ffplay rtsp://<user>:<pass>@<ipaddress>:554/path (gui)
find paths on ispydb or in zm hcl

If you are new to security software, read:
https://wiki.zoneminder.com/Dummies_Guide
mindzone
Posts: 5
Joined: Mon Aug 17, 2020 10:18 pm

Re: Zoneminder Rpi 4

Post by mindzone »

thank you for your response.
I checked the link, and was able to configure my external HD.

I still have not had the chance to check logs yet. I will probably be switching to a different linux distro today, so not sure if I will have any further trouble or not.

Thanks, this was helpful.
mindzone
Posts: 5
Joined: Mon Aug 17, 2020 10:18 pm

Re: Zoneminder Rpi 4

Post by mindzone »

I was not able to get things working on the newer linux distro, so i'm back to raspberry pi os.

I am still unable to get zoneminder to save to my external hard drive. I am using

https://wiki.zoneminder.com/Using_a_ded ... Hard_Drive

I followed instructions here as far as I could. pretty much until step 7. i set the drive folder to 777, i do not see how to add specific users

here are some screen shots and log output :
this is my mounted external 1TB hard drive. it is labelled camdrive and is currently empty, partitioned to ntfs
Image

this is what my camera looks like from the console :
Image

this is what my camera storage settings looks like :
Image
Image

this is what my output is giving me on step 7 of the instructions. is there a specific command or set of commands i should be entering in here? I know i want to add user www-data but i don't see the command. i was able to set the permissions to 777. this system will not be connected to the www.
Image

these are the output of the logs as far as i can tell :
Image

this is the result of the camera capturing motion :
Image


can anuyone tell me what i missed or did wrong?

Thanks
mindzone
Posts: 5
Joined: Mon Aug 17, 2020 10:18 pm

Re: Zoneminder Rpi 4

Post by mindzone »

i tried :
# sudo chown -R www-data /media/pi/camdrive

to add permissions to the /media/pi/camdrive - my external hard drive
then continued with the instructions adding a filter "that will delete on our new storage area."

I'm still getting the error.


another question. when i view logs, there is a "clear" button, but it looks like it clears the scren and not the logs.

in order to delete the logs, i see this online"
# mysql -uroot -ppassword zm
# truncate table Logs;
# quit

and that clears my logs. is it true the only way to delete zoneminder logs is through terminal?

any idea why my external hard drive is still not showing up in zoneminder?

I believe i have covered all the instructions, i could be wrong.
User avatar
burger
Posts: 390
Joined: Mon May 11, 2020 4:32 pm

Re: Zoneminder Rpi 4

Post by burger »

mindzone wrote: Sat Aug 29, 2020 8:35 pm I'm still getting the error.
What error is that? You didn't say.
mindzone wrote: Sat Aug 29, 2020 8:35 pm in order to delete the logs, i see this online"
# mysql -uroot -ppassword zm
# truncate table Logs;
# quit

and that clears my logs. is it true the only way to delete zoneminder logs is through terminal?
You shouldn't need to worry about truncating any ZM (mysql) logs. The system will manage it for you, I think there is a setting in options that by default truncates it every 30 or 60 days or something. And logrotate will handle /var/log.

You don't know how to use chown? You lack a fundamental understanding of how to use Unix. Perhaps you should read a few books on the subject, and or use the OS for a year or two before jumping into administering Zoneminder.
fastest way to test streams:
ffmpeg -i rtsp://<user>:<pass>@<ipaddress>:554/path ./output.mp4 (if terminal only)
ffplay rtsp://<user>:<pass>@<ipaddress>:554/path (gui)
find paths on ispydb or in zm hcl

If you are new to security software, read:
https://wiki.zoneminder.com/Dummies_Guide
mindzone
Posts: 5
Joined: Mon Aug 17, 2020 10:18 pm

Re: Zoneminder Rpi 4

Post by mindzone »

yep
you are probably right.

I bought the pi and some cameras as a cheaper alternative. not working

I know web programming, very deep. not interested in learning a new language nor set of commands.
I've spent days, months, hours in linux, i just retain none of it. specific routines and commands are saved to file, or written in notebooks, but i don't care to memorize something that 75% works - just yet. It requires a dedicated effort i'm not ready to give.

This past week i have faced the music that i may have to settle for buying an out-of-the-box security solution or just buy an x86 windows machine for this. I'm familiar enough with linux to remember slackware linux prior to the existence of tinycore linux. it's just really not my thing i guess. i do web programming daily but may go months without using linux os.

I did get one of those retropie installs with over 31,000 games so i guess i still have use for the pi even if it's not my original intent.

oh well. zoneminder is still better than motioneye. but all these programs require more hacking and configuring than i care to give.
We need more video tutorials.
User avatar
burger
Posts: 390
Joined: Mon May 11, 2020 4:32 pm

Re: Zoneminder Rpi 4

Post by burger »

RPI is limited in its performance with ZM.

https://wiki.zoneminder.com/Single_Board_Computers

It can be used, but quickly reaches limitations. This is also why virtual reality with a cellphone is not feasible.
fastest way to test streams:
ffmpeg -i rtsp://<user>:<pass>@<ipaddress>:554/path ./output.mp4 (if terminal only)
ffplay rtsp://<user>:<pass>@<ipaddress>:554/path (gui)
find paths on ispydb or in zm hcl

If you are new to security software, read:
https://wiki.zoneminder.com/Dummies_Guide
Post Reply