Re: more than 32 groups per user

Nick Burrett (nick@dsvr.net)
12 Jul 1999 14:41:45 +0100


Christopher McCrory <chrismcc@netus.com> writes:

> Hello...
>
>
> lucas vossberg wrote:
> >
> > hi,
> >
> > i 'm trying to raise the 32-groups-per-user limit in my 2.0.33 kernel
> > running on a single cpu pentium system.
> >
> > is it a possible and safe way to raise the limit to 64 or even more by just
> > setting NGROUPS_MAX in include/linux/limits.h?
>
> Almost... (someone correct me if I am wrong)
>
> You need to patch /PATH/linux/include/linux/limits.h and
> /PATH/linux/include/ARCH/param.h
> with:
> -#define NGROUPS 32
> +#define NGROUPS 256
>
> Then patch glibc also with the same patch, otherwise it won't work.
> With glibc2, you need the patch the sources. With glibc2.1 the
> paramaters are gotten out of the running kernel (could be the kernel
> source though). When both are done you should be OK. Try this on a
> devel machine first!
>
> ftp://admin.netus.com/OLD/glibc/glibc-2.0.7.NG265.patch
> and
> ftp://admin.netus.com/pub/hello is a quicky program to show the limits
> sample:
> [www@sc tmp]$ ./hello
> _SC_NGROUPS_MAX 256 end
> _SC_LOGIN_NAME_MAX 9 end
> Num groups 78 end
> I can't find the source to that right now though... :(

You need to look out for other packages that use NGROUPS as a compile
time constant e.g. shadow-utils. You'd have to rebuild all those
packages as well.

Probably better to fix your kernel and glibc and then re-build all
packages.

Nick.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/