From cda690e94f5f29df0d225e9a2074e896bea76f03 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Mon, 8 Jul 2019 10:19:41 -0400 Subject: [PATCH] Set RADOS df information in ZK --- node-daemon/pvcd/Daemon.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/node-daemon/pvcd/Daemon.py b/node-daemon/pvcd/Daemon.py index 386afec9..6e34aef4 100644 --- a/node-daemon/pvcd/Daemon.py +++ b/node-daemon/pvcd/Daemon.py @@ -916,6 +916,21 @@ def update_zookeeper(): logger.out('Failed to set Ceph status data', state='e') return + # Set ceph rados df information in zookeeper (primary only) + if this_node.router_state == 'primary': + if debug: + print("Set ceph rados df information in zookeeper (primary only)") + # Get rados df info + retcode, stdout, stderr = common.run_os_command('rados df') + rados_df = stdout + try: + zkhandler.writedata(zk_conn, { + '/ceph/radosdf': str(rados_df) + }) + except: + logger.out('Failed to set Rados space data', state='e') + return + # Set pool information in zookeeper (primary only) if this_node.router_state == 'primary': if debug: