Movatterモバイル変換


[0]ホーム

URL:


D. J. Bernstein
UNIX
daemontools

The readproctitle program

readproctitlemaintains an automatically rotated log in memoryfor inspection byps.

readproctitleis available in daemontools 0.75 and above.

Interface

     readproctitleLD
L consists of any number of arguments.D is one argumentconsisting of at least five dots.

readproctitle reads data into the end ofD,shiftingD to the left to make room.This means that the most recent datais visible to process-listing tools such asps.readproctitle always leavesthree dots at the left ofD.

For example, if

     readproctitle io errors: ....................
reads the data
     fatal error xyz     warning abc
then its command-line arguments change to
     readproctitle io errors: ... xyz!warning abc!
with a newline character in place of each!.Process-listing tools typically show the newline characteras? or\n.

readproctitle exits when it reaches the end of input.

Beware that most implementations ofpshave small argument-length limits.These limits apply to the total length ofreadproctitleLD.I have not seen a system with a limit below 512 bytes.


[8]ページ先頭

©2009-2025 Movatter.jp