/proc/<pid>/cmdline and udhcpcd

Bob Dunlop bob.dunlop at xyzzy.org.uk
Wed Mar 26 13:34:22 UTC 2014


Hi,

> As I've written in a previous message, I know nothing of such other
> programs, but I'd be intrested to learn more.

Modifying argv[] has been around since V6 unix to my knowledge.
Some games used to modify it so other users could see your score
via ps etc.  Some programs even had non-frivolous uses.

BSD had the setproctitle() function specifically for this purpose
and the linux kernel /proc/*/cmdline code has comments refering
to this even though linux libc does not contain the function.

Several people have implemented varients of setproctitle() see [1].

Several scripting languages (Python and PHP that I know of) have
setproctitle() implementations although the implementations are
poor/buggy on linux by all accounts.

[1] http://stupefydeveloper.blogspot.co.uk/2008/10/linux-change-process-name.html

-- 
        Bob Dunlop


More information about the busybox mailing list