1837121 Members
11223 Online
110112 Solutions
New Discussion

LINE_MAX 2048 ??

 
SOLVED
Go to solution
nitren
Frequent Advisor

LINE_MAX 2048 ??

Hi!

Is there a work around for inserting more than 450 users to a group in /etc/group file avoiding "line too long" msg?
HP-UX 11.00.

Rgds

NilsI
2 REPLIES 2
Robert-Jan Goossens
Honored Contributor
Solution

Re: LINE_MAX 2048 ??

Hi Nils,

Yes there is. Add a group with the same groupnumber in the etc group file.

oracle::1000:oracle
oracle01::1000:gorj,etc,etc.

Regards,
Robert-Jan.
A. Clay Stephenson
Acclaimed Contributor

Re: LINE_MAX 2048 ??

No, and this is a very common problem in NIS maps but what you can do is create multiple groups with a common group id:

grp1::125:tom,dick,harry
grp1a::125:huey,louie,dewey
grp1b::125:donald,daffy,yacky

If you are using NIS then it is very important for users who are members of multiple groups to be listed in the first group because only the first will be picked up by the NIS map. The other thing to note (NIS or not) is that it is only important to list those users who will be changing groups in the groups file because they are implicitly members of the group defined in their passwd entry. Thus one method to limit the size of the groups entry is to simply not include those users who do not need to be members of more than one group.

If it ain't broke, I can fix that.