This patch adds mode option documentation to the fcoeadm man page, adds the new MODE options to the config file template and adds the new -m|--mode options to the bash completion.
Signed-off-by: Mark Rustad <[email protected]> Tested-by: Jack Morgan <[email protected]> --- contrib/bash_completion/fcoeadm | 11 +++++-- doc/fcoeadm.8 | 26 +++++++++++++++-- doc/fcoeadm.txt | 18 ++++++++++-- doc/fcoemon.8 | 14 ++++++++- doc/fcoemon.txt | 16 +++++++++++ doc/fcrls.8 | 17 ++++++++--- doc/fipvlan.8 | 58 +++++++++++++++++---------------------- etc/cfg-ethx | 11 +++++++ 8 files changed, 122 insertions(+), 49 deletions(-) diff --git a/contrib/bash_completion/fcoeadm b/contrib/bash_completion/fcoeadm index b3b23bb..59ed54b 100644 --- a/contrib/bash_completion/fcoeadm +++ b/contrib/bash_completion/fcoeadm @@ -3,7 +3,7 @@ ## fcoeadm --help #Version 1.0.17 #Usage: fcoeadm -# [-c|--create] <ethX> +# [-m|--mode fabric|vn2vn] [-c|--create] <ethX> # [-d|--destroy] <ethX> # [-r|--reset] <ethX> # [-S|--Scan] <ethX> @@ -41,7 +41,7 @@ have fcoeadm && _fcoeadm_options() COMPREPLY=() cur="${COMP_WORDS[COMP_CWORD]}" prev="${COMP_WORDS[COMP_CWORD-1]}" - opts="-c --create -d --destroy -r --reset -i --interface -t --target -l --lun -s --stats -S --Scan -h --help -v --version" + opts="-m --mode -c --create -d --destroy -r --reset -i --interface -t --target -l --lun -s --stats -S --Scan -h --help -v --version" case "${prev}" in -c|--create|-d|--destroy|-r|--reset|-s|--stats|-S|--Scan|-i|--interface|-t|--target|-l|--lun) @@ -49,6 +49,11 @@ have fcoeadm && _fcoeadm_options() _available_fcoe_interfaces -a return 0 ;; + -m|--mode) + COMPREPLY=( fabric vn2vn ) + COMPREPLY=( $( compgen -W '${COMPREPLY[@]/%[[:punct:]]/}' -- "$cur" ) ) + return 0 + ;; esac case "${cur}" in @@ -68,4 +73,4 @@ complete -F _fcoeadm_options fcoeadm # sh-indent-comment: t # indent-tabs-mode: nil # End: -# ex: ts=4 sw=4 et filetype=sh \ No newline at end of file +# ex: ts=4 sw=4 et filetype=sh diff --git a/doc/fcoeadm.8 b/doc/fcoeadm.8 index a7c4c71..11da6e3 100644 --- a/doc/fcoeadm.8 +++ b/doc/fcoeadm.8 @@ -2,12 +2,12 @@ .\" Title: fcoeadm .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/> -.\" Date: 07/20/2012 +.\" Date: 11/08/2012 .\" Manual: Open-FCoE Tools .\" Source: Open-FCoE .\" Language: English .\" -.TH "FCOEADM" "8" "07/20/2012" "Open\-FCoE" "Open\-FCoE Tools" +.TH "FCOEADM" "8" "11/08/2012" "Open\-FCoE" "Open\-FCoE Tools" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- @@ -29,7 +29,7 @@ fcoeadm \- The Open\-FCoE Administration Tool .SH "SYNOPSIS" .sp -\fBfcoeadm\fR \-c|\-\-create \fIethX\fR +\fBfcoeadm\fR [\-m|\-\-mode fabric|vn2vn] \-c|\-\-create \fIethX\fR .sp \fBfcoeadm\fR \-d|\-\-destroy \fIethX\fR .sp @@ -56,9 +56,15 @@ fcoeadm \- The Open\-FCoE Administration Tool .sp The \fBfcoeadm\fR utility is the Fibre Channel over Ethernet (FCoE) management tool for the \fIOpen\-FCoE\fR project\&. \fBfcoeadm\fR may be used to create, destroy, and reset an FCoE instance on a given network interface\&. For these operations \fBfcoeadm\fR sends a command to a running \fBfcoemon\fR process, via a socket interface\&. \fBfcoemon\fR will then perform the requested operation\&. .sp -\fBfcoeadm\fR also provides options to query information about FCoE instances, including interface information, target information, LUN information, and port statistics\&. For much of this information, \fBfcoeadm\fR relies on the \fIlibhbalinux\fR implementation of the \fIHBA API\fR\&. +\fBfcoeadm\fR also provides operations to query information about FCoE instances, including interface information, target information, LUN information, and port statistics\&. For much of this information, \fBfcoeadm\fR relies on the \fIlibhbalinux\fR implementation of the \fIHBA API\fR\&. Only one operation may be given on a command\&. .SH "OPTIONS" .PP +\fB\-m\fR, \fB\-\-mode\fR fabric|vn2vn +.RS 4 +Used together with the create option to control the FCoE mode of operation\&. The mode defaults to fabric but this option allows the selection of vn2vn mode\&. +.RE +.SH "OPERATIONS" +.PP \fB\-c\fR, \fB\-\-create\fR \fIethX\fR .RS 4 Creates an FCoE instance based on the specified network interface\&. Note that if there is not an fcoemon configuration file for the interface (/etc/fcoe/cfg\-ethX, see @@ -158,6 +164,18 @@ fcoeadm \-c eth2\&.101 .RE .\} .sp +Creates an FCoE VN2VN instance on eth2\&.101 +.sp +.if n \{\ +.RS 4 +.\} +.nf +fcoeadm \-m vn2vn \-c eth2\&.101 +.fi +.if n \{\ +.RE +.\} +.sp Destroys the FCoE instance on eth2\&.101 .sp .if n \{\ diff --git a/doc/fcoeadm.txt b/doc/fcoeadm.txt index 927acd6..788625c 100644 --- a/doc/fcoeadm.txt +++ b/doc/fcoeadm.txt @@ -19,7 +19,7 @@ fcoeadm - The Open-FCoE Administration Tool SYNOPSIS -------- -*fcoeadm* -c|--create _ethX_ +*fcoeadm* [-m|--mode fabric|vn2vn] -c|--create _ethX_ *fcoeadm* -d|--destroy _ethX_ @@ -51,13 +51,21 @@ destroy, and reset an FCoE instance on a given network interface. For these operations *fcoeadm* sends a command to a running *fcoemon* process, via a socket interface. *fcoemon* will then perform the requested operation. -*fcoeadm* also provides options to query information about FCoE instances, +*fcoeadm* also provides operations to query information about FCoE instances, including interface information, target information, LUN information, and port statistics. For much of this information, *fcoeadm* relies on the _libhbalinux_ -implementation of the _HBA API_. +implementation of the _HBA API_. Only one operation may be given on a +command. OPTIONS ------- +*-m*, *--mode* fabric|vn2vn:: + Used together with the create option to control the FCoE mode of + operation. The mode defaults to fabric but this option allows + the selection of vn2vn mode. + +OPERATIONS +---------- *-c*, *--create* _ethX_:: Creates an FCoE instance based on the specified network interface. Note that if there is not an fcoemon configuration file for the @@ -136,6 +144,10 @@ Creates an FCoE instance on eth2.101 fcoeadm -c eth2.101 +Creates an FCoE VN2VN instance on eth2.101 + + fcoeadm -m vn2vn -c eth2.101 + Destroys the FCoE instance on eth2.101 fcoeadm -d eth2.101 diff --git a/doc/fcoemon.8 b/doc/fcoemon.8 index 9aa3d66..e9a045b 100644 --- a/doc/fcoemon.8 +++ b/doc/fcoemon.8 @@ -2,12 +2,12 @@ .\" Title: fcoemon .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/> -.\" Date: 10/08/2012 +.\" Date: 02/06/2013 .\" Manual: Open-FCoE Tools .\" Source: Open-FCoE .\" Language: English .\" -.TH "FCOEMON" "8" "10/08/2012" "Open\-FCoE" "Open\-FCoE Tools" +.TH "FCOEMON" "8" "02/06/2013" "Open\-FCoE" "Open\-FCoE Tools" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- @@ -344,6 +344,16 @@ indicates if VLAN discovery should be performed\&. If AUTO_VLAN is set to "yes", \fBfcoemon\fR will run run the FIP VLAN discovery protocol on the Ethernet interface\&. Network interfaces for any discovered FCoE VLANs will be automatically created, if they are not already configured, and FCoE instances will be created on the VLAN interfaces\&. If the network interface specified by the filename is already a VLAN interface, the AUTO_VLAN setting is ignored\&. .RE +.PP +\fIMODE\fR +.RS 4 +indicates whether operation will be in fabric or vn2vn mode\&. The default is fabric\&. +.RE +.PP +\fIFIP_RESP\fR +.RS 4 +indicates whether a FIP responder should be activated on this device to support VLAN discovery in a vn2vn environment\&. The default is "no"\&. Often this will be used on a vn2vn node also serving as a target\&. When using this option, the AUTO_VLAN should not be set and the supported VLANs should have configuration files supplied, constituting a static VLAN configuration that provides the information for the FIP responder to return\&. This should be set on a base device, which should probably have FCOE_ENABLE set to "no" since presumably FCoE operation will be on the configured VLANs\&. +.RE .sp Note that the attached Ethernet peer device (e\&.g\&. FCoE capable switch port) must have compatible settings For DCB and FCoE to function properly\&. .SS "/etc/init\&.d/fcoe" diff --git a/doc/fcoemon.txt b/doc/fcoemon.txt index f2f2ad3..ec15197 100644 --- a/doc/fcoemon.txt +++ b/doc/fcoemon.txt @@ -191,6 +191,22 @@ _AUTO_VLAN_:: interfaces. If the network interface specified by the filename is already a VLAN interface, the AUTO_VLAN setting is ignored. +_MODE_:: + indicates whether operation will be in fabric or vn2vn mode. The + default is fabric. + +_FIP_RESP_:: + indicates whether a FIP responder should be activated on this + device to support VLAN discovery in a vn2vn environment. The + default is "no". Often this will be used on a vn2vn node also + serving as a target. When using this option, the AUTO_VLAN + should not be set and the supported VLANs should have + configuration files supplied, constituting a static VLAN + configuration that provides the information for the FIP responder + to return. This should be set on a base device, which should + probably have FCOE_ENABLE set to "no" since presumably FCoE + operation will be on the configured VLANs. + Note that the attached Ethernet peer device (e.g. FCoE capable switch port) must have compatible settings For DCB and FCoE to function properly. diff --git a/doc/fcrls.8 b/doc/fcrls.8 index a384687..be7672c 100644 --- a/doc/fcrls.8 +++ b/doc/fcrls.8 @@ -1,20 +1,27 @@ '\" t .\" Title: fcrls .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] -.\" Generator: DocBook XSL Stylesheets v1.75.2 <http://docbook.sf.net/> -.\" Date: 06/04/2010 +.\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/> +.\" Date: 02/06/2013 .\" Manual: Open-FCoE Tools .\" Source: Open-FCoE .\" Language: English .\" -.TH "FCRLS" "8" "06/04/2010" "Open\-FCoE" "Open\-FCoE Tools" +.TH "FCRLS" "8" "02/06/2013" "Open\-FCoE" "Open\-FCoE Tools" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh -.\" disable justification (adjust text to left margin only) -.ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- diff --git a/doc/fipvlan.8 b/doc/fipvlan.8 index ba9daf7..5b2a2c2 100644 --- a/doc/fipvlan.8 +++ b/doc/fipvlan.8 @@ -1,13 +1,22 @@ '\" t .\" Title: fipvlan .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] -.\" Generator: DocBook XSL Stylesheets v1.75.2 <http://docbook.sf.net/> -.\" Date: 10/06/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/> +.\" Date: 02/06/2013 .\" Manual: Open-FCoE Tools .\" Source: Open-FCoE .\" Language: English .\" -.TH "FIPVLAN" "8" "10/06/2011" "Open\-FCoE" "Open\-FCoE Tools" +.TH "FIPVLAN" "8" "02/06/2013" "Open\-FCoE" "Open\-FCoE Tools" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,33 +31,18 @@ fipvlan \- Fibre Channel over Ethernet VLAN Discovery .sp \fBfipvlan\fR [\-c|\-\-create] [\-s|\-\-start] \fIinterfaces\fR .sp -\fBfipvlan\fR \-a|\-\-auto [\-c|\-\-create] [\-d|\-\-debug] -[\-s|\-\-start] [\-l|\-\-link-retry <num>] +\fBfipvlan\fR \-a|\-\-auto [\-c|\-\-create] [\-d|\-\-debug] [\-s|\-\-start] [\-l|\-\-link\-retry \fIcount\fR] .sp \fBfipvlan\fR \-h|\-\-help .sp \fBfipvlan\fR \-v|\-\-version .SH "DESCRIPTION" .sp -The \fBfipvlan\fR command performs Fibre Channel over Ethernet (FCoE) -Initialization Protocol (FIP) VLAN Discovery over Ethernet -interfaces\&. \fBfipvlan\fR can be used as a diagnostic tool to -determine which VLANs have FCoE services available on a network, prior -to configuring VLAN interfaces and the \fIOpen\-FCoE\fR -initiator\&. \fBfipvlan\fR can also be used to create VLAN interfaces -as they are discovered, and to start the \fIOpen\-FCoE\fR -initiator\&. The \fB\-\-create\fR and \fB\-\-start\fR options are -primarily intended to be used as part of an \fIOpen\-FCoE\fR boot -solution\&. FCoE instances started in this way cannot be destroyed or -reset by fcoeadm\&. +The \fBfipvlan\fR command performs Fibre Channel over Ethernet (FCoE) Initialization Protocol (FIP) VLAN Discovery over Ethernet interfaces\&. \fBfipvlan\fR can be used as a diagnostic tool to determine which VLANs have FCoE services available on a network, prior to configuring VLAN interfaces and the \fIOpen\-FCoE\fR initiator\&. \fBfipvlan\fR can also be used to create VLAN interfaces as they are discovered, and to start the \fIOpen\-FCoE\fR initiator\&. The \fB\-\-create\fR and \fB\-\-start\fR options are primarily intended to be used as part of an \fIOpen\-FCoE\fR boot solution\&. FCoE instances started in this way cannot be destroyed or reset by fcoeadm\&. .sp -\fBfipvlan\fR takes a list of network interface names to run the VLAN -discovery protocol over, or the \fB\-\-auto\fR option to use all -available Ethernet interfaces\&. +\fBfipvlan\fR takes a list of network interface names to run the VLAN discovery protocol over, or the \fB\-\-auto\fR option to use all available Ethernet interfaces\&. .sp -\fBfipvlan\fR will enable any interface which is found to be not -enabled by the time the program runs. If no response is received -on that interface it will be shutdown again when fipvlan terminates. +\fBfipvlan\fR will enable any interface which is found disabled\&. If no response is received on that interface it will be shutdown again when \fBfipvlan\fR terminates\&. .SH "OPTIONS" .PP \fB\-a\fR, \fB\-\-auto\fR @@ -73,15 +67,18 @@ Start the initiator on discovered FCoE VLANs .RE .PP -\fB\-f\fR, \fB\-\-suffix \fI<suffix string>\fR +\fB\-f\fR, \fB\-\-suffix\fR \fIsuffix\fR .RS 4 -Append the specified string \fI<suffix string>\fR to VLAN interface names. +Append the specified string +\fIsuffix\fR +to VLAN interface names\&. .RE .PP -\fB\-l\fR, \fB\-\-link-retry \fI<number of retries>\fR +\fB\-l\fR, \fB\-\-link\-retry\fR \fIcount\fR .RS 4 -Retry check for link up up to \fI<number of retries>\fR times. The -link state is retried every 500 ms. The default is 20. +Retry check for link up to +\fIcount\fR +times\&. The link state is checked every 500 ms\&. The default number of retries is 20\&. .RE .PP \fB\-h\fR, \fB\-\-help\fR @@ -97,10 +94,7 @@ version string .RE .SH "VLAN NAMING CONVENTIONS" .sp -The default VLAN device name is \fIdev\fR\&.\fIvlan\fR; where -\fIdev\fR is the name of the Ethernet parent device and \fIvlan\fR is -the discovered VLAN ID number\&. An optional suffix can be appended to -this with \fI-f\fR commandline option. +If a new VLAN device is created, it will have the name \fIdev\fR\&.\fIvlan\fR; where \fIdev\fR is the name of the Ethernet parent device and \fIvlan\fR is the discovered VLAN ID number\&. An optional suffix may be appended to this with the the \fB\-f\fR command line option\&. .SH "EXAMPLES" .sp Display all discoverable VLANs with FCoE services @@ -127,7 +121,7 @@ fipvlan \-\-create \-\-start eth2 .RE .\} .sp -In this example if FCoE services were available on VLAN 101 of network interface eth2, then a VLAN interface eth2\&.101\-fcoe would be created and used as the parent device for the initiator\&. +In this example if FCoE services were available on VLAN 101 of network interface eth2, then a VLAN interface eth2\&.101 would be created and used as the parent device for the initiator\&. .SH "SEE ALSO" .sp \fBfcoeadm\fR(8) \fBfcoemon\fR(8) diff --git a/etc/cfg-ethx b/etc/cfg-ethx index 616bff3..c5aaf36 100644 --- a/etc/cfg-ethx +++ b/etc/cfg-ethx @@ -15,3 +15,14 @@ DCB_REQUIRED="yes" # Indicate if VLAN discovery should be handled by fcoemon # Normally set to "yes" AUTO_VLAN="yes" + +## Type: fabric/vn2vn +## Default: fabric +# Indicate the mode of the FCoE operation, either fabric or vn2vn +# Normally set to "fabric" +MODE="fabric" + +## Type: yes/no +## Default: no +# Indicate whether to run a FIP responder for VLAN discovery in vn2vn mode +#FIP_RESP="yes" _______________________________________________ fcoe-devel mailing list [email protected] http://lists.open-fcoe.org/mailman/listinfo/fcoe-devel
