[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: shellcommands not executing - lock problem?
From: |
Russell Adams |
Subject: |
Re: shellcommands not executing - lock problem? |
Date: |
Tue, 24 Feb 2004 11:41:16 -0600 |
User-agent: |
Mutt/1.5.6i |
I was thinking that perhaps there was a limit, like the lockname was
truncated before comparison...
Looking in lock.c (no expert, but thought I'd check the code before I
opened my mouth), it often uses the first 100 chars of the operator,
so you'd get:
shellcommand._gweb._bin_su___gweb__l__c___usr_bin_rsync__rltvv___delete_gweb_nue_gentoo_org__var_www_www_gentoo_org_stage_site_images___var_www_www_gentoo_org_images__
truncated to:
shellcommand._gweb._bin_su___gweb__l__c___usr_bin_rsync__rltvv___delete_gweb_nue_gentoo_org__var_www_www_gentoo_org_stag
which would mean the locks were most likely identical for those two
operations.
The path munging workaround should still work.
Am I totally offbase above?
Russell
On Tue, Feb 24, 2004 at 06:21:14PM +0100, Mark.Burgess@iu.hio.no wrote:
>
> Ah - perhaps it is because the strings are so similar, and cfagent restricts
> the
> keys length....they end up with the same key..
> Try reordering the options on one of the lines...?
>
> M
>
> On 24 Feb, Kurt Lieber wrote:
> > On Tue, Feb 24, 2004 at 05:51:22PM +0100 or thereabouts,
> > Mark.Burgess@iu.hio.no wrote:
> >> If something caused the agent to crash while the shellcommand was running
> >> the lock will have to wait until expiredafter time is reached before
> >> it will be removed. You can always delete the lock database to check.
> >> /var/cfengine/cfengine_lock_db
> >
> > That's the odd thing -- the second command *never* gets run while the other
> > two *always* get run, even though they're in the same shellcommands stanza.
> > We've been trying to make it work for a couple weeks now.
> >
> >> > shellcommands:
> >> > _gweb.slave_webnode.slave_web_sync::
> >> > "/bin/su - gweb -l -c '/usr/bin/rsync -rltvv --delete
> >> > gweb@$(_master_node):$(web_stage_html)/ $(web_html)/'"
> >> > "/bin/su - gweb -l -c '/usr/bin/rsync -rltvv --delete
> >> > gweb@$(_master_node):$(web_stage_images)/ $(web_images)/'"
> >> > "/bin/su - gweb -l -c '$(web_scripts)/rsync-weblogs.sh'"
> > [snip]
> >> > cfengine:nue: Nothing scheduled for
> >> > shellcommand._gweb._bin_su___gweb__l__c___
> >> > usr_bin_rsync__rltvv___delete_gweb_nue_gentoo_org__var_www_www_gentoo_org_stage
> >> > _site_images___var_www_www_gentoo_org_images__ (0/1 minutes elapsed)
> >
> > Just to make sure, I deleted /var/cfengine/cfengine_lock_db on one of the
> > servers and re-ran the command. Same problem.
> >
> > Also, this behavior is consistent across all three boxes that this
> > particular stanza runs on. It *never* works on any of the boxes unless we
> > use the -K option.
> >
> > --kurt
>
>
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Work: +47 22453272 Email: Mark.Burgess@iu.hio.no
> Fax : +47 22453205 WWW : http://www.iu.hio.no/~mark
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
> _______________________________________________
> Help-cfengine mailing list
> Help-cfengine@gnu.org
> http://mail.gnu.org/mailman/listinfo/help-cfengine
- shellcommands not executing - lock problem?, Kurt Lieber, 2004/02/24
- Re: shellcommands not executing - lock problem?, Mark . Burgess, 2004/02/24
- Re: shellcommands not executing - lock problem?, Kurt Lieber, 2004/02/24
- Re: shellcommands not executing - lock problem?,
Russell Adams <=
- Re: shellcommands not executing - lock problem?, Chip Seraphine, 2004/02/24
- Re: shellcommands not executing - lock problem?, Eric Sorenson, 2004/02/24
- Re: shellcommands not executing - lock problem?, Pete Ehlke, 2004/02/25
- Re: shellcommands not executing - lock problem?, Mark . Burgess, 2004/02/25
- Re: shellcommands not executing - lock problem?, Adrian Phillips, 2004/02/25
Re: shellcommands not executing - lock problem?, Russell Adams, 2004/02/24