Bug 712638

Summary: iscsi target outgoing user binding broken unexpectedly
Product: [Fedora] Fedora Reporter: Ian Dall <ian>
Component: scsi-target-utilsAssignee: Andy Grover <agrover>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 14CC: agrover, mchristi, terje.rosten
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-07-08 21:21:00 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Shell script to exercise tgt-utils
none
Standard output from tgt-test script
none
Log output from "tgtd -d 9" while running tgt-test script
none
Patch to only unbind users which are bound to a target. none

Description Ian Dall 2011-06-12 02:37:46 UTC
Created attachment 504285 [details]
Shell script to exercise tgt-utils

Description of problem:
When multiple targets are set up with outgoing users, modifying one target invalidates the binding of the outgoing user to unrelated targets.

Version-Release number of selected component (if applicable):
1.0.1-3.fc13

How reproducible:
Always

Steps to Reproduce: 
1. Create two targets "iqn.test:test1" and "iqn.test:test2"
2. Delete target "iqn.test:test1"
3. Recreate target "iqn.test:test1"
  
Actual results:
tgt-admin --dump shows that "iqn.test:test2" has lost its outgoing user, even though only "iqn.test:test1" should have been changed.

Expected results:
Operations on one target are unaffected by operations on another target

Additional info:
It is possible to fix up the outgoing user binding explicitly. It may be that operations are order dependent, but I am using "tgt-admin --update" which should do the right thing.

I have attached a script which demonstrates the problem.

Comment 1 Ian Dall 2011-06-12 02:39:36 UTC
Created attachment 504286 [details]
Standard output from tgt-test script

Comment 2 Ian Dall 2011-06-12 02:40:48 UTC
Created attachment 504287 [details]
Log output from "tgtd -d 9" while running tgt-test script

Comment 3 Ian Dall 2011-06-15 12:44:08 UTC
Created attachment 504861 [details]
Patch to only unbind users which are bound to a target.

This patch fixes the reported problem with no apparent side effects.

Comment 4 Andy Grover 2011-06-15 22:17:43 UTC
Ian, thanks for tracking this bug down.

I see this is not fixed in stgt upstream. Would you like to submit the patch yourself to stgt.org? If not, I can follow up on your behalf.

Comment 5 Ian Dall 2011-06-16 09:37:53 UTC
OK. I have reported it upstream.

Comment 6 Fedora Update System 2011-06-30 01:19:31 UTC
scsi-target-utils-1.0.18-1.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/scsi-target-utils-1.0.18-1.fc15

Comment 7 Fedora Admin XMLRPC Client 2011-06-30 22:03:48 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 8 Fedora Update System 2011-06-30 22:14:33 UTC
scsi-target-utils-1.0.18-1.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/scsi-target-utils-1.0.18-1.fc14

Comment 9 Fedora Update System 2011-07-08 18:02:03 UTC
scsi-target-utils-1.0.18-1.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2011-07-12 04:55:14 UTC
scsi-target-utils-1.0.18-1.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.