FC6 - 1.22.1 to 1.23.1 upgraded, but can't view Events?
Posted: Thu Feb 07, 2008 6:48 am
On my home server...
I've had a wonderful working 1.22.1 system for months, and have been very happy with everything. But a few weeks ago, I got the pop-up for the new version, downloaded, configured, updated packages, re-configured, compiled, then installed.
But, I could not get the old database to load, so I followed the instructions in the Wiki and ran 'zmupdate.pl –version=1.22.1'
Now, the main page loads, and I think everything is fine, until I try to look at an event and get a blank window.
So, I followed the hints given in this thread and enabled $db_debug in zm_db.php and now in the error_log I see this...
Hmmm, that doesn't look good. I was clicking on a single event. So, I recheck the Forum and find the same thread and after re-reading it, I decide to run a mysqlcheck (in extended mode) and it says...
So, the database says it's okay, but the problem I have is when I click on a link like ...
I try to do mysql queries which are WAY too big...
For instance, if I manually send the SQL-DEBUG commands to mysql (password changed BTW ) I see the following...
So, in order to display a single event, I need to pull 106,224 things out of the database? Umm, what is wrong with my host?
Scott
Code: Select all
[sck@house ~]$ cat /etc/fedora-release
Fedora Core release 6 (Zod)
[sck@house ~]$ uname -a
Linux house.nogas.org 2.6.22.14-72.fc6 #1 SMP Wed Nov 21 15:12:59 EST 2007 i686 i686 i386 GNU/Linux
But, I could not get the old database to load, so I followed the instructions in the Wiki and ran 'zmupdate.pl –version=1.22.1'
Now, the main page loads, and I think everything is fine, until I try to look at an event and get a blank window.
So, I followed the hints given in this thread and enabled $db_debug in zm_db.php and now in the error_log I see this...
Code: Select all
[Wed Feb 06 22:21:45 2008] [error] [client 192.168.8.104] SQL-DEBUG: select E.*,M.Name as MonitorName,M.Width,M.Height,M.DefaultRate,M.DefaultScale from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.Id = '354264', referer: http://192.168.8.4:81/zm/index.php?view=events&page=1&filter[terms][0][attr]=Archived&filter[terms][0][op]==&filter[terms][0][val]=0&filter[terms][1][cnj]=and&filter[terms][1][attr]=DateTime&filter[terms][1][op]=%3E=&filter[terms][1][val]=-1+month&filter[terms][2][cnj]=and&filter[terms][2][attr]=MonitorId&filter[terms][2][op]==&filter[terms][2][val]=8
[Wed Feb 06 22:21:45 2008] [error] [client 192.168.8.104] SQL-DEBUG: select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.StartTime <= '2008-01-12 10:15:42' order by E.StartTime desc, referer: http://192.168.8.4:81/zm/index.php?view=events&page=1&filter[terms][0][attr]=Archived&filter[terms][0][op]==&filter[terms][0][val]=0&filter[terms][1][cnj]=and&filter[terms][1][attr]=DateTime&filter[terms][1][op]=%3E=&filter[terms][1][val]=-1+month&filter[terms][2][cnj]=and&filter[terms][2][attr]=MonitorId&filter[terms][2][op]==&filter[terms][2][val]=8
[Wed Feb 06 22:21:45 2008] [error] [client 192.168.8.104] SQL-DEBUG: select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.StartTime <= '2008-01-12 10:15:42' order by E.StartTime desc, referer: http://192.168.8.4:81/zm/index.php?view=events&page=1&filter[terms][0][attr]=Archived&filter[terms][0][op]==&filter[terms][0][val]=0&filter[terms][1][cnj]=and&filter[terms][1][attr]=DateTime&filter[terms][1][op]=%3E=&filter[terms][1][val]=-1+month&filter[terms][2][cnj]=and&filter[terms][2][attr]=MonitorId&filter[terms][2][op]==&filter[terms][2][val]=8
[Wed Feb 06 22:21:53 2008] [error] [client 192.168.8.104] PHP Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 40 bytes) in /home/zm/zm_db.php on line 99, referer: http://192.168.8.4:81/zm/index.php?view=events&page=1&filter[terms][0][attr]=Archived&filter[terms][0][op]==&filter[terms][0][val]=0&filter[terms][1][cnj]=and&filter[terms][1][attr]=DateTime&filter[terms][1][op]=%3E=&filter[terms][1][val]=-1+month&filter[terms][2][cnj]=and&filter[terms][2][attr]=MonitorId&filter[terms][2][op]==&filter[terms][2][val]=8
Allowed memory size of 16777216 bytes exhausted (tried to allocate 10 bytes)
Code: Select all
[sck@house zm]$ mysqlcheck -u root -pSECRET_PASSWRD_YO! -e zm
zm.Config OK
zm.ControlPresets OK
zm.Controls OK
zm.Devices OK
zm.Events OK
zm.Filters OK
zm.Frames OK
zm.Groups OK
zm.MonitorPresets OK
zm.Monitors OK
zm.States OK
zm.Stats OK
zm.TriggersX10 OK
zm.Users OK
zm.ZonePresets OK
zm.Zones OK
[sck@house zm]$
Code: Select all
javascript: eventWindow( '/zm/index.php?view=event&eid=354264&filter[terms][0][attr]=Archived&filter[terms][0][op]==&filter[terms][0][val]=0&filter[terms][1][cnj]=and&filter[terms][1][attr]=DateTime&filter[terms][1][op]=>=&filter[terms][1][val]=-1+month&filter[terms][2][cnj]=and&filter[terms][2][attr]=MonitorId&filter[terms][2][op]==&filter[terms][2][val]=8&sort_field=DateTime&sort_asc=1&page=1', 'zmEvent', 336, 348 );
For instance, if I manually send the SQL-DEBUG commands to mysql (password changed BTW ) I see the following...
Code: Select all
[sck@house zm]$ echo "select E.*,M.Name as MonitorName,M.Width,M.Height,M.DefaultRate,M.DefaultScale from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.Id = '354264'" | mysql -u zmuser -pzm_passwd -D zm | wc -l
2
[sck@house zm]$ echo "select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.StartTime <= '2008-01-12 10:15:42' order by E.StartTime desc" | mysql -u zmuser -pzm_passwd -D zm | wc -l
106224
[sck@house zm]$ echo "select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where E.StartTime <= '2008-01-12 10:15:42' order by E.StartTime desc" | mysql -u zmuser -pzm_passwd -D zm | wc -l
106224
Scott