Page 1 of 1

Fresh install problem on Ubuntu 22.04.3 LTS

Posted: Fri Nov 17, 2023 5:48 am
by bloxxom
I just installed Ubuntu server (Jammy) on my machine. I then installed Zoneminder, following these instructions:

https://zoneminder.readthedocs.io/en/la ... buntu.html.


Everything went fine, with no problems until the last step which is the one that starts Zoneminder.

It dumped the following systemd log message:

$ systemctl status zoneminder.service
× zoneminder.service - ZoneMinder CCTV recording and surveillance system
Loaded: loaded (/lib/systemd/system/zoneminder.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2023-11-16 21:23:53 PST; 38s ago
Docs: http://zoneminder.readthedocs.org/en/latest/
Process: 29985 ExecStart=/usr/bin/zmpkg.pl start (code=exited, status=255/EXCEPTION)
CPU: 88ms

Nov 16 21:23:53 rahula zmpkg[29985]: ERR [Error reconnecting to db: errstr:Access denied for user 'www-data'@'localhost' (using password: NO) error val:]
Nov 16 21:23:53 rahula zmpkg.pl[29985]: Unable to connect to DB. ZM Cannot continue.

So I'm guessing that something went wrong with the DB setup, but I'm a bit rusty on mysql etc. I'm hoping this is obvious to someone. I've seen other instructions that include steps for creating a DB user, but the instructions I followed didn't ask me to do that, so I didn't. This is the Zoneminder from the Ubuntu Repo, which claims to be version 1.36.12+dfsg1-1

Re: Fresh install problem on Ubuntu 22.04.3 LTS

Posted: Fri Nov 17, 2023 6:14 pm
by bloxxom
Okay, I seem to have gotten it working.

There were a few steps missing from the instructions that I followed.

I had to add the www-data user
I had to create zmuser in mysql
I had to create the zm database

At this point, I was getting a blank page (error 500)

I ran zmupdate.pl -f

Now I can see the web page and it seems to be working. I will add some monitors and see what happens.

Re: Fresh install problem on Ubuntu 22.04.3 LTS

Posted: Sat Nov 18, 2023 2:34 pm
by bbunge

Re: Fresh install problem on Ubuntu 22.04.3 LTS

Posted: Mon Nov 20, 2023 4:57 pm
by dad1
Hi,

Rebuilding a new zoneminder server after my last one died from hardware failure. Quick question not covered in the above helpful instrctions - does zoneminder still require its own separate disc partition?

If so does anyone have a custom partition layout for a clean ubuntu install?

Best

Re: Fresh install problem on Ubuntu 22.04.3 LTS

Posted: Tue Nov 21, 2023 1:29 am
by dougmccrary
I find it's better to have a separate disk for recordings. Do you have one? Also, best to have the os and data (i.e., everything other than recordings) on SSD.

Anyway, whatever you have to start, you don't need a partition, the recordings go to /var/cache/zoneminder/
If you have a separate disk available, you can just mount the disk over that and off you go, as long as you set the permissions to www-data.