#48846 Rlimit check in dsktune and util.c does not handle RLIM_INFINITY correctly.
Closed: wontfix None Opened 5 years ago by firstyear.

RLIM_INFINITY is set to a high or low values on certain platforms. We need to be able to detect and manage this if it is set. This especially affects 32bit systems (IE embedded arm)

/* Value to indicate that there is no limit.  */                                 
#ifndef __USE_FILE_OFFSET64                                                      
# define RLIM_INFINITY ((__rlim_t) -1)                                           
#else                                                                            
# define RLIM_INFINITY 0xffffffffffffffffuLL                                     
#endif

In some cases this can prevent installation as dsktune fails, and may cause cache sizechecking to behave incorrectly.


{{{
./setup-ds.pl
ERROR : processes are limited by RLIMIT_DATA to -1 MB in size.

ERROR : processes are limited by RLIMIT_AS to -1 MB in size.

ERROR : The above errors MUST be corrected before proceeding.
}}}

It looks good to me. But please double-check that using RLIM_INFINITY does not introduce any compiler warnings...
{{{
$ egrep RLIM_INFINITY /usr/include/.h /usr/include//*.h
/usr/include/asm-generic/resource.h:#ifndef RLIM_INFINITY
/usr/include/asm-generic/resource.h:# define RLIM_INFINITY (~0UL)
/usr/include/bits/resource.h:# define RLIM_INFINITY ((__rlim_t) -1)
/usr/include/bits/resource.h:# define RLIM_INFINITY 0xffffffffffffffffuLL
}}}
Thanks!

commit 17a56db
commit b08fa7e
commit 636c89b
Writing objects: 100% (20/20), 3.08 KiB | 0 bytes/s, done.
Total 20 (delta 14), reused 0 (delta 0)
To ssh://git.fedorahosted.org/git/389/ds.git
d4eb7d0..636c89b master -> master

Metadata Update from @firstyear:
- Issue assigned to firstyear
- Issue set to the milestone: 1.3.5.5

4 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/1906

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix (was: Fixed)

a year ago

Login to comment on this ticket.

Metadata