From: rread Date: Sat, 2 Nov 2002 00:51:43 +0000 (+0000) Subject: * add a bit of randomness to the MDC uuid X-Git-Tag: 0.5.16~37 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=17d3dce9eba7316b50d33267b48d509ffd6b9040;p=fs%2Flustre-release.git * add a bit of randomness to the MDC uuid --- diff --git a/lustre/utils/lconf b/lustre/utils/lconf index c014e9c..8692970 100755 --- a/lustre/utils/lconf +++ b/lustre/utils/lconf @@ -25,7 +25,7 @@ # Based in part on the XML obdctl modifications done by Brian Behlendorf import sys, getopt -import string, os, stat, popen2, socket, time +import string, os, stat, popen2, socket, time, random import re, exceptions import xml.dom.minidom @@ -688,8 +688,6 @@ class Module: def cleanup(self): """ default cleanup, used for most modules """ - if not is_prepared(self.uuid): - return self.info() srv = self.get_server() if srv and local_net(srv): @@ -1003,8 +1001,8 @@ class MDC(Module): self._connected = 0 host = socket.gethostname() - self.name = 'MDC_%s_%s' % ( host, self.mds.name ) - self.uuid = self.name + '_UUID' + self.name = 'MDC_%s' % (self.mds.name) + self.uuid = '%s_%4.4x_UUID' % (self.name , int(random.random() * 100000 )) self.lookup_server(self.mds.uuid) self.add_module('lustre/mdc', 'mdc')