Bug 1006449 - If you try to create a storage connection with empty port, then it is set to 0
Summary: If you try to create a storage connection with empty port, then it is set to 0
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: ovirt-engine-core
Version: 3.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 3.5.0
Assignee: Allon Mureinik
QA Contact: Elad
URL:
Whiteboard: storage
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-10 15:56 UTC by Katarzyna Jachim
Modified: 2016-02-10 18:54 UTC (History)
13 users (show)

Fixed In Version: ovirt-3.5.0-alpha1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-10-17 12:28:05 UTC
oVirt Team: Storage


Attachments (Terms of Use)
test logs (vdsm, engine, server etc.) (3.67 MB, application/x-bzip2)
2013-09-10 15:56 UTC, Katarzyna Jachim
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 24402 0 None None None Never

Description Katarzyna Jachim 2013-09-10 15:56:41 UTC
Created attachment 796066 [details]
test logs (vdsm, engine, server etc.)

Description of problem:
<port> tag is required when creating an iscsi storage connection. However, when you try the following call:
<storage_connection>
    <target>iqn.1992-04.com.emc:cx.ckm00121000438.b7</target>
    <type>iscsi</type>
    <port></port>
    <address>10.35.160.107</address>
</storage_connection>

it succeeds and the created connection has port = 0:

<storage_connections>
    <storage_connection href="/api/storageconnections/726a17f2-67c2-41a0-9fbc-9fed23a70271" id="726a17f2-67c2-41a0-9fbc-9fed23a70271">
        <address>10.35.160.107</address>
        <type>iscsi</type>
        <port>0</port>
        <target>iqn.1992-04.com.emc:cx.ckm00121000438.b7</target>
    </storage_connection>
</storage_connections>

Also, if you try to change existing connection and specified empty tag <port>, it will be set to 0.

Version-Release number of selected component (if applicable): is13


How reproducible: 100%, automated tests:
http://jenkins.qa.lab.tlv.redhat.com:8080/view/Storage/view/3.3/job/3.3-storage_storage_connections_iscsi-iscsi-rest/54/


Steps to Reproduce:
1. try to create an iscsi storage connection and specify empty <port> tag

Actual results: connection is created with port = 0


Expected results: the operation should fail with appropriate error message

Comment 3 Juan Hernández 2014-02-25 15:08:38 UTC
Allon, can you merge this change so that Ravi can backport it to 3.4? If not please retarget to 3.4.1 or 3.5.

Comment 4 Allon Mureinik 2014-02-27 09:57:00 UTC
(In reply to Juan Hernández from comment #3)
> Allon, can you merge this change so that Ravi can backport it to 3.4? If not
> please retarget to 3.4.1 or 3.5.
I merged it upstream. Considering the timing in 3.4's lifecycle and the severity of this issue, I pushed it out to 3.5.

Comment 5 Elad 2014-07-08 10:42:14 UTC
Tried to create a storage connection with no value under port parameter and it failed with the following error:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<fault>
    <reason>Operation Failed</reason>
    <detail>[Invalid value for port, should be an integer greater than 0.]</detail>
</fault>


Verified using ovirt-engine-3.5-beta
ovirt-engine-3.5.0-0.0.master.20140629172257.git0b16ed7.el6.noarch
ovirt-engine-restapi-3.5.0-0.0.master.20140629172257.git0b16ed7.el6.noarch

Comment 6 Sandro Bonazzola 2014-10-17 12:28:05 UTC
oVirt 3.5 has been released and should include the fix for this issue.


Note You need to log in before you can comment on or make changes to this bug.