1 |
iproute2 is newer and while it takes over all of the abilities of ifconfig, |
2 |
it is modularized and designed for controlling advanced router features as |
3 |
well as basic interface related stuff. |
4 |
|
5 |
The capabilities of it are vastly superior to ifconfig, and sometimes the |
6 |
notation is simpler. |
7 |
|
8 |
Setup eth0, and activate it: |
9 |
|
10 |
ifconfig eth0 192.168.1.1 <http://192.168.1.1> netmask |
11 |
255.255.255.0<http://255.255.255.0>broadcast |
12 |
192.168.1.255 <http://192.168.1.255> up |
13 |
route add -net 0/0 gw 192.168.1.254 <http://192.168.1.254> |
14 |
|
15 |
ip addr add 192.168.1.1/24 <http://192.168.1.1/24> brd |
16 |
192.168.1.255<http://192.168.1.255> |
17 |
ip link set eth0 up |
18 |
ip route add default via 192.168.1.254 <http://192.168.1.254> |
19 |
|
20 |
---- |
21 |
|
22 |
There is a type of NAT [aka FastNAT] that you can use with iproute2 - |
23 |
involving no iptables/netfilter support. You can setup multiple defoult |
24 |
routes, rudimentary load balancing, and other stuff. |
25 |
|
26 |
|
27 |
For a better concept of the abilities of iproute2 - please see |
28 |
http://lartc.org |
29 |
The Linux Advanced Routing and Traffic Control site. |
30 |
|
31 |
thanks, |
32 |
joshua |
33 |
|
34 |
|
35 |
|
36 |
On 10/12/05, Martins Steinbergs <mar@××.lv> wrote: |
37 |
> |
38 |
> hi |
39 |
> |
40 |
> what is the difference in general between these - ifconfig and iproute2? |
41 |
> |
42 |
> i used old style /etc/conf.d/net and it worked well until system last |
43 |
> update i |
44 |
> run - net was gone. made new style /etc/conf.d/net but ifconfig version |
45 |
> refused to work, lucky i got windoze on other drive to get iproute2 source |
46 |
> from mirror. ok, now net is working but im still confused about ifconfig |
47 |
> not |
48 |
> working, got these setings for single box connected to i-net, is there |
49 |
> somethin' wrong? |
50 |
> |
51 |
> hotplug_eth0="yes" |
52 |
> |
53 |
> modules=( "iproute2" ) |
54 |
> here i tried both modules |
55 |
> |
56 |
> config_eth0=( "some_IP netmask some_IP broadcast some_IP" ) |
57 |
> routes_eth0=( |
58 |
> "default via some_IP" |
59 |
> "::/0" |
60 |
> ) |
61 |
> |
62 |
> |
63 |
> |
64 |
> martins |
65 |
> -- |
66 |
> gentoo-user@g.o mailing list |
67 |
> |
68 |
> |