Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Change forked process' name

Posted on 2007-11-18
3
1,117 Views
Last Modified: 2008-10-10
Hi all

OS: RHEL4

Is there a way to change a forked process` name?

I have seen this behavior by a lot of daemons, and a daemon is what I'm making.

I have one main thread that listens for incoming connections, then spawns a child to deal with it. I would like the child to show up in TOP as

mydaemon serving <hostname>

Most I could find were some shady links on Google pertaining C programming.

Good luck!
0
Comment
Question by:x_terminat_or_3
3 Comments
 
LVL 43

Accepted Solution

by:
ravenpl earned 500 total points
ID: 20310854
http://manpages.courier-mta.org/htmlman2/prctl.2.html
But it works for 2.6.9+
Otherwise You can't, except the following may (maybe) work http://www.uofr.net/~greg/processname.html
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question