Solved

apc.shm_segments setting ignored in MMAP mode

Posted on 2011-02-22
6
2,055 Views
Last Modified: 2013-12-13
Hi there:

This is an error message I am getting in my apache log file:

PHP Warning:  PHP Startup: apc.shm_segments setting ignored in MMAP mode in Unknown on line 0

I have my php.ini file APC as follows:

extension=apc.so
[apc]
apc.ttl="7200"
apc.user_ttl="7200"
apc.shm_segments="3"
apc.shm_size="32"

May that be related to an error in my config file?

Thank you very much in advance.

Javier Faus
0
Comment
Question by:javierfaus
  • 3
  • 3
6 Comments
 
LVL 14

Accepted Solution

by:
svgmuc earned 125 total points
Comment Utility
From http://php.net/manual/en/apc.configuration.php

When APC is compiled with mmap support (Memory Mapping), it will use only one memory segment, unlike when APC is built with SHM (SysV Shared Memory) support that uses multiple memory segments. MMAP does not have a maximum limit like SHM does in /proc/sys/kernel/shmmax. In general MMAP support is recommeded because it will reclaim the memory faster when the webserver is restarted and all in all reduces memory allocation impact at startup.
0
 

Author Comment

by:javierfaus
Comment Utility
So if my APC is working in MMAP mode I just set the apc.shm_segments="1", is it?

Thanks in advance.
Javier.
0
 
LVL 14

Expert Comment

by:svgmuc
Comment Utility
Yes, that's the only acceptable setting.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:javierfaus
Comment Utility
Hi svgmuc:

Thanks for your help here. Is there any way to make sure my APC is actually configured to use MMAP? I would say it is because of the error message but still not 100% sure.

Thanks a lot for your support in this one.
Javier.
0
 

Author Closing Comment

by:javierfaus
Comment Utility
Just partial answer.
0
 
LVL 14

Expert Comment

by:svgmuc
Comment Utility
The error would not show if not in MMAP mode.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
In Solr 4.0 it is possible to atomically (or partially) update individual fields in a document. This article will show the operations possible for atomic updating as well as setting up your Solr instance to be able to perform the actions. One major …
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to dynamically set the form action using jQuery.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now