Page 1 of 1

add new monitor help

Posted: Mon Feb 06, 2006 4:18 pm
by mountainMan
OK...i know how to add a new monitor but for streaming reasons i need to know something....

on the Zoneminder console the far left colum is ID....Name...Function..etc

When i delete a cam and add one its like it remembers the deleted cam id and just adds one to it....Like if i delete the last cam ID 3 and add one....It wont pick up redo 3 it goes one more cam up to 4...how do i wipe this clean ???

Posted: Mon Feb 06, 2006 5:27 pm
by Nico
I would suspect this has to do with the mysql database part of the software. A lot of the CMS's I use for websites do the same, if I want to reclaim that ID number I have to go in and edit the actual database. You gotta ask yourself

A) how well do i know mysql
B) do I really wanna mess with it

if you really do want to mess with it, and would like an easy way to edit mysql entries try out phpMyAdmin

of course this is only my second post and i am not sure, so this only will help you if my theory is correct.

Posted: Mon Feb 06, 2006 5:43 pm
by mountainMan
this sounds sticky and i a very new newbie for both linux and zoneminder...I figured there were some ez fix... :cry:

Posted: Mon Feb 06, 2006 6:36 pm
by SyRenity
Hi.

Try to search in Google for "mysql resetting autoincrement". There will be quite a lot of results:

http://www.nexcess.net/forums/archive/i ... t-241.html
http://www.developer.be/index.cfm/fusea ... Id/187.htm
http://www.experts-exchange.com/Databas ... 25966.html


Btw, I don't guarantee at all that this won't mess your ZM installation, so if you can live with the incremented numbers, probably it will be better to let it be.

Posted: Mon Feb 06, 2006 8:16 pm
by cordel
It is a function of the database and there is no easy way about it. The best suggitions is just leave it alone, or install phpmyadmin.

Corey

Posted: Tue Feb 07, 2006 12:02 am
by zoneminder
The monitor ids autoincrement. If you do change it with mysql you should ensure that you also update the MonitorId field in the Zones and Events tables as well as possibly the Groups and Stats ones etc. Also there is a numbered link in the events directory. The simplest way to change it in the DB is to totally delete a monitor, set the next Id value (I can't remember the exact mysql command for this), and then create a new monitor which should be created with the correct value.

Generally speaking it's best to leave it alone, you can reorder the monitors with the arrows anyway. Eventually I think the Id field will disappear from the console anyway as it's becoming less necessary for users to know it nowadays.

Posted: Tue Feb 07, 2006 1:24 pm
by mountainMan
Well the only reason i wanted to change it was because of the windows viewing program that James Wilson wrote...just makes it easier to pull up when the monitors are numbered in secquence instead of having gaps.

Thanks for all your help...i am very happy with the program...and as i learn more i hope to contribute to the developement of ZONE MINDER...