View | Details | Raw Unified | Return to bug 54415
Collapse All | Expand All

(-)../httpd-2.4.3-org/httpd-2.4.3/server/scoreboard.c (-5 / +13 lines)
Lines 179-191 Link Here
179
179
180
    /* The shared memory file must not exist before we create the
180
    /* The shared memory file must not exist before we create the
181
     * segment. */
181
     * segment. */
182
    apr_shm_remove(fname, pool); /* ignore errors */
182
    rv = apr_shm_remove(fname, pool);
183
    if (rv != APR_SUCCESS) {
184
        ap_log_error(APLOG_MARK, APLOG_INFO, rv, ap_server_conf, APLOGNO(00001)
185
                     "Unable to remove the old scoreboard file \"%s\".", fname);
186
    }   
183
187
184
    rv = apr_shm_create(&ap_scoreboard_shm, scoreboard_size, fname, pool);
188
    rv = apr_shm_create(&ap_scoreboard_shm, scoreboard_size, fname, pool);
185
    if (rv != APR_SUCCESS) {
189
    if (rv != APR_SUCCESS) {
186
        ap_log_error(APLOG_MARK, APLOG_CRIT, rv, ap_server_conf, APLOGNO(00001)
190
        ap_log_error(APLOG_MARK, APLOG_CRIT, rv, ap_server_conf, APLOGNO(00001)
187
                     "unable to create or access scoreboard \"%s\" "
191
                     "Unable to create or access scoreboard \"%s\" with size %u "
188
                     "(name-based shared memory failure)", fname);
192
                     "(name-based shared memory failure). "
193
                     "Please check the 'ServerLimit' and 'ThreadLimit' settings, or the memory usage.", 
194
		     fname, scoreboard_size);
189
        return rv;
195
        return rv;
190
    }
196
    }
191
#endif /* APR_HAS_SHARED_MEMORY */
197
#endif /* APR_HAS_SHARED_MEMORY */
Lines 231-238 Link Here
231
                            global_pool); /* anonymous shared memory */
237
                            global_pool); /* anonymous shared memory */
232
        if ((rv != APR_SUCCESS) && (rv != APR_ENOTIMPL)) {
238
        if ((rv != APR_SUCCESS) && (rv != APR_ENOTIMPL)) {
233
            ap_log_error(APLOG_MARK, APLOG_CRIT, rv, ap_server_conf, APLOGNO(00004)
239
            ap_log_error(APLOG_MARK, APLOG_CRIT, rv, ap_server_conf, APLOGNO(00004)
234
                         "Unable to create or access scoreboard "
240
                         "Unable to create or access scoreboard with size %u "
235
                         "(anonymous shared memory failure)");
241
                         "(anonymous shared memory failure). "
242
                         "Please check the 'ServerLimit' and 'ThreadLimit' settings, or the disk space.", 
243
                         scoreboard_size);
236
            return rv;
244
            return rv;
237
        }
245
        }
238
        /* Make up a filename and do name-based shmem */
246
        /* Make up a filename and do name-based shmem */

Return to bug 54415