Code: Select all
2011-09-13 19:39:41.584021 zma_m2 2087 ERR Got unexpected memory map file size 23041284, expected 5761284 zm_monitor.cpp 364
Code: Select all
2011-09-13 19:39:41.584021 zma_m2 2087 ERR Got unexpected memory map file size 23041284, expected 5761284 zm_monitor.cpp 364
Code: Select all
./configure --with-webdir=/var/www/zm --with-cgidir=/usr/lib/cgi-bin \
ZM_DB_HOST=localhost ZM_DB_NAME=zm ZM_DB_USER=zmuser \
ZM_DB_PASS=zmpass ZM_SSL_LIB=openssl --enable-debug=no \
--with-webgroup=www-data --with-webuser=www-data --enable-mmap CPPFLAGS="-D__STDC_CONSTANT_MACROS ${CPPFLAGS}"
Code: Select all
kernel.shmmax = 167772160
Code: Select all
Sep 13 22:05:39 ZONEMINDER1 zmc_dvideo0[3783]: ERR [Got unexpected memory map file size 6913364, expected 9217524]
You need to restart ZM after changing settings such as the resolution.gmar_87 wrote:I am trying to get some spare USB webcams working with ZoneMinder, but having some problems. I can get one sort of working at 320x240 but if i increase pixels or image frame size i get the following in the syslog.
Is it possible to increase mapped memory? If so, how?Code: Select all
2011-09-13 19:39:41.584021 zma_m2 2087 ERR Got unexpected memory map file size 23041284, expected 5761284 zm_monitor.cpp 364
I have tried restarting zm service and rebooting the server after the changes, but still same problem...mastertheknife wrote:You need to restart ZM after changing settings such as the resolution.gmar_87 wrote:I am trying to get some spare USB webcams working with ZoneMinder, but having some problems. I can get one sort of working at 320x240 but if i increase pixels or image frame size i get the following in the syslog.
Is it possible to increase mapped memory? If so, how?Code: Select all
2011-09-13 19:39:41.584021 zma_m2 2087 ERR Got unexpected memory map file size 23041284, expected 5761284 zm_monitor.cpp 364
mastertheknife
Code: Select all
--enable--mmap=yes
Code: Select all
mount | grep shm
Code: Select all
none on /dev/shm type tmpfs (rw,nosuid,nodev,size=512mb)
Code: Select all
# mount -o remount,size=1G /dev/shm
Code: Select all
ls -l /dev/shm/zm*
Thanks for the advice nightcrawler. Sorry i didn't get back to you sooner!nightcrawler wrote:gmar,
Mapped memory allows you to use a special type of file as the placeholder for your memory and this file is "mapped" into memory space for easy and fast access.
To enable mapped memory in Zoneminder you need to add theswitch to your configure line. IE: etc/zm/zm.confCode: Select all
--enable--mmap=yes
look if your linux has an mmap drive. usualy it is like /dev/shm. (see the wiki: http://www.zoneminder.com/wiki/index.php/FAQ for mmap)
You can check it with command:An line is send back if you have it like :Code: Select all
mount | grep shm
look to the size! if it's less then your system RAM than Increase it with an remount commandCode: Select all
none on /dev/shm type tmpfs (rw,nosuid,nodev,size=512mb)
and check it againCode: Select all
# mount -o remount,size=1G /dev/shm
Now set in Zoneminder options path > PAT_MAP to /dev/shm (default!) and restart ZoneMinder, to check the memory slices use "df" and relating to just ZM type(you can leave the /zm* out of it if you want to see other users of the swap space)Code: Select all
ls -l /dev/shm/zm*
and if it's set you can increase your camera resolution,buffer etc. if the cam stops working restart zoneminder like mastertheknife says in his post. the mmap only increase if you restart ZoneMinder.
(It personally has takes me a few days of google-in before I found this "bug").
Code: Select all
df -h
Code: Select all
mount | grep shm
Code: Select all
ls -al /dev/shm
Code: Select all
total 74424
drwxrwxrwt 2 root root 100 2011-10-10 19:55 .
drwxr-xr-x 19 root root 4340 2011-10-08 11:17 ..
-rw------- 1 www-data www-data 36865524 2011-10-11 08:45 zm.mmap.1
-rw------- 1 www-data www-data 36865524 2011-10-11 08:46 zm.mmap.2
-rw------- 1 www-data www-data 2305044 2011-10-10 19:55 zm.mmap.9