*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->FreeBSD man pages -> ng_iface (4)              
Title
Content
Arch
Section
 

NG_IFACE(4)

Contents


NAME    [Toc]    [Back]

     ng_iface -- interface netgraph node type

SYNOPSIS    [Toc]    [Back]

     #include <netgraph/ng_iface.h>

DESCRIPTION    [Toc]    [Back]

     An iface node is both a netgraph node and a system networking interface.
     When an iface node is created, a new interface appears which is accessible
 via ifconfig(8).  Iface node interfaces are named ng0, ng1, etc.
     When a node is shutdown, the corresponding interface is removed and the
     interface name becomes available for reuse by future iface nodes; new
     nodes always take the first unused interface.  The node itself is
     assigned the same name as its interface, unless the name already exists,
     in which case the node remains unnamed.

     An iface node has a single hook corresponding to each supported protocol.
     Packets transmitted via the interface flow out the corresponding protocol-specific
 hook.  Similarly, packets received on a hook appear on the
     interface as packets received into the corresponding protocol stack.  The
     currently supported protocols are IP, IPv6, AppleTalk, IPX, ATM, NATM,
     and NS.

     An iface node be configured as a point-to-point interface or a broadcast
     interface.  The configuration can only be changed when the interface is
     down.  The default mode is point-to-point.

     Iface nodes support the Berkeley Packet Filter (BPF).

HOOKS    [Toc]    [Back]

     This node type supports the following hooks:

     inet    Transmission and reception of IP packets.

     inet6   Transmission and reception of IPv6 packets.

     atalk   Transmission and reception of AppleTalk packets.

     ipx     Transmission and reception of IPX packets.

     atm     Transmission and reception of ATM packets.

     natm    Transmission and reception of NATM packets.

     ns      Transmission and reception of NS packets.

CONTROL MESSAGES    [Toc]    [Back]

     This node type supports the generic control messages, plus the following:

     NGM_IFACE_GET_IFNAME
	  Returns the name of the interface corresponding to this node in a
	  struct ng_iface_ifname:

	      struct ng_iface_ifname {
		char  ngif_name[NG_IFACE_IFACE_NAME_MAX + 1];
	      };

     NGM_IFACE_POINT2POINT
	  Set the interface to point-to-point mode.  The interface must not
	  currently be up.

     NGM_IFACE_BROADCAST
	  Set the interface to broadcast mode.	The interface must not currently
 be up.

     NGM_CISCO_GET_IPADDR
	  This message is defined by the ng_cisco(4) node type; see
	  ng_cisco(4) for a description.

SHUTDOWN    [Toc]    [Back]

     This node shuts down upon receipt of a NGM_SHUTDOWN control message.  The
     associated interface is removed and becomes available for use by future
     iface nodes.

     Unlike most other node types, an iface node does not go away when all
     hooks have been disconnected; rather, and explicit NGM_SHUTDOWN control
     message is required.

SEE ALSO    [Toc]    [Back]

      
      
     bpf(4), netgraph(4), ng_cisco(4), ifconfig(8), ngctl(8)

HISTORY    [Toc]    [Back]

     The iface node type was implemented in FreeBSD 4.0.

AUTHORS    [Toc]    [Back]

     Archie Cobbs <archie@FreeBSD.org>


FreeBSD 5.2.1		       January 19, 1999 		 FreeBSD 5.2.1
[ Back ]
 Similar pages
Name OS Title
ng_gif FreeBSD generic tunnel interface netgraph node type
ng_hci FreeBSD Netgraph node type that is also a Bluetooth Host Controller Interface (HCI) layer
ng_atm FreeBSD netgraph ATM node type
ng_uni FreeBSD netgraph UNI node type
ng_UI FreeBSD UI netgraph node type
ng_ip_input FreeBSD netgraph IP input node type
ng_device FreeBSD device netgraph node type
ng_echo FreeBSD netgraph echo node type
ng_rfc1490 FreeBSD RFC 1490 netgraph node type
ng_ether FreeBSD Ethernet netgraph node type
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service