Hello community,

here is the log from the commit of package python-rtslib for openSUSE:Factory 
checked in at 2016-01-05 21:55:07
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-rtslib (Old)
 and      /work/SRC/openSUSE:Factory/.python-rtslib.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-rtslib"

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-rtslib/python-rtslib.changes      
2015-03-09 10:09:00.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.python-rtslib.new/python-rtslib.changes 
2016-01-05 21:55:37.000000000 +0100
@@ -1,0 +2,8 @@
+Fri Dec 25 08:16:22 UTC 2015 - [email protected]
+
+- fix BNC#958274 - Wrong random default name of iSCSI target name 
+  generated by Targetcli 
+  fix iqn wwn name error when include "-"
+  patch: rtslib-fix-iqn-wwn.patch
+
+-------------------------------------------------------------------

New:
----
  rtslib-fix-iqn-wwn.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-rtslib.spec ++++++
--- /var/tmp/diff_new_pack.fPAqEN/_old  2016-01-05 21:55:40.000000000 +0100
+++ /var/tmp/diff_new_pack.fPAqEN/_new  2016-01-05 21:55:40.000000000 +0100
@@ -31,6 +31,7 @@
 Patch2:         %{oname}-add-prot-info-attributes.patch
 Patch3:         %{oname}-add-iblock-backstore-policy.patch
 Patch5:         0001-Add-support-for-xen-scsiback.patch
+Patch6:         %{oname}-fix-iqn-wwn.patch
 Requires:       python-configobj
 Requires:       python-ipaddr
 Requires:       python-netifaces
@@ -74,6 +75,7 @@
 %patch2 -p1
 %patch3 -p1
 %patch5 -p1
+%patch6        -p1
 
 %build
 python setup.py build

++++++ rtslib-fix-iqn-wwn.patch ++++++
Index: rtslib-2.2/rtslib/target.py
===================================================================
--- rtslib-2.2.orig/rtslib/target.py
+++ rtslib-2.2/rtslib/target.py
@@ -1194,6 +1194,7 @@ class Target(CFSNode):
 
         if wwn is not None:
             wwn = str(wwn).strip()
+            wwn = wwn.replace("_","-")
         elif fabric_module.spec['wwn_list']:
             existing_wwns = set([child.wwn for child in fabric_module.targets])
             free_wwns = fabric_module.spec['wwn_list'] - existing_wwns
Index: rtslib-2.2/rtslib/utils.py
===================================================================
--- rtslib-2.2.orig/rtslib/utils.py
+++ rtslib-2.2/rtslib/utils.py
@@ -520,7 +520,8 @@ def generate_wwn(wwn_type):
     if wwn_type == 'unit_serial':
         return str(uuid.uuid4())
     elif wwn_type == 'iqn':
-        localname = socket.gethostname().split(".")[0]
+        localname_raw = socket.gethostname().split(".")[0]
+        localname = localname_raw.replace("_","-")
         localarch = os.uname()[4].replace("_","")
         prefix = "iqn.2003-01.org.linux-iscsi.%s.%s" % (localname, localarch)
         prefix = prefix.strip().lower()

Reply via email to