> How does Solaris load up its tasks and know when to
> say "stop, no more please"?

You might want to take a look at the zone.max-lwps
rctl.  See resource_controls(5).  You can set this
rctl on the global zone using something like:

# prctl -n zone.max-lwps -v 1000 -r -i zone global

The problem with this for stopping a fork bomb
is that although it limits the total number of
processes, it is still really hard to administer
the system if the fork bomb is running in the global
zone.

This is where we might recommend using non-global zones.
By putting your apps into a non-global zone, you can
set the zone.max-lwps rctl for the zone and by using
that in conjunction with the fair share scheduler (FSS),
you can run a fork bomb all day in the zone and
not have much overall impact on the system as a whole.

You need to use FSS in conjunction with the rctl in
order for the other zones, or just the global zone,
to stay responsive.  Otherwise your other processes
that are not in the fork-bombed zone are still having
to contend for scheduling time with the fork bomb.
FSS solves this problem and zones make it easy to
manage all of this.

We are also working to make setting up this configuration
even easier.  See:

http://www.opensolaris.org/os/community/arc/caselog/2006/496/

To set this up, you would configure zone.max-lwps and zone.cpu-shares
on the non-global zone and set up FSS as the default scheduler using
dispadmin(1M).

Jerry
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to