home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.hp
- Path: sparky!uunet!ukma!wupost!sdd.hp.com!scd.hp.com!hpscdm!cupnews0.cup.hp.com!pasq
- From: pasq@cup.hp.com (Mark Di Pasquale)
- Subject: Re: owner of a process
- Sender: news@cupnews0.cup.hp.com
- Message-ID: <BxBoMr.8z3@cup.hp.com>
- Date: Sat, 7 Nov 1992 01:40:03 GMT
- References: <1992Nov4.152939.14166@lmpsbbs.comm.mot.com>
- Organization: Hewlett-Packard
- X-Newsreader: TIN [version 1.1.4 PL6]
- Lines: 25
-
- Steve Bennett (bennett@areaplg2.corp.mot.com) wrote:
- : Does anyone know how to get the owner of a process from the process id. I get the
- : source to the bsd source of ps but it uses kvm routines which do not appear to
- : exist on the HP700's What I am trying to do is write a secure version of renice
- : that allows a users to turn the priority of jobs they own up or down.
- : Unfortunately, the setpriotity syscall only allows users other that root to turn
- : their own priority down (lower).
-
- If you can get the process ID, contained in the same process structure
- is the UID for that process. With the UID, you can get the name of
- owner by using getpwuid(3C).
-
- --
- Regards,
- Mark DiPasquale, GSY Support Planning & Training
-
- _______ ________________________________________________________________
- /
- / Mark DiPasquale c/o Hewlett-Packard
- ____ ___ / 19111 Pruneridge Avenue, MS 44M9
- / / / / Cupertino, CA 95014
- __/ __/ _____/ Email: pasq@cup.hp.com
- / Phone: (1/408) 447-0911 FAX: (1/408) 447-0177
- ___________ __/ __________________________________________________________
-
-