[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
"ps output line ... is shorter than its associated header"
From: |
address@hidden |
Subject: |
"ps output line ... is shorter than its associated header" |
Date: |
Thu, 14 Mar 2019 17:21:04 +0000 |
System:
RHEL 7.6
cfengine-community 3.10.3
CFEngine log files and emails for a small number of our clients have:
"ps output line '...' is shorter than its associated header"
Correspondingly the "-v" output from "cf-agent" has:
-----------
verbose: C: BEGIN classes / conditions (pass 1)
verbose: Observe process table with /bin/ps -eo
user,pid,ppid,pgid,pcpu,pmem,vsz,ni,rss:9,nlwp,stime,etime,time,args
error: ps output line 'user-id 35911 1 8597 0.0 0.0 123668 0
2504 2 Mar11 2-22:28:49 00:00:00' is shorter than its associated header
-----------
(I've obfuscated the user-id.)
Running that quoted 'ps' command manually and scanning the output, I see:
-----------
user-id 35772 1 8597 0.0 0.3 1022928 0 54292 5 Mar11
2-22:32:59 00:00:48 kleopatra
user-id 35905 1 8597 0.0 0.0 782440 0 6144 5 Mar11
2-22:32:04 00:00:28 /etc/speech-dispatcher/modules//espeak.conf
user-id 35911 1 8597 0.0 0.0 123668 0 2504 2 Mar11
2-22:32:04 00:00:00
user-id 35913 1 35913 0.0 0.0 94272 0 952 2 Mar11
2-22:32:04 00:00:00 /usr/bin/speech-dispatcher
-----------
Note that pid 35911 lacks any command-line information ("args").
(As an associated observation (clearer in a monospaced font) pid 35905 has two
spaces, rather than a single space, separating the end of the time, 00:00:28,
from the args, "/etc/speech...". This is probably irrelevant.)
Our calling bundle is doing a 'processexists("...").
It would seem that when "cf-agent" is internally invoking a 'ps' command, the
processing of the output is not cleanly allowing for an empty "args" result
(our pid 35911).
This seems to be a bug. (A quick Google search indicates that something
similar has been seen a few years ago in AIX and Solaris: CFE-2446 and
CFE-2161.) But we are RHEL7.6 Any thoughts?
Of course, this prompts again the thought about whether all this could be much
more cleanly handled on OSes that support "/proc", relegating the "ps"
mechanism to those few OSes that lack "/proc": CFE-1655. But that is probably
another story for another time...
-- David Lee
--
This e-mail and any attachments may contain confidential, copyright and or
privileged material, and are for the use of the intended addressee only. If you
are not the intended addressee or an authorised recipient of the addressee
please notify us of receipt by returning the e-mail and do not use, copy,
retain, distribute or disclose the information in or attached to the e-mail.
Any opinions expressed within this e-mail are those of the individual and not
necessarily of Diamond Light Source Ltd.
Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments
are free from viruses and we cannot accept liability for any damage which you
may sustain as a result of software viruses which may be transmitted in or with
the message.
Diamond Light Source Limited (company no. 4375679). Registered in England and
Wales with its registered office at Diamond House, Harwell Science and
Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- "ps output line ... is shorter than its associated header",
address@hidden <=