diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index 4c86b54..4bc110d 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -133,8 +133,10 @@ MAN= aac.4 \ ng_cisco.4 \ nge.4 \ ng_echo.4 \ + ng_eiface.4 \ ng_etf.4 \ ng_ether.4 \ + ng_fec.4 \ ng_frame_relay.4 \ ng_hole.4 \ ng_iface.4 \ diff --git a/share/man/man4/ng_eiface.4 b/share/man/man4/ng_eiface.4 new file mode 100644 index 0000000..adc7896 --- /dev/null +++ b/share/man/man4/ng_eiface.4 @@ -0,0 +1,123 @@ +.\" Copyright (c) 2004 Gleb Smirnoff +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man4/ng_eiface.4,v 1.3.2.1 2005/02/03 13:49:18 ru Exp $ +.\" $DragonFly$ +.\" +.Dd February 3, 2005 +.Dt NG_EIFACE 4 +.Os +.Sh NAME +.Nm ng_eiface +.Nd "generic Ethernet interface netgraph node type" +.Sh SYNOPSIS +.In netgraph/ng_eiface.h +.Sh DESCRIPTION +The +.Vt eiface +netgraph node implements the generic Ethernet interface. +When +.Vt eiface +node is created, a new interface appears which is accessible via +.Xr ifconfig 8 . +These interfaces are named +.Dq Li ngeth0 , +.Dq Li ngeth1 , +etc. +When a node is shut down, the corresponding interface is removed, +and the interface name becomes available for reuse by future +.Vt eiface +nodes. +New nodes always take the first unused interface. +.Sh HOOKS +An +.Vt eiface +node has a single hook named +.Va ether , +which should be connected to the +Ethernet downstream, for example, to the +.Xr ng_vlan 4 +node. +Packets transmitted via the interface flow out this hook. +Similarly, packets received on the hook go to the protocol stack as +packets received by any real Ethernet interface. +.Sh CONTROL MESSAGES +This node type supports the generic control messages, plus the following: +.Bl -tag -width indent +.It Dv NGM_EIFACE_SET Pq Li set +Set link-level address of the interface. +Requires +.Vt "struct ether_addr" +as an argument. +This message also has an +.Tn ASCII +version, called +.Dq Li set , +which requires as an argument an +.Tn ASCII +string consisting of 6 colon-separated hex digits. +.It Dv NGM_EIFACE_GET_IFNAME Pq Li getifname +Return the name of the associated interface as a +.Dv NUL Ns -terminated +.Tn ASCII +string. +.It Dv NGM_EIFACE_GET_IFADDRS +Return the list of link-level addresses associated with the node. +.El +.Sh SHUTDOWN +This node shuts down upon receipt of a +.Dv NGM_SHUTDOWN +control message. +The associated interface is removed and its name becomes +available for reuse by future +.Vt eiface +nodes. +.Pp +Unlike most other node types, an +.Vt eiface +node does +.Em not +go away when all hooks have been disconnected; rather, and explicit +.Dv NGM_SHUTDOWN +control message is required. +.Sh SEE ALSO +.Xr netgraph 4 , +.Xr ng_ether 4 , +.Xr ng_iface 4 , +.Xr ng_vlan 4 , +.Xr ifconfig 8 , +.Xr ngctl 8 +.Sh HISTORY +The +.Vt eiface +node type was implemented in +.Fx 4.6 . +.Sh AUTHORS +.An -nosplit +The +.Vt eiface +node type was written by +.An Vitaly V Belekhov . +This manual page was written by +.An Gleb Smirnoff . diff --git a/share/man/man4/ng_fec.4 b/share/man/man4/ng_fec.4 new file mode 100644 index 0000000..779e5c7 --- /dev/null +++ b/share/man/man4/ng_fec.4 @@ -0,0 +1,104 @@ +.\" Copyright (c) 2004 Gleb Smirnoff +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man4/ng_fec.4,v 1.2.4.1 2004/09/05 10:26:00 glebius Exp $ +.\" $DragonFly$ +.\" +.Dd July 22, 2004 +.Dt NG_FEC 4 +.Os +.Sh NAME +.Nm ng_fec +.Nd netgraph Fast EtherChannel node +.Sh SYNOPSIS +.In netgraph/ng_fec.h +.Sh DESCRIPTION +The +.Nm fec +node implements Ethernet port trunking using Cisco Fast EtherChannel protocol. +Upon creation, node creates a network interface associated with it. +Interfaces are named +.Dq Li fec0 , +.Dq Li fec1 , +etc. +New node takes first available unit. +.Sh HOOKS +The +.Nm fec +node accepts any hooks. +However it does not use them. +Under normal operation, node should not have any hooks. +.Sh CONTROL MESSAGES +Interface membership in the FEC group is configured with the following +control messages: +.Bl -tag -width indent +.It Dv NGM_FEC_ADD_IFACE Pq Dq Li add_iface +Attach interface to the FEC group. +Target interface name is passed as a string argument. +.It Dv NGM_FEC_DEL_IFACE Pq Dq Li del_iface +Remove interface from the trunk. +Target interface name is passed as a string argument. +.El +.Pp +The following control messages define forwarding method for a node: +.Bl -tag -width indent +.It Dv NGM_FEC_MODE_INET Pq Dq Li set_mode_mac +Forwarding decisions will be made on destination link layer MAC addresses. +.It Dv NGM_FEC_MODE_MAC Pq Dq Li set_mode_inet +Forwarding decisions will be made on destination IP addresses. +.El +.Sh SHUTDOWN +This node shuts down upon receipt of a +.Dv NGM_SHUTDOWN +control message. +.Sh EXAMPLES +This example script creates a +.Nm fec +node, attaches four Ethernet interfaces to it and +sets forwarding method based on IP address: +.Bd -literal -offset indent +/usr/sbin/ngctl -f- <<-SEQ + mkpeer fec dummy fec + msg fec0: add_iface "dc0" + msg fec0: add_iface "dc1" + msg fec0: add_iface "dc2" + msg fec0: add_iface "dc3" + msg fec0: set_mode_inet +SEQ +.Ed +.Sh SEE ALSO +.Xr netgraph 4 +.Sh HISTORY +The +.Nm fec +node type was implemented in +.Fx 5.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm fec +node was written by +.An "Bill Paul" Aq wpaul@FreeBSD.org . +This manual page was written by +.An "Gleb Smirnoff" .