Only trigger pool updates on primary

This commit is contained in:
Joshua Boniface 2019-06-18 21:26:05 -04:00
parent 612f5ab52c
commit 2bbbda3da5
1 changed files with 5 additions and 5 deletions

View File

@ -913,11 +913,11 @@ def update_zookeeper():
} }
}) })
# Trigger updates for each pool on this node # Trigger updates for each pool on this node
for pool in pool_list: for pool in pool_list:
zkhandler.writedata(zk_conn, { zkhandler.writedata(zk_conn, {
'/ceph/pools/{}/stats'.format(pool): str(json.dumps(pool_df[pool])) '/ceph/pools/{}/stats'.format(pool): str(json.dumps(pool_df[pool]))
}) })
# Only grab OSD stats if there are OSDs to grab (otherwise `ceph osd df` hangs) # Only grab OSD stats if there are OSDs to grab (otherwise `ceph osd df` hangs)
osds_this_node = 0 osds_this_node = 0