Distributed: Fixed issue on shutting down of server