]> CyberLeo.Net >> Repos - FreeBSD/releng/9.2.git/blob - share/man/man4/natmip.4
- Copy stable/9 to releng/9.2 as part of the 9.2-RELEASE cycle.
[FreeBSD/releng/9.2.git] / share / man / man4 / natmip.4
1 .\"
2 .\" Copyright (c) 2003
3 .\"     Fraunhofer Institute for Open Communication Systems (FhG Fokus).
4 .\"     All rights reserved.
5 .\"
6 .\" Author: Hartmut Brandt <harti@FreeBSD.org>
7 .\"
8 .\" Redistribution and use in source and binary forms, with or without
9 .\" modification, are permitted provided that the following conditions
10 .\" are met:
11 .\" 1. Redistributions of source code must retain the above copyright
12 .\"    notice, this list of conditions and the following disclaimer.
13 .\" 2. Redistributions in binary form must reproduce the above copyright
14 .\"    notice, this list of conditions and the following disclaimer in the
15 .\"    documentation and/or other materials provided with the distribution.
16 .\"
17 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 .\" SUCH DAMAGE.
28 .\"
29 .\" $FreeBSD$
30 .\"
31 .Dd August 11, 2003
32 .Dt NATMIP 4
33 .Os
34 .Sh NAME
35 .Nm natmip
36 .Nd IP over ATM PVCs
37 .Sh SYNOPSIS
38 .Cd "device atm"
39 .Cd "options NATM"
40 .Sh DESCRIPTION
41 The NATM protocol stack includes support for IP over ATM.
42 Without any
43 additional signalling stacks or other modules it is possible to build
44 a CLIP (classical IP over ATM) network based on PVCs.
45 .Pp
46 An ATM network card
47 .Li ( en0
48 in this example) is configured for IP by something
49 like:
50 .Pp
51 .Dl "ifconfig en0 128.252.200.1 netmask 0xffffff00 up"
52 .Pp
53 IP routing is done with special interface routes (routes with directly
54 reachable destinations) with a link layer gateway address.
55 The link layer address specifies the ATM interface through which the
56 destination can be reached, the virtual channel that connects to the
57 destination and the ATM characteristics of this channel.
58 The address part of the link layer address (see
59 .Xr link_addr 3 )
60 consists of a fixed part (the first 5 bytes) and a part that
61 depends on the kind of the PVC (UBR, CBR, VBR, ABR).
62 Multi-byte values
63 are big-endian encoded: the bytes with the lower numbers contain the
64 higher order bits.
65 .Bl -tag -width "bytes 12...12" -offset indent
66 .It byte 0
67 Is a flag byte.
68 Currently only flag 0x20 is used.
69 When set, all IP frames are LLC/SNAP encapsulated before putting them into
70 an AAL5 frame.
71 Setting this flag is recommended and allows interoperability with other
72 CLIP implementations.
73 Note that BPF works only with LLC/SNAP encapsulation.
74 .It byte 1
75 This is the VPI of the channel.
76 .It bytes 2...3
77 VCI of the channel.
78 Must not be zero.
79 .It byte 4
80 Traffic type.
81 One of 0 (UBR), 1 (CBR), 2 (ABR), 3 (VBR).
82 .El
83 .Pp
84 The variable part for UBR connections may be either empty or three bytes:
85 .Bl -tag -width "bytes 12...12" -offset indent
86 .It bytes 5...7
87 Specifies the peak cell rate for UBR.
88 .El
89 .Pp
90 The variable part for CBR connections must be three bytes:
91 .Bl -tag -width "bytes 12...12" -offset indent
92 .It bytes 5...7
93 Specifies the peak cell rate for CBR.
94 .El
95 .Pp
96 The variable part for VBR connections must be 9 bytes long and specifies three
97 values:
98 .Bl -tag -width "bytes 12...12" -offset indent
99 .It bytes 5...7
100 Specifies the peak cell rate for VBR.
101 .It bytes 8...10
102 This is the sustainable cell rate.
103 .It bytes 11...13
104 The maximum burst size.
105 .El
106 .Pp
107 The variable part for ABR connections must be 19 bytes long and specifies the
108 following values:
109 .Bl -tag -width "bytes 12...12" -offset indent
110 .It bytes 5...7
111 Specifies the peak cell rate for ABR.
112 .It bytes 8...10
113 The minimum cell rate.
114 .It bytes 11...13
115 The initial cell rate.
116 .It bytes 14...16
117 The transient buffer exposure.
118 .It byte 17
119 The NRM value.
120 .It byte 18
121 The TRM value.
122 .It bytes 19...20
123 The ADTF value.
124 .It byte 21
125 The rate increase factor (RIF).
126 .It byte 22
127 The rate decrease factor (RDF).
128 .It byte 23
129 The cutoff decrease factor (CDF).
130 .El
131 .Pp
132 To add a PVC the
133 .Xr route 8
134 utility can be used:
135 .Bd -ragged -offset indent
136 .Nm route Cm add
137 .Fl iface Aq Ar "remote\ IP\ address"
138 .Fl link Ao Ar iface Ac : Ns Aq Ar lladdr
139 .Ed
140 .Pp
141 The
142 .Ar iface
143 is the ATM interface through which
144 .Ar "remote\ IP\ address"
145 can be reached and
146 .Ar lladdr
147 is the link layer address as a string of dot-separated, hexadecimal bytes.
148 .Pp
149 NATM also supports the old, original format.
150 This consists of 4 byte
151 link layer addresses (and the channels are implicit UBR):
152 .Bl -tag -width "bytes 12...12" -offset indent
153 .It byte 0
154 Flags:
155 .Bl -tag -width "0x02" -offset indent -compact
156 .It 0x01
157 use AAL5.
158 .It 0x02
159 if using AAL5, use an LLC/SNAP header.
160 .El
161 .Pp
162 Thus, parameter 3 means AAL5 and LLC/SNAP encapsulation (this is the required
163 setting for interworking with other CLIP clients).
164 Note that BPF works only with LLC/SNAP encapsulation.
165 .It byte 1
166 VPI for the channel
167 .It bytes 2...3
168 VCI for the channel
169 .El
170 .Sh EXAMPLES
171 Suppose you have 3 hosts 128.252.200.1, 128.252.200.2 and
172 128.252.200.3 connected by ATM through PVCs:
173 .Pp
174 .Bl -item -offset indent -compact
175 .It
176 between 128.252.200.1 and 128.252.200.2: 0xc9 UBR
177 .It
178 between 128.252.200.1 and 128.252.200.3: 0xca VBR
179 .It
180 between 128.252.200.2 and 128.252.200.3: 0xcb CBR
181 .El
182 .Pp
183 The parameters for the VBR channel are: PCR 50000, SCR 10000, MBS 10.
184 The peak cell rate for the CBR channel is 100000.
185 .Pp
186 To enable the links use the following commands:
187 .Pp
188 on host 128.252.200.1:
189 .Bd -literal -offset indent -compact
190 ifconfig en0 128.252.200.1 netmask 0xffffff00 up
191 route add -iface 128.252.200.2 -link en0:3.0.0.c9.0
192 route add -iface 128.252.200.3 -link en0:3.0.0.ca.3.0.c3.50.0.27.10.0.0.a
193 .Ed
194 .Pp
195 on host 128.252.200.2:
196 .Bd -literal -offset indent -compact
197 ifconfig en0 128.252.200.2 netmask 0xffffff00 up
198 route add -iface 128.252.200.1 -link en0:3.0.0.c9.0
199 route add -iface 128.252.200.3 -link en0:3.0.0.cb.1.1.86.a0
200 .Ed
201 .Pp
202 on host 128.252.200.3:
203 .Bd -literal -offset indent -compact
204 ifconfig en0 128.252.200.3 netmask 0xffffff00 up
205 route add -iface 128.252.200.1 -link en0:3.0.0.ca.3.0.c3.50.0.27.10.0.0.a
206 route add -iface 128.252.200.2 -link en0:3.0.0.cb.1.1.86.a0
207 .Ed
208 .Pp
209 This can also be done in
210 .Xr rc.conf 5 :
211 .Pp
212 on host 128.252.200.1:
213 .Bd -literal -offset indent -compact
214 network_interfaces="lo0 en0"
215 ifconfig_en0="inet 128.252.200.1 netmask 255.255.255.0"
216 static_routes="host2 host3"
217 route_host2="-iface 128.252.200.2 -link en0:3.0.0.c9.0"
218 route_host3="-iface 128.252.200.3 -link en0:3.0.0.ca.3.0.c3.50.0.27.10.0.0.a"
219 .Ed
220 .Pp
221 on host 128.252.200.2:
222 .Bd -literal -offset indent -compact
223 network_interfaces="lo0 en0"
224 ifconfig_en0="inet 128.252.200.2 netmask 255.255.255.0"
225 static_routes="host1 host3"
226 route_host1="-iface 128.252.200.1 -link en0:3.0.0.c9.0"
227 route_host3="-iface 128.252.200.3 -link en0:3.0.0.cb.1.1.86.a0"
228 .Ed
229 .Pp
230 on host 128.252.200.3:
231 .Bd -literal -offset indent -compact
232 network_interfaces="lo0 en0"
233 ifconfig_en0="inet 128.252.200.3 netmask 255.255.255.0"
234 static_routes="host1 host2"
235 route_host1="-iface 128.252.200.1 -link en0:3.0.0.ca.3.0.c3.50.0.27.10.0.0.a"
236 route_host2="-iface 128.252.200.2 -link en0:3.0.0.cb.1.1.86.a0"
237 .Ed
238 .Sh SEE ALSO
239 .Xr en 4 ,
240 .Xr fatm 4 ,
241 .Xr hatm 4 ,
242 .Xr natm 4 ,
243 .Xr patm 4
244 .Sh AUTHORS
245 .An Chuck Cranor
246 of Washington University implemented the NATM protocol layer
247 along with the EN ATM driver in 1996 for
248 .Nx .