Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 5 product line. The current stable release is 5.10. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 512938

Summary: Running fcoeadm -i ethx where for ethx doesn't exists fc_host displays "fcoeadm: Invalid command options!"
Product: Red Hat Enterprise Linux 5 Reporter: Martin Kočí <mkoci>
Component: fcoe-utilsAssignee: Petr Šabata <psabata>
Status: CLOSED ERRATA QA Contact: Gris Ge <fge>
Severity: low Docs Contact:
Priority: low    
Version: 5.4CC: fge, ohudlick, ovasik
Target Milestone: rcKeywords: Patch
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: fcoe-utils-1.0.7-5.el5 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-02-21 06:09:14 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
Patch correcting the behaviour none

Description Martin Kočí 2009-07-21 12:41:07 UTC
Description of problem:
Running "fcoeadm -i ethx" where for ethx doesn't exists fc_host displays "fcoeadm: Invalid command options!"

Version-Release number of selected component (if applicable):
fcoe-utils-1.0.7-4

How reproducible:
Always

Steps to Reproduce:
1.# fcoeadm -i eth0 (note that there is no fc_host for eth0)
  
Actual results:
# fcoeadm -i eth0
fcoeadm: No fc_host found for eth0
fcoeadm: Invalid command options!
fcoeadm v1.0.7
Copyright (c) 2009, Intel Corporation.

Usage: fcoeadm
         [-c|--create] <ethX>
         [-d|--destroy] <ethX>
         [-r|--reset] <ethX>
         [-i|--interface] [<ethX>]
         [-t|--target] [<ethX>]
         [-l|--lun] [<target port_id> [<lun_id>]]
         [-s|--stats] <ethX> [-n <interval>]
         [-v|--version]
         [-h|--help]


Expected results:
Some sane output instead of "fcoeadm: Invalid command options!"

Comment 2 Jan Zeleny 2009-09-07 14:20:40 UTC
Created attachment 359997 [details]
Patch correcting the behaviour

Attaching a patch, which is correcting the behavior - now fcoeadm only prints out, that no host was found on given interface.

Comment 9 Petr Šabata 2011-10-19 13:23:46 UTC
Patch applied in fcoe-utils-1_0_7-5_el5

Comment 11 Gris Ge 2012-01-11 07:28:15 UTC
fcoe-utils-1.0.7-5.el5 fixed this issue.

VERIFY.

Comment 12 errata-xmlrpc 2012-02-21 06:09:14 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0230.html