[comp.unix.wizards] Needing newgrp on 4bsd...

mwm%violet.Berkeley.EDU@BERKELEY.EDU (03/24/87)

I once had to have newgrp for 4bsd. I was running a system for a
consulting firm that had a many-many relationship between engineers
and projects (customers). We wanted everybody (about 15 people) to be
able to work on all the project (about 400), and we needed to charge
projects for disk useage and CPU time.

400 groups per user is a bit much.

The solution was to write a "newgrp" (called "project") that changed
your real group id to the given group. People could then start shells
to be billed to specific projects with project, and use the nice BSD
job control to bounce back and forth between projects when one was
busy. The management loved it. So did most of the staff.

In the process, I discovered that group set/group id semantics are
_not_ clean. While I don't have that code anymore (at least, I don't
think so), I'd be glad to describe what has to happen to make such
work.

	<mike