Hi, I am having problems getting cfengine to keep promises. I admit that I am completely new to cfengine and have only been working with it for a few weeks now. I am using Automating Linux and Unix System Administration, second edition as my primary reference, with a smattering of other resources. The fun part about cfengine is that every time I think I am starting to get my head around it, my brain falls out on the floor. :)
I have set up a server on a openvz container called worf (based on Chapters 5 and 7, for those of you keeping score). cfagent.conf is all imports, and the basic configuration seemed to do what it was told (cron entries and ntp -- I disabled the motd, since I didn't need it for my test network), except that it wants to move the symlink that Debian creates from /var/lib/cfengine2/inputs -> /etc/cfengine and create a real directory...Even though in my directories directive I have directories: any:: $(workdir)/backups mode=700 owner=root group=root $(workdir)/outputs mode=700 owner=root group=root $(workdir)/ppkeys mode=700 owner=root group=root $(workdir)/cfengine/sums mode=700 owner=root group=root $(workdir)/tmp mode=700 owner=root group=root !debian:: $(workdir)/bin mode=700 owner=root group=root $(workdir)/inputs mode=700 owner=root group=root and in links, I have links: !debian:: $(workdir)/bin/cfagent -> $(cf_base_path)/cfagent define=hupcfexecdandcfservd debian:: $(workdir)/inputs -> /etc/cfengine So right now, I have an ntp script working. I tried to add a second script to manage syslog-ng. I am looking to a) make sure the target is using the right syslog-ng, b) if not, replace and restart, and c) make sure that syslog-ng is running. It is doing none of these. In fact, when I run a cfagent -v, the only reference to it in any of my runs was when the cf.syslog-ng was copied to /var/lib/cfengine2/inputs/... I tried doing a cfagent -d -v, but the amount of output was a lot to wade through...And I'm still trying to make heads or tails of it. There were more references to cf.syslog-ng, but nothing immediately jumped out at me telling me why it was failing. My cf.syslog-ng is as follows: classes: logserver = ( "/usr/bin/test -d /var/log/master" ) ng_hosts = ( "/usr/bin/test -d /etc/syslog-ng" ) control: AddInstallable = ( restartsyslog ) AllowRedefinitionOf = ( syslog_conf_file ) syslog_conf_dest = ( /etc/syslog-ng/syslog-ng.conf ) syslog_conf_source = ( syslog-ng.conf.client ) logserver:: syslog_conf_source = ( syslog-ng.conf.server ) files: $(syslog_conf_dest) mode=0644 owner=root group=root copy: $(master_etc)/syslog-ng/$(syslog_conf_source) dest=$(syslog_conf_dest) mode=644 type=checksum server=$(fileserver) encrypt=true owner=root group=root define=restartsyslog shellcommands: restartsyslog:: "/etc/init.d/syslog-ng restart" timeout=30 inform=true processes: "syslog-ng" restart "/etc/init.d/syslog-ng restart" timeout=30 inform=true and in cfagent.conf ng_hosts:: tasks/os/cf.syslog-ng I can provide more information as needed, but I wasn't sure what the protocol for this list wrt large posts. Could someone help me to figure this out? Thanks, --b
_______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine