Change in vdsm[master]: multipath: Backup old configuration using hard link

fabiand at redhat.com fabiand at redhat.com
Mon Aug 17 06:22:30 UTC 2015


Fabian Deutsch has posted comments on this change.

Change subject: multipath: Backup old configuration using hard link
......................................................................


Patch Set 3:

(1 comment)

https://gerrit.ovirt.org/#/c/44866/3/lib/vdsm/tool/configurators/multipath.py
File lib/vdsm/tool/configurators/multipath.py:

Line 124:     """
Line 125: 
Line 126:     backup = _CONF_FILE + '.' + time.strftime("%Y%m%d%H%M")
Line 127:     try:
Line 128:         os.link(_CONF_FILE, backup)
> Fabian: is this going to work on node?
This will at least not work when then multipath.conf file is persisted. In that case multipath.conf is a bind-mount target, and can thus not be hardlinked.

ovirt.node.utils.fs.Config().unpersist(fn) can be used to unpersist the file, which would remove the bindmount, then the hardlink can work, as longs as hardlinks work on tmpfs.
Line 129:     except OSError as e:
Line 130:         if e.errno != errno.ENOENT:
Line 131:             raise
Line 132:     else:


-- 
To view, visit https://gerrit.ovirt.org/44866
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ibe97ffc0bc56bf219efad2e57c307f8576315589
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fabiand at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fdeutsch at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski at gmail.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list