php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #54201 memory_limit 4G limit?
Submitted: 2011-03-09 11:43 UTC Modified: 2011-03-22 10:23 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: paulgao at yeah dot net Assigned:
Status: Not a bug Package: PHP options/info functions
PHP Version: 5.3.5 OS: irrelevant
Private report: No CVE-ID: None
 [2011-03-09 11:43 UTC] paulgao at yeah dot net
Description:
------------
if memory_limit set to 4096M, Segfault.



Test script:
---------------
memory_limit = 4096M

Expected result:
----------------
[root@server]# php -v
PHP 5.3.5 (cli) (built: Feb 28 2011 22:46:15) 
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies

Actual result:
--------------
[root@server]# php -v

Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 34816 bytes) in Unknown on line 0
Segmentation fault

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-03-09 13:29 UTC] felipe@php.net
As we use a long for memory limit, using 4096M we got:
var_dump(intval(4096*1024*1024)); // 0
 [2011-03-22 10:23 UTC] aharvey@php.net
-Status: Open +Status: Bogus
 [2011-03-22 10:23 UTC] aharvey@php.net
What Felipe said. :)
 [2011-03-22 10:58 UTC] paulgao at yeah dot net
I want set memory_limit to 4096M or bigger, plz tell me how to set?! don't tell me set to -1. thx.

PS: my server have 32GB memory.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Jun 19 17:01:33 2024 UTC