开发者

very large memory allocation in 64-bit linux

开发者 https://www.devze.com 2023-01-31 13:56 出处:网络
I am trying to allocate a single very large piece of memory (>2.5gb) on a centos 64-bit linux. The hardware has more than 16gb physical memory. However, when I use malloc or calloc, they return null.

I am trying to allocate a single very large piece of memory (>2.5gb) on a centos 64-bit linux. The hardware has more than 16gb physical memory. However, when I use malloc or calloc, they return null. The code run开发者_C百科s in root account, and as far as I checked with ulimit there is no limit on memory allocation. What can be the problem ?

Thanks.

Mete


Google the sbrk routine, it will help you.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号