No cron jobs when leader is removed

Bug #1440862 reported by Andreas Hasenack
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Landscape Charm
Fix Released
High
Данило Шеган

Bug Description

To test https://bugs.launchpad.net/landscape-charm/+bug/1439555 I deployed the trunk landscape-server charm with https://pastebin.canonical.com/128901/.

Verified that landscape-server/0 had RUN_CRON=yes in /etc/default/landscape-server.

I then deployed another unit of landscape-server, and verified that it had RUN_CRON=no

Finally, I destroyed the first unit, expecting the second one to become the "leader" and have RUN_CRON switched to yes. That didn't happen:

andreas@nsn7:~/deployer-configs/trusty/landscape-server$ juju destroy-unit landscape-server/0
andreas@nsn7:~/deployer-configs/trusty/landscape-server$ juju debug-log
unit-haproxy-0[902]: 2015-04-06 19:18:56 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 #015Reading package lists... 0%#015#015Reading package lists... 0%#015#015Reading package lists... 1%#015#015Reading package lists... 11%#015#015Reading package lists... 11%#015#015Reading package lists... 36%#015#015Reading package lists... 53%#015#015Reading package lists... 53%#015#015Reading package lists... 59%#015#015Reading package lists... 59%#015#015Reading package lists... 78%#015#015Reading package lists... 84%#015#015Reading package lists... 84%#015#015Reading package lists... 88%#015#015Reading package lists... 88%#015#015Reading package lists... 90%#015#015Reading package lists... 90%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 93%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 94%#015#015Reading package lists... 96%#015#015Reading package lists... 96%#015#015Reading package lists... 97%#015#015Reading package lists... 97%#015#015Reading package lists... 99%#015#015Reading package lists... 99%#015#015Reading package lists... 99%#015#015Reading package lists... 99%#015#015Reading package lists... Done
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 #015Building dependency tree... 0%#015#015Building dependency tree... 0%#015#015Building dependency tree... 50%#015#015Building dependency tree... 50%#015#015Building dependency tree
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 #015Reading state information... 0%#015#015Reading state information... 4%#015#015Reading state information... Done
machine-0: 2015-04-06 19:18:53 ERROR juju.rpc server.go:554 error writing response: write tcp 10.96.3.193:45008: broken pipe
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.juju-log cmd.go:247 reverseproxy:22: Unit 'landscape-server/1' overrides 'services', skipping further processing.
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.juju-log cmd.go:247 reverseproxy:22: Service: landscape-https
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.juju-log cmd.go:247 reverseproxy:22: Service: landscape-http
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.juju-log cmd.go:247 reverseproxy:22: Using self-signed certificate
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.juju-log cmd.go:247 reverseproxy:22: Required config not found or invalid (metrics_target, metrics_sample_interval), disabling metrics
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 Configuration file is valid
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 * Reloading haproxy haproxy
unit-haproxy-0[902]: 2015-04-06 19:18:57 INFO unit.haproxy/0.reverseproxy-relation-departed logger.go:40 ...done.
machine-0-lxc-7[846]: 2015-04-06 19:19:00 ERROR juju.worker runner.go:208 fatal "machiner": agent should be terminated
machine-0-lxc-7[846]: 2015-04-06 19:19:00 ERROR juju.api.watcher watcher.go:84 error trying to stop watcher: connection is shut down
machine-0-lxc-7[846]: 2015-04-06 19:19:00 ERROR juju.worker runner.go:208 fatal "api-post-upgrade": agent should be terminated
machine-0-lxc-7[846]: 2015-04-06 19:19:00 ERROR juju.worker runner.go:208 fatal "upgrader": connection is shut down
machine-0-lxc-7[846]: 2015-04-06 19:19:00 ERROR juju.worker runner.go:208 fatal "api": agent should be terminated

$ juju run --service landscape-server 'sudo grep RUN_CRON /etc/default/landscape-server'
# To run cron jobs on this server when RUN_ALL="no" set RUN_CRON to "yes".
RUN_CRON="no"
sudo: unable to resolve host juju-machine-0-lxc-10

Related branches

tags: removed: kanban
Changed in landscape-charm:
assignee: nobody → Данило Шеган (danilo)
tags: added: squad-beta upgradable-charm
Changed in landscape-charm:
milestone: none → 1.0
Changed in landscape-charm:
status: New → In Progress
Changed in landscape-charm:
status: In Progress → Fix Committed
Changed in landscape-charm:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.