[monit/services] Décodage des uuids de block devices
darcs-hash:20110208234105-ffbb2-8252d59f1533d364386965ad4bdb153012424cfb.gz
This commit is contained in:
parent
2c12e8af85
commit
0ce634069e
1 changed files with 7 additions and 0 deletions
|
@ -205,6 +205,12 @@ for i in range(0,dernierecarte):
|
|||
if hostname in ['canard'] :
|
||||
done()
|
||||
|
||||
disques = {}
|
||||
if has('blkid'):
|
||||
for line in metadata.Probes["blkid"].splitlines():
|
||||
label, disque = line.strip().split()
|
||||
disques[label] = disque
|
||||
|
||||
for line in metadata.Probes["fstab_local"].splitlines():
|
||||
# on supprime les espaces
|
||||
line = line.strip()
|
||||
|
@ -217,6 +223,7 @@ for line in metadata.Probes["fstab_local"].splitlines():
|
|||
|
||||
# on découpe la ligne
|
||||
[fs, mntpoint, type, options, dump, pass_] = re.split('[ \t]*',line)
|
||||
fs = disques.get(fs, fs)
|
||||
options = options.split(",")
|
||||
|
||||
# on saute si c'est une partition non montée au démarrage
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue