[a088964] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[b06ca36] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[a088964] | 4 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
[bdea25ce] | 7 |
|
---|
[81fd230] | 8 | <sect1 id="ch-system-iproute2" role="wrap">
|
---|
[bdea25ce] | 9 | <?dbhtml filename="iproute2.html"?>
|
---|
| 10 |
|
---|
[e747759] | 11 | <sect1info condition="script">
|
---|
| 12 | <productname>iproute2</productname>
|
---|
| 13 | <productnumber>&iproute2-version;</productnumber>
|
---|
| 14 | <address>&iproute2-url;</address>
|
---|
| 15 | </sect1info>
|
---|
| 16 |
|
---|
[f0d59f2] | 17 | <title>IPRoute2-&iproute2-version;</title>
|
---|
[bdea25ce] | 18 |
|
---|
[a088964] | 19 | <indexterm zone="ch-system-iproute2">
|
---|
[89ed081] | 20 | <primary sortas="a-IPRoute2">IPRoute2</primary>
|
---|
[a088964] | 21 | </indexterm>
|
---|
[bdea25ce] | 22 |
|
---|
[a088964] | 23 | <sect2 role="package">
|
---|
| 24 | <title/>
|
---|
[bdea25ce] | 25 |
|
---|
| 26 | <para>The IPRoute2 package contains programs for basic and advanced IPV4-based
|
---|
| 27 | networking.</para>
|
---|
| 28 |
|
---|
[a088964] | 29 | <segmentedlist>
|
---|
| 30 | <segtitle>&buildtime;</segtitle>
|
---|
| 31 | <segtitle>&diskspace;</segtitle>
|
---|
[bdea25ce] | 32 |
|
---|
[a088964] | 33 | <seglistitem>
|
---|
[e4a5635] | 34 | <seg>&iproute2-ch6-sbu;</seg>
|
---|
| 35 | <seg>&iproute2-ch6-du;</seg>
|
---|
[a088964] | 36 | </seglistitem>
|
---|
| 37 | </segmentedlist>
|
---|
[bdea25ce] | 38 |
|
---|
[a088964] | 39 | </sect2>
|
---|
[bdea25ce] | 40 |
|
---|
[a088964] | 41 | <sect2 role="installation">
|
---|
[f0d59f2] | 42 | <title>Installation of IPRoute2</title>
|
---|
[a088964] | 43 |
|
---|
| 44 | <para>Compile the package:</para>
|
---|
| 45 |
|
---|
[0445a3d] | 46 | <screen><userinput remap="make">make SBINDIR=/sbin</userinput></screen>
|
---|
[81fd230] | 47 |
|
---|
| 48 | <variablelist>
|
---|
[bdea25ce] | 49 | <title>The meaning of the make option:</title>
|
---|
| 50 |
|
---|
| 51 | <varlistentry>
|
---|
| 52 | <term><parameter>SBINDIR=/sbin</parameter></term>
|
---|
| 53 | <listitem>
|
---|
| 54 | <para>This ensures that the IPRoute2 binaries will install into
|
---|
| 55 | <filename class="directory">/sbin</filename>. This is the correct
|
---|
| 56 | location according to the FHS, because some of the IPRoute2 binaries
|
---|
| 57 | are used by the LFS-Bootscripts package.</para>
|
---|
| 58 | </listitem>
|
---|
| 59 | </varlistentry>
|
---|
| 60 |
|
---|
[81fd230] | 61 | </variablelist>
|
---|
| 62 |
|
---|
[971be6b] | 63 | <para>This package comes with a testsuite, but due to assumptions it makes,
|
---|
| 64 | it is not possible to reliably run these tests from within the chroot
|
---|
| 65 | environment. If you wish to run these tests after booting into your new LFS
|
---|
| 66 | system, ensure you select <filename>/proc/config.gz</filename>
|
---|
| 67 | CONFIG_IKCONFIG_PROC ("General setup" -> "Enable access to
|
---|
| 68 | .config through /proc/config.gz") support into your kernel then run
|
---|
| 69 | 'make alltests' from the <filename class="directory">testsuite/</filename>
|
---|
| 70 | subdirectory.</para>
|
---|
[0be3d41] | 71 |
|
---|
[81fd230] | 72 | <para>Install the package:</para>
|
---|
| 73 |
|
---|
[0445a3d] | 74 | <screen><userinput remap="install">make SBINDIR=/sbin install</userinput></screen>
|
---|
[bdea25ce] | 75 |
|
---|
| 76 | <para>The <command>arpd</command> binary links against the Berkeley DB
|
---|
| 77 | libraries that reside in <filename class="directory">/usr</filename> and
|
---|
| 78 | uses a database in <filename>/var/lib/arpd/arpd.db</filename>. Thus,
|
---|
| 79 | according to the FHS, it must be in <filename
|
---|
| 80 | class="directory">/usr/sbin</filename>. Move it there:</para>
|
---|
[fa21b3d] | 81 |
|
---|
[0445a3d] | 82 | <screen><userinput remap="install">mv -v /sbin/arpd /usr/sbin</userinput></screen>
|
---|
[bdea25ce] | 83 |
|
---|
[a088964] | 84 | </sect2>
|
---|
| 85 |
|
---|
| 86 | <sect2 id="contents-iproute2" role="content">
|
---|
[f0d59f2] | 87 | <title>Contents of IPRoute2</title>
|
---|
[bdea25ce] | 88 |
|
---|
[81fd230] | 89 | <segmentedlist>
|
---|
| 90 | <segtitle>Installed programs</segtitle>
|
---|
[bdea25ce] | 91 |
|
---|
[81fd230] | 92 | <seglistitem>
|
---|
[2791a8e] | 93 | <seg>arpd, ctstat (link to lnstat), genl, ifcfg, ifstat, ip, lnstat,
|
---|
| 94 | nstat, routef, routel, rtacct, rtmon, rtpr, rtstat (link to lnstat), ss,
|
---|
[bdea25ce] | 95 | and tc.</seg>
|
---|
[81fd230] | 96 | </seglistitem>
|
---|
| 97 | </segmentedlist>
|
---|
| 98 |
|
---|
[bdea25ce] | 99 | <variablelist>
|
---|
| 100 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 101 | <?dbfo list-presentation="list"?>
|
---|
| 102 | <?dbhtml list-presentation="table"?>
|
---|
| 103 |
|
---|
[fa21b3d] | 104 | <varlistentry id="arpd">
|
---|
[bdea25ce] | 105 | <term><command>arpd</command></term>
|
---|
[fa21b3d] | 106 | <listitem>
|
---|
[bdea25ce] | 107 | <para>Userspace ARP daemon, useful in really large networks, where the
|
---|
| 108 | kernelspace ARP implementation is insufficient, or when setting up a
|
---|
| 109 | honeypot</para>
|
---|
[fa21b3d] | 110 | <indexterm zone="ch-system-iproute2 arpd">
|
---|
| 111 | <primary sortas="b-arpd">arpd</primary>
|
---|
| 112 | </indexterm>
|
---|
| 113 | </listitem>
|
---|
| 114 | </varlistentry>
|
---|
| 115 |
|
---|
[46a500e] | 116 | <varlistentry id="ctstat">
|
---|
[bdea25ce] | 117 | <term><command>ctstat</command></term>
|
---|
[46a500e] | 118 | <listitem>
|
---|
[89ed081] | 119 | <para>Connection status utility</para>
|
---|
[46a500e] | 120 | <indexterm zone="ch-system-iproute2 ctstat">
|
---|
[005dc3f] | 121 | <primary sortas="b-ctstat">ctstat</primary>
|
---|
[46a500e] | 122 | </indexterm>
|
---|
| 123 | </listitem>
|
---|
| 124 | </varlistentry>
|
---|
| 125 |
|
---|
[2791a8e] | 126 | <varlistentry id="genl">
|
---|
| 127 | <term><command>genl</command></term>
|
---|
| 128 | <listitem>
|
---|
| 129 | <para></para>
|
---|
| 130 | <indexterm zone="ch-system-iproute2 genl">
|
---|
| 131 | <primary sortas="b-genl">genl</primary>
|
---|
| 132 | </indexterm>
|
---|
| 133 | </listitem>
|
---|
| 134 | </varlistentry>
|
---|
| 135 |
|
---|
[46a500e] | 136 | <varlistentry id="ifcfg">
|
---|
[bdea25ce] | 137 | <term><command>ifcfg</command></term>
|
---|
[46a500e] | 138 | <listitem>
|
---|
[89ed081] | 139 | <para>A shell script wrapper for the <command>ip</command> command</para>
|
---|
[46a500e] | 140 | <indexterm zone="ch-system-iproute2 ifcfg">
|
---|
| 141 | <primary sortas="b-ifcfg">ifcfg</primary>
|
---|
| 142 | </indexterm>
|
---|
| 143 | </listitem>
|
---|
| 144 | </varlistentry>
|
---|
[81fd230] | 145 |
|
---|
| 146 | <varlistentry id="ifstat">
|
---|
[bdea25ce] | 147 | <term><command>ifstat</command></term>
|
---|
[81fd230] | 148 | <listitem>
|
---|
[bdea25ce] | 149 | <para>Shows the interface statistics, including the amount of
|
---|
| 150 | transmitted and received packets by interface</para>
|
---|
[81fd230] | 151 | <indexterm zone="ch-system-iproute2 ifstat">
|
---|
| 152 | <primary sortas="b-ifstat">ifstat</primary>
|
---|
| 153 | </indexterm>
|
---|
| 154 | </listitem>
|
---|
| 155 | </varlistentry>
|
---|
| 156 |
|
---|
| 157 | <varlistentry id="ip">
|
---|
[bdea25ce] | 158 | <term><command>ip</command></term>
|
---|
[81fd230] | 159 | <listitem>
|
---|
| 160 | <para>The main executable. It has several different functions:</para>
|
---|
| 161 |
|
---|
[0090db5] | 162 | <para><command>ip link <replaceable><device></replaceable></command>
|
---|
[bdea25ce] | 163 | allows users to look at the state of devices and to make changes</para>
|
---|
[81fd230] | 164 |
|
---|
| 165 | <para><command>ip addr</command> allows users to look at addresses and
|
---|
[bdea25ce] | 166 | their properties, add new addresses, and delete old ones</para>
|
---|
[81fd230] | 167 |
|
---|
[bdea25ce] | 168 | <para><command>ip neighbor</command> allows users to look at neighbor
|
---|
| 169 | bindings and their properties, add new neighbor entries, and delete
|
---|
| 170 | old ones</para>
|
---|
[81fd230] | 171 |
|
---|
| 172 | <para><command>ip rule</command> allows users to look at the routing
|
---|
[bdea25ce] | 173 | policies and change them</para>
|
---|
[81fd230] | 174 |
|
---|
| 175 | <para><command>ip route</command> allows users to look at the routing
|
---|
[bdea25ce] | 176 | table and change routing table rules</para>
|
---|
[81fd230] | 177 |
|
---|
| 178 | <para><command>ip tunnel</command> allows users to look at the IP
|
---|
[bdea25ce] | 179 | tunnels and their properties, and change them</para>
|
---|
[81fd230] | 180 |
|
---|
| 181 | <para><command>ip maddr</command> allows users to look at the multicast
|
---|
[bdea25ce] | 182 | addresses and their properties, and change them</para>
|
---|
[81fd230] | 183 |
|
---|
| 184 | <para><command>ip mroute</command> allows users to set, change, or
|
---|
[bdea25ce] | 185 | delete the multicast routing</para>
|
---|
[81fd230] | 186 |
|
---|
[bdea25ce] | 187 | <para><command>ip monitor</command> allows users to continously monitor
|
---|
| 188 | the state of devices, addresses and routes</para>
|
---|
[81fd230] | 189 | <indexterm zone="ch-system-iproute2 ip">
|
---|
| 190 | <primary sortas="b-ip">ip</primary>
|
---|
| 191 | </indexterm>
|
---|
| 192 | </listitem>
|
---|
| 193 | </varlistentry>
|
---|
| 194 |
|
---|
[46a500e] | 195 | <varlistentry id="lnstat">
|
---|
[bdea25ce] | 196 | <term><command>lnstat</command></term>
|
---|
[46a500e] | 197 | <listitem>
|
---|
| 198 | <para>Provides Linux network statistics. It is a generalized and more
|
---|
[bdea25ce] | 199 | feature-complete replacement for the old <command>rtstat</command>
|
---|
| 200 | program</para>
|
---|
[46a500e] | 201 | <indexterm zone="ch-system-iproute2 lnstat">
|
---|
[005dc3f] | 202 | <primary sortas="b-lnstat">lnstat</primary>
|
---|
[46a500e] | 203 | </indexterm>
|
---|
| 204 | </listitem>
|
---|
| 205 | </varlistentry>
|
---|
| 206 |
|
---|
[81fd230] | 207 | <varlistentry id="nstat">
|
---|
[bdea25ce] | 208 | <term><command>nstat</command></term>
|
---|
[81fd230] | 209 | <listitem>
|
---|
[89ed081] | 210 | <para>Shows network statistics</para>
|
---|
[81fd230] | 211 | <indexterm zone="ch-system-iproute2 nstat">
|
---|
| 212 | <primary sortas="b-nstat">nstat</primary>
|
---|
| 213 | </indexterm>
|
---|
| 214 | </listitem>
|
---|
| 215 | </varlistentry>
|
---|
| 216 |
|
---|
| 217 | <varlistentry id="routef">
|
---|
[bdea25ce] | 218 | <term><command>routef</command></term>
|
---|
[81fd230] | 219 | <listitem>
|
---|
[bdea25ce] | 220 | <para>A component of <command>ip route</command>. This is for flushing
|
---|
| 221 | the routing tables</para>
|
---|
[81fd230] | 222 | <indexterm zone="ch-system-iproute2 routef">
|
---|
| 223 | <primary sortas="b-routef">routef</primary>
|
---|
| 224 | </indexterm>
|
---|
| 225 | </listitem>
|
---|
| 226 | </varlistentry>
|
---|
| 227 |
|
---|
| 228 | <varlistentry id="routel">
|
---|
[bdea25ce] | 229 | <term><command>routel</command></term>
|
---|
[81fd230] | 230 | <listitem>
|
---|
[bdea25ce] | 231 | <para>A component of <command>ip route</command>. This is for listing
|
---|
| 232 | the routing tables</para>
|
---|
[81fd230] | 233 | <indexterm zone="ch-system-iproute2 routel">
|
---|
| 234 | <primary sortas="b-routel">routel</primary>
|
---|
| 235 | </indexterm>
|
---|
| 236 | </listitem>
|
---|
| 237 | </varlistentry>
|
---|
| 238 |
|
---|
[46a500e] | 239 | <varlistentry id="rtacct">
|
---|
[bdea25ce] | 240 | <term><command>rtacct</command></term>
|
---|
[46a500e] | 241 | <listitem>
|
---|
[bdea25ce] | 242 | <para>Displays the contents of
|
---|
| 243 | <filename>/proc/net/rt_acct</filename></para>
|
---|
[46a500e] | 244 | <indexterm zone="ch-system-iproute2 rtacct">
|
---|
| 245 | <primary sortas="b-rtacct">rtacct</primary>
|
---|
| 246 | </indexterm>
|
---|
| 247 | </listitem>
|
---|
| 248 | </varlistentry>
|
---|
| 249 |
|
---|
[81fd230] | 250 | <varlistentry id="rtmon">
|
---|
[bdea25ce] | 251 | <term><command>rtmon</command></term>
|
---|
[81fd230] | 252 | <listitem>
|
---|
[89ed081] | 253 | <para>Route monitoring utility</para>
|
---|
[81fd230] | 254 | <indexterm zone="ch-system-iproute2 rtmon">
|
---|
| 255 | <primary sortas="b-rtmon">rtmon</primary>
|
---|
| 256 | </indexterm>
|
---|
| 257 | </listitem>
|
---|
| 258 | </varlistentry>
|
---|
| 259 |
|
---|
[46a500e] | 260 | <varlistentry id="rtpr">
|
---|
[bdea25ce] | 261 | <term><command>rtpr</command></term>
|
---|
[46a500e] | 262 | <listitem>
|
---|
| 263 | <para>Converts the output of <command>ip -o</command> back into a
|
---|
[bdea25ce] | 264 | readable form</para>
|
---|
[46a500e] | 265 | <indexterm zone="ch-system-iproute2 rtpr">
|
---|
| 266 | <primary sortas="b-rtpr">rtpr</primary>
|
---|
| 267 | </indexterm>
|
---|
| 268 | </listitem>
|
---|
| 269 | </varlistentry>
|
---|
| 270 |
|
---|
[81fd230] | 271 | <varlistentry id="rtstat">
|
---|
[bdea25ce] | 272 | <term><command>rtstat</command></term>
|
---|
[81fd230] | 273 | <listitem>
|
---|
[89ed081] | 274 | <para>Route status utility</para>
|
---|
[81fd230] | 275 | <indexterm zone="ch-system-iproute2 rtstat">
|
---|
| 276 | <primary sortas="b-rtstat">rtstat</primary>
|
---|
| 277 | </indexterm>
|
---|
| 278 | </listitem>
|
---|
| 279 | </varlistentry>
|
---|
| 280 |
|
---|
| 281 | <varlistentry id="ss">
|
---|
[bdea25ce] | 282 | <term><command>ss</command></term>
|
---|
[81fd230] | 283 | <listitem>
|
---|
[bdea25ce] | 284 | <para>Similar to the <command>netstat</command> command; shows active
|
---|
| 285 | connections</para>
|
---|
[81fd230] | 286 | <indexterm zone="ch-system-iproute2 ss">
|
---|
| 287 | <primary sortas="b-ss">ss</primary>
|
---|
| 288 | </indexterm>
|
---|
| 289 | </listitem>
|
---|
| 290 | </varlistentry>
|
---|
| 291 |
|
---|
| 292 | <varlistentry id="tc">
|
---|
[bdea25ce] | 293 | <term><command>tc</command></term>
|
---|
[81fd230] | 294 | <listitem>
|
---|
[bdea25ce] | 295 | <para>Traffic Controlling Executable; this is for Quality Of Service
|
---|
| 296 | (QOS) and Class Of Service (COS) implementations</para>
|
---|
[81fd230] | 297 |
|
---|
| 298 | <para><command>tc qdisc</command> allows users to setup the queueing
|
---|
[bdea25ce] | 299 | discipline</para>
|
---|
[81fd230] | 300 |
|
---|
[bdea25ce] | 301 | <para><command>tc class</command> allows users to setup classes based
|
---|
| 302 | on the queuing discipline scheduling</para>
|
---|
[81fd230] | 303 |
|
---|
| 304 | <para><command>tc estimator</command> allows users to estimate the
|
---|
[bdea25ce] | 305 | network flow into a network</para>
|
---|
[81fd230] | 306 |
|
---|
| 307 | <para><command>tc filter</command> allows users to setup the QOS/COS
|
---|
[bdea25ce] | 308 | packet filtering</para>
|
---|
[81fd230] | 309 |
|
---|
| 310 | <para><command>tc policy</command> allows users to setup the QOS/COS
|
---|
[bdea25ce] | 311 | policies</para>
|
---|
[81fd230] | 312 | <indexterm zone="ch-system-iproute2 ss">
|
---|
| 313 | <primary sortas="b-tc">tc</primary>
|
---|
| 314 | </indexterm>
|
---|
| 315 | </listitem>
|
---|
| 316 | </varlistentry>
|
---|
[bdea25ce] | 317 |
|
---|
[81fd230] | 318 | </variablelist>
|
---|
[bdea25ce] | 319 |
|
---|
[a088964] | 320 | </sect2>
|
---|
[81fd230] | 321 |
|
---|
[bdea25ce] | 322 | </sect1>
|
---|