Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!elroy.jpl.nasa.gov!jato!csi.jpl.nasa.gov!mwette From: mwette@csi.jpl.nasa.gov (Matt Wette) Newsgroups: comp.unix.admin Subject: wanted: way to inforce a nice'd login. Message-ID: <1991Jun13.212644.25754@jato.jpl.nasa.gov> Date: 13 Jun 91 21:26:44 GMT Sender: nobody@jato.jpl.nasa.gov Reply-To: mwette@csi.jpl.nasa.gov (Matt Wette) Organization: Jet Propulsion Laboratory, Pasadena, CA Lines: 33 Nntp-Posting-Host: mr-ed.jpl.nasa.gov We have users who refuse to run number-crunching programs suitably "nice"d on our server, often resulting in several users' workstations being locked up waiting for access. Is there any way to have the user's login run at a suitable nice value? I heard that some login's look for a "pri=n" string in the GCOS field. However, on our Sun (SunOS4.1) this doesn't seem to work (i.e., GCOS is :pri=10,Name,office,phone:). I've even tried to run a C program which nices itself and then execs /bin/csh ... #ifndef NICEVAL #define NICEVAL 10 #endif main(argc, argv) int argc; char *argv[]; { setpriority(0, getpid(), NICEVAL); execl("/bin/csh", "-csh", (char *)0); } but this doesn't always seem to work (can't remember why). Am I doing something wrong here? Matt frustrated system administrator -- _________________________________________________________________ Matthew R. Wette | Jet Propulsion Laboratory, 198-326 mwette@csi.jpl.nasa.gov | 4800 Oak Grove Dr, Pasadena,CA 91109 -----------------------------------------------------------------