Fix shutdown issue with service restarts and cloudi_pool errors.