juju 1.17.5 tries to execute non-existant hooks

Bug #1293310 reported by Dave Cheney on 2014-03-17
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
High
Andrew Wilkins

Bug Description

Simple case, deploying cs:precise/ubuntu failed

  u0:
    charm: cs:precise/ubuntu-4
    exposed: false
    units:
      u0/0:
        agent-state: error
        agent-state-info: 'hook failed: "config-changed"'
        agent-version: 1.17.5.1
        machine: "1"
        public-address: ec2-54-206-179-139.ap-southeast-2.compute.amazonaws.com

Log

ubuntu@ip-10-249-71-95:~$ tail /var/log/juju/unit-u0-0.log
2014-03-17 02:54:31 INFO juju.worker.uniter modes.go:421 ModeConfigChanged starting
2014-03-17 02:54:31 DEBUG juju.worker.uniter.filter filter.go:440 discarded config event
2014-03-17 02:54:32 INFO juju.worker.uniter uniter.go:474 running "config-changed" hook
2014-03-17 02:54:32 ERROR juju.worker.uniter uniter.go:480 hook failed: fork/exec /var/lib/juju/agents/unit-u0-0/charm/hooks/config-changed: no such file or directory
2014-03-17 02:54:32 DEBUG juju.worker.uniter modes.go:423 ModeConfigChanged exiting
2014-03-17 02:54:32 INFO juju.worker.uniter modes.go:421 ModeHookError starting

ubuntu@ip-10-249-71-95:~$ sudo stat /var/lib/juju/agents/unit-u0-0/charm/hooks/config-changed
stat: cannot stat `/var/lib/juju/agents/unit-u0-0/charm/hooks/config-changed': No such file or directory

Related branches

John A Meinel (jameinel) on 2014-03-17
Changed in juju-core:
milestone: 1.18.0 → 1.17.6
Andrew Wilkins (axwalk) wrote :

In Dave's case, this is caused by the tools being built with a version of Go > 1.2, where the behaviour of os/exec.Command has changed. Our code is relying on implementation details of Command, which until 1.3 will use LookPath uncondtionally. LookPath returns the error that we check for. In 1.3, LookPath is used conditionally (not at all in our usage).

I'm told that others have come across this before with released tools. I can't speak to that.

Andrew Wilkins (axwalk) on 2014-03-17
Changed in juju-core:
assignee: nobody → Andrew Wilkins (axwalk)
status: Confirmed → In Progress
John A Meinel (jameinel) wrote :

Good to fix, but not actually Critical because it only affects when using Go trunk to build the tools, which we *don't* do for releases.

Changed in juju-core:
importance: Critical → High
Andrew Wilkins (axwalk) on 2014-03-17
Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui) on 2014-03-20
Changed in juju-core:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers