How update ZM from 1.25.0 to 1.26.3

Forum for questions and support relating to the 1.26.x releases only.
iitywygms
Posts: 123
Joined: Thu Nov 08, 2012 5:19 am

Re: How update ZM from 1.25.0 to 1.26.3

Post by iitywygms »

Magic919 wrote:Great. After than just run zmupdate.pl with no arguments.
Magic919. You obviously know more about zoneminder than I.
But from this thread, http://www.zoneminder.com/forums/viewto ... .pl#p80904
it says you must run certain arguments.
I am not saying which way is right, or create confusion for the op and I apologize if I do. I just want to pass on info that I come across.
topromotion
Posts: 22
Joined: Mon Aug 12, 2013 3:18 pm

Re: How update ZM from 1.25.0 to 1.26.3

Post by topromotion »

Magic919 wrote:Great. After than just run zmupdate.pl with no arguments.
I have an error after zmupdate.pl command. See picture.
Attachments
error.png
error.png (6.16 KiB) Viewed 3567 times
Magic919
Posts: 1381
Joined: Wed Sep 18, 2013 6:56 am

Re: How update ZM from 1.25.0 to 1.26.3

Post by Magic919 »

Running from that location overrides your config - as the message says.

Leave that directory, then run it somewhere that doesn't contain a zm.conf.
-
User avatar
knight-of-ni
Posts: 2404
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: How update ZM from 1.25.0 to 1.26.3

Post by knight-of-ni »

Magic919 wrote:Great. After than just run zmupdate.pl with no arguments.
Negative.

If your previous version of zoneminder is older than 1.26.0 than you have to call zmupdate.pl like so or the upgrade will leave your system with missing columns in the Monitors dB table:

Code: Select all

sudo zmudpate.pl --user=root --pass={mysql_root_pwd}
When in doubt, always run zmupdate.pl like that.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Magic919
Posts: 1381
Joined: Wed Sep 18, 2013 6:56 am

Re: How update ZM from 1.25.0 to 1.26.3

Post by Magic919 »

I've never run mine that way, but my database has the newer columns, Deinterlacing and Colours. It'll come down to how you've set the privileges of your ZM user for the database at the end of the day, surely. I don't mind it being the recommended way, just I can't see we 'have' to.
-
User avatar
knight-of-ni
Posts: 2404
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: How update ZM from 1.25.0 to 1.26.3

Post by knight-of-ni »

Magic919 wrote:I've never run mine that way, but my database has the newer columns, Deinterlacing and Colours. It'll come down to how you've set the privileges of your ZM user for the database at the end of the day, surely. I don't mind it being the recommended way, just I can't see we 'have' to.
From the zoneminder wiki:

Code: Select all

mysql> grant select,insert,update,delete on zm.* to '<database user>'@localhost identified by '<database password>';
The lines of Perl script that updates an older dB to 1.26.0 looks like this:

Code: Select all

$dbh->do(q{alter table Monitors add column `Colours` tinyint(3) unsigned NOT NULL default '1' after `Height`;});
$dbh->do(q{alter table Monitors add column `Deinterlacing` INT unsigned NOT NULL default '0' after 
This step will fail for anyone following the zoneminder documentation. That's why I said something.

While you might have upgraded the permissions of the zmuser account on your system, a new person following the instructions would not know to do this. That person would end up with a database missing the mentioned columns. Running zmupdate.pl a second time is not an option because the script would have written a 1.26.x to the config table. Catch-22. Yuck.

This is an issue we are currently working on, but in the meantime you have to run zmupdate.pl the way that was previously mentioned if you are upgrading to/past 1.26.0.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Locked