Page 1 of 1

How to change Events path

Posted: Fri Mar 09, 2012 9:21 am
by frankge973
I tried to change the events path without success.
In options I left 'Events'
and in the original folder of Events I created a sym link with ln command to new path on another hard drive.
But the events aren't recorded and IP camera's address in list are in orange colour. Why?
Thanks.

Re: How to change Events path

Posted: Fri Mar 09, 2012 3:25 pm
by PacoLM
mount external drive to store events:
mkdir /zmdisk
mount /dev/sdc1 /zmdisk
mkdir /zmdisk/events /zmdisk/images /zmdisk/temp
rm -rf /usr/share/zoneminder/events
rm -rf /usr/share/zoneminder/images
rm -rf /usr/share/zoneminder/temp
ln -s /zmdisk/events /usr/share/zoneminder/events
ln -s /zmdisk/images /usr/share/zoneminder/images
ln -s /zmdisk/temp /usr/share/zoneminder/temp

Be careful in the rm -rf steps, if you already have events, images, etc, first copy the complete directories to the new hard drive.

Hope it helps,

PacoLM

Re: How to change Events path

Posted: Tue Mar 27, 2012 12:21 am
by Mr.Ziggy
FYI: You haven't mentioned your distro. For Ubuntu, locations are different, and I struggled a long time until I came upon someone else's post about using FSTAB. For an odd Ubuntu reason, symlinks weren't working properly and I had to use FSTAB to make it all work out. From the link:



fstab could allow you to bind-mount an alternate location:
/dev/sdX1 /otherdrive ext3 defaults 0 2 /otherdrive/zoneminder/images /var/cache/zoneminder/images none defaults,bind 0 2 /otherdrive/zoneminder/events /var/cache/zoneminder/events none defaults,bind 0 2
or in some cases,
/otherdrive/zoneminder/images /usr/share/zoneminder/images none defaults,bind 0 2 /otherdrive/zoneminder/events /usr/share/zoneminder/events none defaults,bind 0 2
or if you have a separate partition for each:
/dev/sdX1 /var/cache/zoneminder/images ext3 defaults 0 2 /dev/sdX2 /var/cache/zoneminder/events ext3 defaults 0 2