ZM stops recording events, SQL error

Forum for questions and support relating to the 1.24.x releases only.
Locked
darkpaw
Posts: 166
Joined: Thu Apr 26, 2007 2:35 am

ZM stops recording events, SQL error

Post by darkpaw »

After running fine for weeks, ZM stopped recording events. All processes start fine and start processing, then I eventually get this:

Sep 7 04:44:31 zm zma_m4[1534]: INF [BackYard: 800 - Gone into alarm state]
Sep 7 04:44:31 zm zma_m4[1534]: ERR [Can't insert event: Duplicate entry '0' for key 'Archived']
Sep 7 04:44:31 zm zmdc[1252]: ERR ['zma -m 4' exited abnormally, exit status 38]

Every time there is an alarm, it says that there is a duplicate entry, and ZM crashes. Doesn't matter which camera (I have four active, five connected).

This happened before, and I just reinstalled it to get everything working again, and wrote it off as a fluke. But this is twice, so something is wrong.

This is running version 1.24.2-6 in Fedora Core 14.
bb99
Posts: 943
Joined: Wed Apr 02, 2008 12:04 am

Re: ZM stops recording events, SQL error

Post by bb99 »

Try repairing your database: http://www.zoneminder.com/wiki/index.ph ... atabase.3F

Or use Phpmyadmin.
darkpaw
Posts: 166
Joined: Thu Apr 26, 2007 2:35 am

Re: ZM stops recording events, SQL error

Post by darkpaw »

I think I just made it worse:

Sep 7 19:45:01 zm zmaudit[2815]: FAT [Can't execute: Incorrect key file for table './zm/Events.MYI'; try to repair it]

Uh oh.

Going to try phpmyadmin now...
darkpaw
Posts: 166
Joined: Thu Apr 26, 2007 2:35 am

Re: ZM stops recording events, SQL error

Post by darkpaw »

I updated the config for phpmyadmin and I can't seem to get into the 'zm' database. So I tried via CLI, and get:

[root@zm db]# mysql -uzm
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 337
Server version: 5.1.56 Source distribution

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> USE `zm`;
ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'zm'
mysql> \q;
Bye
[root@zm db]#



-----------------------------

I never changed the password for the zm user since database creation. I checked the zm_create.pl script and there is no password specified.

What am I doing wrong?
Locked