Page 1 of 1
Adding external hard drive
Posted: Sun Feb 09, 2014 4:10 pm
by peteer
I've been trying to figure out how I can make zoneminder upload all events to my external hard drive (NAS server configured with samba).
I followed this guide but I have no idea what I have to add to the fstab file...
http://www.zoneminder.com/wiki/index.ph ... Hard_Drive
My disk is recognized as /dev/sda1 and the nas is mounted to /media/hdd, I'd like to upload all events to /media/hdd/events.
So what do I change the settings below too to make them upload events to the external hard drive?
Code: Select all
/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
(I'm a complete noob at linux, I tried to figure out my own but it just won't work..
)
Re: Adding external hard drive
Posted: Sun Feb 09, 2014 8:18 pm
by mikb
Take a look here first ...
http://www.zoneminder.com/forums/viewto ... 30&t=21899
and I wonder if whoever wrote that guide you followed has no idea how crappy some of these NAS boxes are, maybe understandably, when trying to Unixy things on a FAT filesystem "inside the box".
Re: Adding external hard drive
Posted: Sun Feb 09, 2014 10:29 pm
by helpme1986
Here is what I did to make it work,
On my NAS make a new NFS share which had read/write permissions for all users (I have a zyxel nas, all of them are different so cant explain this bit sorry)
mkdir /mnt/cctv
apt-get install nfs-common
nano /etc/fstab
Added this to the bottom:
Note, my NAS IP is 192.168.1.3, my NFS share was /i-data/fbaf09a8/nfs/cctv
Code: Select all
192.168.1.3:/i-data/fbaf09a8/nfs/cctv /mnt/cctv nfs
/mnt/cctv/zoneminder/images /var/cache/zoneminder/images none defaults,bind 0 2
/mnt/cctv/zoneminder/events /var/cache/zoneminder/events none defaults,bind 0 2
/mnt/cctv/zoneminder/images /usr/share/zoneminder/images none defaults,bind 0 2
/mnt/cctv/zoneminder/events /usr/share/zoneminder/events none defaults,bind 0 2
*Dont forget to create the zoneminder/images and zoneminder/events on the NFS first as they wont link
rebooted and it worked
Re: Adding external hard drive
Posted: Sun Feb 09, 2014 10:52 pm
by peteer
Alright, I guess it's working now, since the disk shows -1% usage, did you have that problem aswell?
(now it is linked, but doesn't record anymore)
Re: Adding external hard drive
Posted: Sun Feb 09, 2014 10:56 pm
by helpme1986
have you rebooted? mine showed -1% until i rebooted, if it still shows -1% then the mounting and binding hasnt worked properly
maybe copy n paste your fstab here so we can see (im a noob as well so dont know if ill be able to help much!)
Re: Adding external hard drive
Posted: Mon Feb 10, 2014 8:08 am
by peteer
Still showing -1
But I'm wondering, the nas is mounted to /media/hdd, so do I put /media/hdd/cctv or /hdd/cctv
Code: Select all
192.168.0.125:/media/hdd/cctv /mnt/cctv nfs
/mnt/cctv/zoneminder/images /var/cache/zoneminder/images none defaults,bind 0 2
/mnt/cctv/zoneminder/events /var/cache/zoneminder/events none defaults,bind 0 2
/mnt/cctv/zoneminder/images /usr/share/zoneminder/images none defaults,bind 0 2
/mnt/cctv/zoneminder/events /usr/share/zoneminder/events none defaults,bind 0 2
I just copied yours, but changed my IP and the location of NAS. I guess that's where it goes wrong but I'll try some settings out tonight.