[Can't get shared memory id '7a6d0003', 3: No such file or

Forum for questions and support relating to the 1.24.x releases only.
Locked
edgar5
Posts: 20
Joined: Tue Nov 16, 2010 7:59 pm

[Can't get shared memory id '7a6d0003', 3: No such file or

Post by edgar5 »

Very popular bug:

01/24/11 16:29:05.529377 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]
01/24/11 16:29:15.531675 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]
01/24/11 16:29:25.533886 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]
01/24/11 16:29:35.536174 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]
01/24/11 16:29:45.538477 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]
01/24/11 16:29:55.540810 zmwatch[8930].ERR [Can't get shared memory id '7a6d0003', 3: No such file or directory]

Is any solution for this?
dsbruin
Posts: 6
Joined: Fri Jan 21, 2011 6:26 pm

Post by dsbruin »

I don't really know what causes that error, but I have discovered through reading places on the Internet, including but not limited to this forum, that changing the kernel's SHMMAX setting alleviates this problem.

This parameter controls how much SHared Memory the kernel has access to. I believe it is measured in PAGES (as opposed to BYTE, KILOBYTES, etc). I further believe most modern linux distributions have a default value compiled into the kernel and/or a considerably obfuscated config file that isn't supposed to get changed (instead you're supposed to supersede it if you want to change the values). I say this so people don't bother trying to grep in their /etc or /proc directory for the value and wonder why they can't find it.

Anyway, a fairly accepted way to persistently override your default value is to simply specify explicitly what you'd like in your /etc/sysctl.conf file and then issue a runtime command to have your kernel reload its parameters (with root privileges):

Code: Select all

sysctl -p
. FYI you only need to issue this command if you want your changes to take effect without a reboot, as they will automatically be incorporated after any future reboots during the init process.

I was getting the same error specified in your post until I tried:

Code: Select all

kernel.shmmax = 134217728
in my sysctl.conf.

I don't really understand why ZoneMinder has what seems to be a soft-coded memory address ("soft" because it is in the default code, but can be changed through the web UI). I would expect there's some way to make this more automated and/or a better error message. I assume ZoneMinder is running out of memory somehow or another when it issues this error.

I'm not entirely sure if my fix is really the right answer, or if it is even a direct fix (as opposed to something that just happens to make the problem go away, but not intentionally). Either way, this should probably be corrected upstream in ZoneMinder by having it check the system for compatibility and issue a warning or error if kernel parameters look unusable.
edgar5
Posts: 20
Joined: Tue Nov 16, 2010 7:59 pm

Post by edgar5 »

Thank you fof reply.

I changed sysctl parameters as You said, but it not helped.
My system has only 128 MB ram and no swap. I wonder to know wahat parameter should be form monitor (logitech c 120), when is just 128 MB RAM.
PacoLM
Posts: 971
Joined: Wed Dec 02, 2009 9:55 pm
Location: Spain

Post by PacoLM »

Hi,
First question: how many cameras do you have in your system?. Seeing the error seems like you have 3, because the first monitor should have a id of 0x7a6d0001. the second 0x7a6d0002 and the third 0x7a6d0003.
Check this, try to run the command 'ipcs -m' and see how many shared memory segments you have in your system.
If you only have one camera, then check the value of the shared memory key in Options-> System->SHM_KEY, the default is 0x7a6d0000.

Post results!,

PacoLM
edgar5
Posts: 20
Joined: Tue Nov 16, 2010 7:59 pm

Post by edgar5 »

1.Options-> System->SHM_KEY, the default is 0x7a6d0000: yes it is.
2. ipcs -m:
voyage:~# ipcs -m

------ Shared Memory Segments --------
key shmid owner perms bytes nattch status

3. lsusb:
Bus 003 Device 003: ID 046d:080f Logitech, Inc. Webcam C120

4. dmesg:
[ 13.275439] uvcvideo: Found UVC 1.00 device <unnamed> (046d:080f)
[ 13.296561] input: UVC Camera (046d:080f) as /class/input/input4
[ 13.296753] usbcore: registered new interface driver uvcvideo
[ 13.296825] USB Video Class driver (v0.1.0)

5. just one camera as above

6. fswebcam, webcam work perfectly with this camera on this system
PacoLM
Posts: 971
Joined: Wed Dec 02, 2009 9:55 pm
Location: Spain

Post by PacoLM »

Hi again,

Try to remove and reinstall again zoneminder.

PacoLM
edgar5
Posts: 20
Joined: Tue Nov 16, 2010 7:59 pm

Post by edgar5 »

Why?
chim
Posts: 5
Joined: Sun Jan 30, 2011 12:42 pm

Post by chim »

I'm having the exact same problem, been at it all sunday, if I find something i'll post it here.

Regards
Chim
PacoLM
Posts: 971
Joined: Wed Dec 02, 2009 9:55 pm
Location: Spain

Post by PacoLM »

Hi,

I'll try to reinstall it, because seems that you have tried to configure more than one monitor (maybe doing test, you created one, then deleted it, etc).
The database could be corrupted, so, in your case, I will reinstall the complete package, just to try, in fact is a question of 5-10 minutes...

PacoLM
edgar5
Posts: 20
Joined: Tue Nov 16, 2010 7:59 pm

Post by edgar5 »

But I see in my log it isn`t problem of mysql, many users have the same problem and no one can repair it.
force
Posts: 8
Joined: Wed Jan 26, 2011 12:03 pm

Post by force »

edgar5 wrote:But I see in my log it isn`t problem of mysql, many users have the same problem and no one can repair it.
sad but true
Locked