Bug 410311

Summary: New kernel syscall sys_rlimit64 for resource limits
Product: Red Hat Enterprise Linux 4 Reporter: Adam Stokes <astokes>
Component: kernelAssignee: Jerome Marchand <jmarchan>
Status: CLOSED INSUFFICIENT_DATA QA Contact: Martin Jenner <mjenner>
Severity: low Docs Contact:
Priority: high    
Version: 4.6CC: gss-xmlrpc
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-06-24 14:08:17 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Adam Stokes 2007-12-04 13:08:10 UTC
Description of problem:
In this particular case users of ppc64 are unable to set things like memlock
higher than 4G

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
Set memlock higher than 4G in /etc/security/limits.conf

This simple application shows its effect :
#include <sys/resource.h>
#include <stdio.h>
#include <stdlib.h>

int main ()
  struct rlimit rlim;
  rlim.rlim_max = 5961560;
  rlim.rlim_cur = rlim.rlim_max;

  if ( setrlimit(8, &rlim) < 0) {
    fprintf(stderr,"Failed to set memlock max\n");
  fprintf(stderr,"rlim_cur: %ld\n",rlim.rlim_cur);
  return 1;
Actual results:
Fails to set memlock higher than 4G.

Expected results:
Allow for higher threshold

Additional info:

Comment 1 Linda Wang 2008-06-06 10:18:57 UTC
if you are using 4.6.9, then it is RHEL4 not RHEL5.
In RHEL4, have you try the PPC64 largesmp version of the kernel?

Comment 2 Vitaly Mayatskikh 2008-06-09 13:47:55 UTC
Hardlimit for memlock is set in compile time and equals to 8 pages (32kb). And
it is not possible to increase hardlimit value in run time. Adam, can you
provide us with more information?

Comment 4 Jerome Marchand 2010-06-24 12:31:56 UTC
I can not reproduce the issue, neither on RHEL4.6 nor on more recent 4.8. 
If you still experience problem, please provide us with more info:
 - what exact kernel version do you use,
 - what error do you get.