[torqueusers] -l file=xxx parameter limited to 2Gb-1 max on Linux

Wightman wightman at clusterresources.com
Thu Feb 3 13:57:10 MST 2005


Thanks,
We had a few sites reporting this same issue and it has been patched in
the latest snapshot (1.2.0b0).

Let us know if you continue to see issues,

- Douglas
Cluster Resources, INC.




On Thu, 2005-02-03 at 16:59 +0100, Marcin Mogielnicki wrote:
> Hello,
> 
> There is one more thing I noticed. Every time a job chosen to start by 
> mom is fails, if file parameter is greater or equal to two gigabytes. I 
> think is is another hardcoded example of infamous file size limit. It 
> fails exactly here:
> 
> halo g # grep -B 7 RLIMIT_FSIZE torque-1.1.0p6/src/resmom/linux/mom_mach.c
>          if (value > INT_MAX)
>            {
>            return(error(pname,PBSE_BADATVAL));
>            }
> 
>          reslim.rlim_cur = reslim.rlim_max = value;
> 
>          if (setrlimit(RLIMIT_FSIZE,&reslim) < 0)
> 
> As you can see mom decides that setrlimit manages values not greater 
> than INT_MAX. However it is not true:
> 
> halo g # grep -A 3 rlimit /usr/include/linux/resource.h
> struct rlimit {
>          unsigned long   rlim_cur;
>          unsigned long   rlim_max;
> };
> 
> I don't know when it was changed from int to ulong, but all my linux 
> servers, even installed 2-3 years ago, devine RLIMIT_FSIZE values as 
> ulong, so I think it should be changed in the way given below. It works 
> for me for some time, users are able to request tens of gigabytes and 
> they really are unable to write anything when they reach given limit.
> 
> 	Marcin Mogielnicki
> 
> diff -r -u torque-1.1.0p6.orig/src/resmom/linux/mom_mach.c 
> torque-1.1.0p6/src/resmom/linux/mom_mach.c
> --- torque-1.1.0p6.orig/src/resmom/linux/mom_mach.c     2005-01-13 
> 03:02:01.000000000 +0100
> +++ torque-1.1.0p6/src/resmom/linux/mom_mach.c  2005-02-02 
> 21:24:20.580571291 +0100
> @@ -1094,7 +1094,8 @@
>             return(error(pname,retval));
>             }
> 
> -        if (value > INT_MAX)
> +        if (value > ULONG_MAX)
>             {
>             return(error(pname,PBSE_BADATVAL));
>             }
> _______________________________________________
> torqueusers mailing list
> torqueusers at supercluster.org
> http://supercluster.org/mailman/listinfo/torqueusers



More information about the torqueusers mailing list