Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Mar 2005 21:00:19 +0000
From:      Alan Milford <alz@evilalz.net>
To:        freebsd-hackers@freebsd.org
Subject:   Process Control
Message-ID:  <42408763.7010106@evilalz.net>

next in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Someone recently asked me the best way to control the number of
foreground and background processes a user can run on the system. I had
a prod around in a few places and pondered the concept of getting the
kernel to limit the max number of processes in login.conf, as sort of
sub-limits of maxproc.

The best way I could come up with doing this kernel-side is by watching
a process' P_CONTROLT flag when a process is created (or tries to fork).
If the process had the flag, I assumed it to be foreground, if not,
background.

If anyone has any other suggestions on how to distinguish fg/bg apart,
or on the concept in general, I'd appreciate some feedback!

Regards,


Alan
- --
Alan 'alz' Milford
email: alz@evilalz.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (MingW32)

iD8DBQFCQIdjq48BsFB7OgARAm5JAKDARB5qlommW29kibdG3M9fvGNs4gCgiFbt
hEJfK4ZmzP9UgCTXtQsV8Vo=
=o7lf
-----END PGP SIGNATURE-----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?42408763.7010106>