/etc/security/limits.conf NIS netgroup support

Hi there,

I am trying to set a ulimit max in the /etc/security/limits.conf against a NIS netgroup (which contains a whole bunch of users) instead of a local user or group.

so I have a NIS netgroup called +@myusers , none of whose users are defined locally on the box. I want to ensure that this setting is applied when they log onto the box, but I cant seem to get it working

It works fine against a local group (defined in /etc/group)

@localgroup       hard    nofile          8192
@localgroup       soft    nofile          8192

but if i try to get it to resolve against a NIS netgroup like this

@myusers       hard    nofile          8192
@myusers       soft    nofile          8192

or

+@myusers       hard    nofile          8192
+@myusers       soft    nofile          8192

The users continue to get given the default ulimit value (1024) for the 'nofile' configurable.

 
$ ulimit -a
...
nofile                         (-n)  1024
...
 

I cant see anything that says explicitly that NIS netgroups are not supported but likewise cant see anything to tell me how to get it working

any help on this would be greatly appreciated

Cheers
Gary

AFAIK, pam_limits doesn't do NIS... you could certainly hack the code and make it do NIS groups though.

If it were me... if this is for shell... I'd put a small script into the /etc/profile (or whatever is appropriate) and set the limits there by scripting and checking netgroup membership. But that's just me...

@rethink do you mean nis netgroups or nis groups?

If you want to apply a common setting to a bunch of users in limits.conf, you would have success if you created a nis group and using that instead.