rsyslog step in juju-restore is outdated and breaks the restore

Bug #1295650 reported by Horacio Durán
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
High
Horacio Durán

Bug Description

Andrew Wilkins said:

We no longer write rsyslog configuration at bootstrap time, but instead it's managed by a worker in jujud.
The upshot is we should be able to just remove anything to do with rsyslog from the restore plugin. It should fix itself up when the agent starts up. Note this is only true for >=1.18, so we may want a version check in there.

In current trunk version we get upon attempting a restore:

+ cd /var/lib/juju/agents
+ for agent in '*'
+ initctl stop jujud-machine-1
jujud-machine-1 stop/waiting
+ sed -i.old -r '/^(stateaddresses|apiaddresses):/{
                n
                s/- .*(:[0-9]+)/- ec2-54-205-27-132.compute-1.amazonaws.com/
        }' machine-1/agent.conf
+ [[ machine-1 = unit-* ]]
+ initctl start jujud-machine-1
jujud-machine-1 start/running, process 5101
jujud-unit-ubuntu-0 stop/waiting
jujud-unit-ubuntu-0 start/running, process 5106
+ for agent in '*'
+ initctl stop jujud-unit-ubuntu-0
+ sed -i.old -r '/^(stateaddresses|apiaddresses):/{
                n
                s/- .*(:[0-9]+)/- ec2-54-205-27-132.compute-1.amazonaws.com/
        }' unit-ubuntu-0/agent.conf
+ [[ unit-ubuntu-0 = unit-* ]]
+ sed -i -r 's/change-version: [0-9]+$/change-version: 0/' 'unit-ubuntu-0/state/relations/*/*'
sed: can't read unit-ubuntu-0/state/relations/*/*: No such file or directory
+ true
+ initctl start jujud-unit-ubuntu-0
+ sed -i -r 's/^(:syslogtag, startswith, "juju-" @)(.*)(:[0-9]+.*)$/ec2-54-205-27-132.compute-1.amazonaws.com/' '/etc/rsyslog.d/*-juju*.conf'
sed: can't read /etc/rsyslog.d/*-juju*.conf: No such file or directory

This bug is being fixed on under the context of #1291022

Related branches

Curtis Hovey (sinzui)
Changed in juju-core:
status: New → Triaged
importance: Undecided → High
tags: added: backup-restore
Changed in juju-core:
milestone: 1.18.0 → changelog.txt
status: Triaged → In Progress
Changed in juju-core:
milestone: changelog.txt → 1.17.7
Martin Packman (gz)
Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui)
Changed in juju-core:
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.