[NEW PATCH] BZ#722865 - Increase fds limit in multipath.conf (via gerrit-bot)
by Haim Ateya
New patch submitted by Haim Ateya (hateya(a)redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/716
commit b20cc868ac55fa1aaa8a08d4d092dc183e365155
Author: Haim Ateya <hateya(a)redhat.com>
Date: Mon Jul 18 07:19:07 2011 +0300
BZ#722865 - Increase fds limit in multipath.conf
Change-Id: Id35be3dafbc5cb5db6c70ee3008c9a6652ae4717
diff --git a/vdsm/constants.py b/vdsm/constants.py
index ae9a79b..2d785ed 100644
--- a/vdsm/constants.py
+++ b/vdsm/constants.py
@@ -153,6 +153,7 @@ defaults {
flush_on_last_del yes
fast_io_fail_tmo 5
dev_loss_tmo 30
+ max_fds 4096
}
"""
12 years, 11 months
[NEW PATCH] BZ#720981 - Don't realy on files in /dev/mapper to be symlinks (via gerrit-bot)
by smizrahi@redhat.com
New patch submitted by Saggi Mizrahi (smizrahi(a)redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/717
commit 97fdad1a321c630ea4470e5c64e5173ed0c27b4e
Author: Saggi Mizrahi <smizrahi(a)redhat.com>
Date: Mon Jul 18 13:07:24 2011 +0300
BZ#720981 - Don't realy on files in /dev/mapper to be symlinks
Change-Id: I4e1669e994834602e7c9cb655fbac31fe666bafe
diff --git a/vdsm/storage/devicemapper.py b/vdsm/storage/devicemapper.py
index 7e2c634..f6ce1a5 100644
--- a/vdsm/storage/devicemapper.py
+++ b/vdsm/storage/devicemapper.py
@@ -10,9 +10,14 @@ from constants import EXT_DMSETUP
DMPATH_FORMAT = "/dev/mapper/%s"
def getDmId(deviceMultipathName):
- devPath = DMPATH_FORMAT % (deviceMultipathName,)
- mpPath = os.path.realpath(devPath)
- return os.path.basename(mpPath)
+ for nameFile in glob("/sys/bloc/dm-*/dm/name"):
+ try:
+ with open(nameFile, "r") as f:
+ if f.read() == deviceMultipathName:
+ return nameFile.split("/")[2]
+ except (IOError, OSError):
+ pass
+ raise OSError(errno.ENOENT, "Could not find dm device named `%s`" % deviceMultipathName)
def findDev(major, minor):
return os.path.basename(os.path.realpath('/sys/dev/block/%d:%d' % (major, minor)))
diff --git a/vdsm/storage/multipath.py b/vdsm/storage/multipath.py
index 9ad6200..63be686 100644
--- a/vdsm/storage/multipath.py
+++ b/vdsm/storage/multipath.py
@@ -195,7 +195,7 @@ def pathListIter(filterGuids=None):
svdsm = supervdsm.getProxy()
pathStatuses = devicemapper.getPathsStatus()
- for guid in getMPDevNamesIter():
+ for dmId, guid in getMPDevsIter():
if devsFound == filterLen:
break
@@ -204,8 +204,6 @@ def pathListIter(filterGuids=None):
devsFound += 1
- dmId = devicemapper.getDmId(guid)
-
devInfo = {
"guid" : guid,
"dm" : dmId,
@@ -290,6 +288,10 @@ def pathinfo(guid):
TOXIC_REGEX = re.compile(r"[%s]" % re.sub(r"[\-\\\]]", lambda m : "\\" + m.group(), TOXIC_CHARS))
def getMPDevNamesIter():
+ for _, name in getMPDevsIter():
+ yield name
+
+def getMPDevsIter():
"""
Collect the list of all the multipath block devices.
Return the list of device identifiers w/o "/dev/mapper" prefix
@@ -316,7 +318,7 @@ def getMPDevNamesIter():
log.info("Device with unsupported GUID %s discarded", guid)
continue
- yield guid
+ yield dmInfoDir.split("/")[2], guid
def devIsiSCSI(type):
return type in [DEV_ISCSI, DEV_MIXED]
12 years, 11 months
Change in vdsm[master]: BZ#720257 - Don't produce domain on teardown
by Dan Kenigsberg
Dan Kenigsberg has posted comments on this change.
Change subject: BZ#720257 - Don't produce domain on teardown
......................................................................
Patch Set 2: I would prefer that you didn't submit this
(4 inline comments)
....................................................
File vdsm/storage/hsm.py
Line 1668: lockType = rm.LockType.exclusive
do you find this clearer than the perl-like
lockType = rm.LockType.exclusive if rw else rm.LockType.shared
? I don't.
Line 1673
so you say this prepare (and the preceeding refresh) where redundant? Please add a reassuring word to the commit message, explaining why the feared NB is no longer relevant.
Line 1689: :param rw: Should the voulme be set as RW. ?
hmmm, I guess that "rw" arg should better be marked as obsolete (unrelated to this patch)
Line 1695: imgResource = self._preparedVolumes[sdUUID + volUUID].pop()
we do not care if the popped imgResource matches our imgUUID? I find it odd that you no longer use that arg.
--
To view, visit http://10.35.18.144/724
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Iaf3311790a7927e3bf3d5e7a4820462d213bcdb6
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
12 years, 11 months
Change in vdsm[master]: BZ#720981 - Don't rely on files in /dev/mapper to be symlink...
by Haim Ateya
Haim Ateya has posted comments on this change.
Change subject: BZ#720981 - Don't rely on files in /dev/mapper to be symlinks
......................................................................
Patch Set 5: Verified
ack from my side, getDeviceList returns with no errors.
--
To view, visit http://10.35.18.144/717
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I4e1669e994834602e7c9cb655fbac31fe666bafe
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Haim Ateya <hateya(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
12 years, 11 months
[NEW PATCH] BZ#705058 - StoragePool instanciations should be lock protected. (via gerrit-bot)
by Yotam Oron
New patch submitted by Yotam Oron (yoron(a)redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/725
commit 09de1812fa94f3b0cda13cb428f3b4e445b39b49
Author: Yotam Oron <yoron(a)redhat.com>
Date: Wed Jul 13 11:56:06 2011 +0300
BZ#705058 - StoragePool instanciations should be lock protected.
Add a storage shared lock on the call to _restorePool, since creates a
new pool object
Change-Id: If17649ae25bbac7bc23fe319c1adfdf669527e60
diff --git a/vdsm/storage/hsm.py b/vdsm/storage/hsm.py
index a6de936..6ae3824 100644
--- a/vdsm/storage/hsm.py
+++ b/vdsm/storage/hsm.py
@@ -166,11 +166,11 @@ class HSM:
for spUUID in dirList:
poolPath = os.path.join(self.storage_repository, spUUID)
try:
- vars.task.getSharedLock(STORAGE, spUUID)
if os.path.exists(poolPath):
- self._restorePool(spUUID)
- #TODO Once we support simultaneous connection to multiple pools, remove following line (break)
- break
+ with rmanager.acquireResource(STORAGE, spUUID, rm.LockType.shared):
+ self._restorePool(spUUID)
+ #TODO Once we support simultaneous connection to multiple pools, remove following line (break)
+ break
except Exception:
self.log.error("Unexpected error", exc_info=True)
12 years, 11 months
Change in vdsm[master]: BZ#705058 - StoragePool instanciations should be lock protec...
by smizrahi@redhat.com
Saggi Mizrahi has posted comments on this change.
Change subject: BZ#705058 - StoragePool instanciations should be lock protected.
......................................................................
Patch Set 2: Looks good to me, approved
--
To view, visit http://10.35.18.144/725
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If17649ae25bbac7bc23fe319c1adfdf669527e60
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yotam Oron <yoron(a)redhat.com>
Gerrit-Reviewer: Haim Ateya <hateya(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Yotam Oron <yoron(a)redhat.com>
12 years, 11 months
Change in vdsm[master]: BZ#705058 - StoragePool instanciations should be lock protec...
by Yotam Oron
Yotam Oron has posted comments on this change.
Change subject: BZ#705058 - StoragePool instanciations should be lock protected.
......................................................................
Patch Set 1: (1 inline comment)
....................................................
File vdsm/storage/hsm.py
Line 170: with rmanager.acquireResource(STORAGE, spUUID, rm.LockType.shared):
Done
--
To view, visit http://10.35.18.144/725
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If17649ae25bbac7bc23fe319c1adfdf669527e60
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yotam Oron <yoron(a)redhat.com>
Gerrit-Reviewer: Haim Ateya <hateya(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Yotam Oron <yoron(a)redhat.com>
12 years, 11 months
Change in vdsm[master]: BZ#705058 - StoragePool instanciations should be lock protec...
by smizrahi@redhat.com
Saggi Mizrahi has posted comments on this change.
Change subject: BZ#705058 - StoragePool instanciations should be lock protected.
......................................................................
Patch Set 1: I would prefer that you didn't submit this
(1 inline comment)
....................................................
File vdsm/storage/hsm.py
Line 170: with rmanager.acquireResource(STORAGE, spUUID, rm.LockType.shared):
Exclusive
--
To view, visit http://10.35.18.144/725
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If17649ae25bbac7bc23fe319c1adfdf669527e60
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yotam Oron <yoron(a)redhat.com>
Gerrit-Reviewer: Haim Ateya <hateya(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
12 years, 11 months
Change in vdsm[master]: BZ#705058 - StoragePool instanciations should be lock protec...
by Haim Ateya
Haim Ateya has posted comments on this change.
Change subject: BZ#705058 - StoragePool instanciations should be lock protected.
......................................................................
Patch Set 1: Verified
fixed. tested on 2 different hosts (spm).
--
To view, visit http://10.35.18.144/725
To unsubscribe, visit http://10.35.18.144/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If17649ae25bbac7bc23fe319c1adfdf669527e60
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yotam Oron <yoron(a)redhat.com>
Gerrit-Reviewer: Haim Ateya <hateya(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
12 years, 11 months
[NEW PATCH] BZ#705058 - StoragePool instanciations should be lock protected. (via gerrit-bot)
by Yotam Oron
New patch submitted by Yotam Oron (yoron(a)redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/700
commit 6b27cdc4cae27c74959c30609d874a39ba35e7ca
Author: Yotam Oron <yoron(a)redhat.com>
Date: Wed Jul 13 11:56:06 2011 +0300
BZ#705058 - StoragePool instanciations should be lock protected.
Add a storage shared lock on the call to _restorePool, since creates a
new pool object
Change-Id: I4ad3cdb07299d63203db98ae3223559b6fdc4eab
diff --git a/vdsm/storage/hsm.py b/vdsm/storage/hsm.py
index b0d5d21..f763120 100644
--- a/vdsm/storage/hsm.py
+++ b/vdsm/storage/hsm.py
@@ -162,16 +162,14 @@ class HSM:
self.taskMng.recoverDumpedTasks()
_poolsTmpDir = config.get('irs', 'pools_data_dir')
- dirList = os.listdir(_poolsTmpDir)
- for spUUID in dirList:
- poolPath = os.path.join(self.storage_repository, spUUID)
- try:
- if os.path.exists(poolPath):
- self._restorePool(spUUID)
- #TODO Once we support simultaneous connection to multiple pools, remove following line (break)
- break
- except Exception:
- self.log.error("Unexpected error", exc_info=True)
+ spUUID = os.listdir(_poolsTmpDir)[0]
+ vars.task.getSharedLock(STORAGE, spUUID)
+ poolPath = os.path.join(self.storage_repository, spUUID)
+ try:
+ if os.path.exists(poolPath):
+ self._restorePool(spUUID)
+ except Exception:
+ self.log.error("Unexpected error", exc_info=True)
threading.Thread(target=storageRefresh).start()
12 years, 11 months