Fix bug with pool removal

This commit is contained in:
Joshua Boniface 2019-06-18 21:51:03 -04:00
parent 264c2d4748
commit ee73676114
1 changed files with 3 additions and 3 deletions

View File

@ -809,13 +809,13 @@ def remove_pool(zk_conn, name):
try:
result = zkhandler.readdata(zk_conn, '/ceph/cmd').split()[0]
if result == 'success-pool_remove':
message = 'Removed RBD pool {} and all volumes.'.format(name, pgs)
message = 'Removed RBD pool {} and all volumes.'.format(name)
success = True
else:
message = 'ERROR: Failed to remove pool; check node logs for details.'
success = False
except:
message = 'ERROR: Command ignored by node.'
except Exception as e:
message = 'ERROR: Command ignored by node: {}'.format(e)
success = False
zkhandler.writedata(zk_conn, {'/ceph/cmd': ''})