[ale] why trailing spaces for init process (RHEL5)
Danny Cox
danscox at mindspring.com
Sat May 31 12:43:17 EDT 2008
On Fri, 2008-05-30 at 10:11 -0400, Jerry Yu wrote:
> I redirected 'ps -ef' to a file for some compliance exercise. saw a
> blank line after init.
> opened it up in vi and realized the 'blank line' is not a separate
> line, but a lot of trailing spaces after the init process name. This
> is on a RHEL5/i386 server.
>
> I know init is special, but didn't notice that it is special in this
> way. anybody knows why?
>
> 1 UID PID PPID C STIME TTY TIME CMD
> 2 root 1 0 0 Apr18 ? 00:00:02 init
> [5]
> 3 root 2 1 0 Apr18 ? 00:00:00 [migration/0]
Wild speculation follows, maybe ;-)
It used to be that programs would change their names after starting by
copying another string to argv[0]. The extra spaces may be part of a
buffer to allow longer names than "init" ("telinit", etc.).
On the other hand, I don't know why init itself would masquerade as any
other program. Busybox, on the other hand.... ;-)
>
> _______________________________________________
> Ale mailing list
> Ale at ale.org
> http://mail.ale.org/mailman/listinfo/ale
--
kernel, n.: A part of an operating system that preserves the
medieval traditions of sorcery and black art.
Danny
More information about the Ale
mailing list