Comment 4 for bug 1859869

Revision history for this message
Faiz Ahmed (faizahmedfarooqui) wrote :

I removed and redeployed apps cinder, cinder-ceph and cinder-backup and since then all nova-compute units are throwing the same hook error ie. "ceph-access-relation-changed".

I tried using "juju debug-hooks nova-compute/0" and reran the same hook ie. ceph-access-relation-changed - I have shared below the error.

```
root@nova-compute:/var/lib/juju/agents/unit-nova-compute-0/charm# ./hooks/ceph-access-relation-changed ./hooks/ceph-access-relation-changed
error: Failed to set attributes from /etc/ceph/secret-cinder-ceph.xml
error: internal error: a secret with UUID 9dbed743-60b0-4544-9817-ce732fb4de61 already defined for use with client.cinder-ceph secret

Traceback (most recent call last):
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/./hooks/ceph-access-relation-changed", line 1022, in <module>
    main()
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/./hooks/ceph-access-relation-changed", line 1015, in main
    hooks.execute(sys.argv)
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/hooks/charmhelpers/core/hookenv.py", line 963, in execute
    self._hooks[hook_name]()
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/./hooks/ceph-access-relation-changed", line 902, in ceph_access
    _configure_keyring(remote_service_name(rid), key, uuid)
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/./hooks/ceph-access-relation-changed", line 883, in _configure_keyring
    create_libvirt_secret(secret_file=secrets_filename,
  File "/var/lib/juju/agents/unit-nova-compute-0/charm/hooks/nova_compute_utils.py", line 816, in create_libvirt_secret
    check_call(cmd)
  File "/usr/lib/python3.10/subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['virsh', '-c', 'qemu:///system', 'secret-define', '--file', '/etc/ceph/secret-cinder-ceph.xml']' returned non-zero exit status 1.
```