cf-agent receiving SIGINT on one client

23 views
Skip to first unread message

Bob

unread,
Dec 1, 2016, 9:29:42 AM12/1/16
to help-cfengine
I have one client and I keep getting this message:

Received signal 15 (SIGTERM) while doing [lock.handle_users.files.edit_line.comment.-client669._etc_passwd_5524_MD5=d3e66baa4f28c36002bd5ec26282cc5a]
Logical start time Thu Dec 1 06:41:26 2016
This sub-task started really at Thu Dec 1 06:41:39 2016


When I run cf-agent from the command-line as follows:

# time cf-agent -KI -v > /tmp/cf-agent.log

real    0m25.997s
user    0m21.821s
sys     0m1.368s


The process appears to execute quickly. The logs do not appear to contain anything helpful. Clients are supposed to run once from between the top of the hour and 15 minutes passed, then again from 30 minutes past to 45 minutes past (splay time of 10 minutes). Any suggestions?

Neil Watson

unread,
Dec 1, 2016, 9:51:40 AM12/1/16
to help-cfengine
-K ignores locks so not no the same as a normal run. And the issue might
well be locks.

Can you provide the offending promise?

--
Neil H Watson @neil_h_watson
CFEngine reporting: https://github.com/neilhwatson/delta_reporting
CFEngine policy: https://github.com/neilhwatson/evolve_cfengine_freelib
CFEngine and vim: https://github.com/neilhwatson/vim_cf3

Dimitrios Apostolou

unread,
Dec 1, 2016, 10:04:48 AM12/1/16
to Bob, help-cfengine

On Thu, Dec 1, 2016 at 3:29 PM, Bob <buha...@gmail.com> wrote:
The process appears to execute quickly. The logs do not appear to contain anything helpful. Clients are supposed to run once from between the top of the hour and 15 minutes passed, then again from 30 minutes past to 45 minutes past (splay time of 10 minutes). Any suggestions?


Try raising the debug verbosity using "-d", and see at the end of the logs. And as Neil mentioned, avoid -K if you want to reproduce the issue.

Dimitris

Dimitrios Apostolou

unread,
Dec 1, 2016, 10:06:42 AM12/1/16
to Bob, help-cfengine
BTW Bob, if you are reading this, your mailbox sends auto-replies as "not being monitored". You may want to fix this. :-)

On Thu, Dec 1, 2016 at 3:29 PM, Bob <buha...@gmail.com> wrote:

--
You received this message because you are subscribed to the Google Groups "help-cfengine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to help-cfengine+unsubscribe@googlegroups.com.
To post to this group, send email to help-c...@googlegroups.com.
Visit this group at https://groups.google.com/group/help-cfengine.
For more options, visit https://groups.google.com/d/optout.

Bob

unread,
Dec 1, 2016, 3:37:49 PM12/1/16
to help-cfengine
I've shutdown cf-execd and am running cf-agent from the command-line. I am having trouble determining which promise is giving me the issue. When I run without debug, cf-agent never terminates:

# time cf-agent -I -v  > /tmp/cf-agent-nodebug.log

I killed it after about 5 minutes.

cf3>  -> Using literal pathtype for /etc/passwd
cf3>  -> Handling file existence constraints on /etc/passwd
cf3> Received signal 2 (SIGINT) while doing [lock.handle_users.files.edit_line.comment.-client669._etc_passwd_5524_MD5=d1a86dbcb3bfc531f9acff425307f584]
cf3> Logical start time Thu Dec  1 13:02:43 2016
cf3> This sub-task started really at Thu Dec  1 13:03:15 2016
cf3> Trying to remove lock - try lock.handle_users.files.edit_line.comment.-client669._etc_passwd_5524_MD5=d1a86dbcb3bfc531f9acff425307f584
cf3> Outcome of version 0.9 (agent-0): Promises observed to be kept 99%, Promises repaired 1%, Promises not repaired 0%


Next, I ran with some debug. When I do this I get a segmentation fault:

time cf-agent -I -v -d 1 > /tmp/cf-agent-debug.log

The last thing I see in the log file is different:

SkipDirLinks(/srv/cfengine3/masterfiles/files/usr/lib/firefox-esr/browser/defaults,defaults)
cf3>  ->>  Entering /usr/lib/firefox-esr/browser/defaults
VerifyCopiedFile(/usr/lib/firefox-esr/browser/defaults,+0,-0)
cf3>  -> Attempting to preserve file permissions from the source: 755
Unix_VerifyFileAttributes(/usr/lib/firefox-esr/browser/defaults -> 755)
Directory...fixing x bits
Unix_VerifyOwner: 0
File okay, newperm = 755, stat = 755
cf3>  -> File permissions on /usr/lib/firefox-esr/browser/defaults as promised
ClassAuditLog( -> File permissions on /usr/lib/firefox-esr/browser/defaults as promised)
Unix_VerifyFileAttributes(Done)
RecursiveCopy(/srv/cfengine3/masterfiles/files/usr/lib/firefox-esr/browser/defaults,/usr/lib/firefox-esr/browser/defaults,lev=999999997)
Trying to create a parent directory for /usr/lib/firefox-esr/browser/defaults/dummycf3> INFO: /usr/lib/firefox-esr/browser/defaults is a symbolic link, not a true directory!
Directory for /usr/lib/firefox-esr/browser/defaults/dummy exists. Okay


I think this is a red herring. I suspect the issue is related to adding users to the system. I was able to confirm this by removing the user management bundle from the list of sequences and cf-agent completes in under 13 seconds.

I will keep looking. Thanks for the suggestions.
Reply all
Reply to author
Forward
0 new messages