update to only reload services that are enabled and running
This commit is contained in:
@@ -459,7 +459,7 @@ if __name__ == '__main__':
|
||||
logger.info('Dataset {} is already unlocked'.format(pool_name))
|
||||
services = c.call("service.query")
|
||||
for service in services:
|
||||
if service['enable'] and service['service'] not in EXCLUDED_SERVICES:
|
||||
if service['enable'] and service['enable'] == "RUNNING" and service['service'] not in EXCLUDED_SERVICES:
|
||||
logger.debug('Service {} is enabled'.format(service['service']))
|
||||
reloaded = c.call("service.control", "RELOAD", service['service'], job=True)
|
||||
if reloaded:
|
||||
|
||||
Reference in New Issue
Block a user