etcd snapshot action is broken #285

Closed
jonathanmarsaud opened this Issue May 12, 2017 · 1 comment

Comments

Projects
None yet
4 participants

jonathanmarsaud commented May 12, 2017

Hi,

I just discovered that running juju run-action etcd/<x> snapshot incorrectly launch the associated etcdctl command as it miss one subdirectory:

unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot ++ action-get target
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + ETCD_BACKUP_TARGET_DIR=/home/ubuntu/etcd-snapshots
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + ETCD_DATA_DIR=/var/snap/etcd/current/
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot ++ date +%Y-%m-%d-%H.%M.%S
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + DATE_STAMP=2017-05-12-14.06.46
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + ARCHIVE=etcd-snapshot-2017-05-12-14.06.46.tar.gz
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + mkdir -p /home/ubuntu/etcd-snapshots/
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot + /snap/bin/etcd.etcdctl backup --data-dir /var/snap/etcd/current/ --backup-dir /home/ubuntu/etcd-snapshots/747cca99-1cbb-41a3-8d85-84f011fd94e2
unit-etcd-0: 14:06:46 INFO unit.etcd/0.snapshot 2017-05-12 14:06:46.582595 I | open /var/snap/etcd/current/member/snap: no such file or directory
unit-etcd-0: 14:06:46 INFO juju.worker.uniter no operations in progress; waiting for changes

open /var/snap/etcd/current/member/snap: no such file or directory <= the correct path is /var/snap/etcd/current/etcd2.etcd/member/snap in this example.

Version:

Model Controller Cloud/Region Version
default cdk manual 2.0.3

App Version Status Scale Charm Store Rev OS Notes
easyrsa 3.0.1 active 1 easyrsa jujucharms 9 ubuntu
etcd 2.3.8 active 5 etcd jujucharms 30 ubuntu
flannel 0.7.0 active 8 flannel jujucharms 15 ubuntu
kubeapi-load-balancer 1.10.0 active 1 kubeapi-load-balancer jujucharms 11 ubuntu exposed
kubernetes-master 1.6.2 active 3 kubernetes-master jujucharms 19 ubuntu
kubernetes-worker 1.6.2 active 5 kubernetes-worker jujucharms 23 ubuntu exposed

Regards,

SaMnCo commented Jul 3, 2017

Also affected by this bug.

@tvansteenburgh tvansteenburgh added this to the 2017.07.21 milestone Jul 3, 2017

@tvansteenburgh tvansteenburgh changed the title from juju run-action etcd/<x> snapshot does not use the right path for etcdctl backup command to etcd snapshot action is broken Jul 7, 2017

@ktsakalozos ktsakalozos referenced this issue in juju-solutions/layer-etcd Jul 12, 2017

Merged

Fix snapshot bug #100

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment