# Generic commandline way to configure network.

## dE_logics

Gentoo has it's own networking method, Debian and Fedora have their own.

Network manager is supposed to be a generic method to configure the network in all OSs but it has only a GUI interface (in the form of applets) and apparently I find cnetworkmanager very immature (how do I make use of it?... how do I dialup an ADSL connection using it?).

WPA supplication is an option but only for wireless, + it has limited capabilities.

So finally is there a good generic commandline method of managing an Ethernet network?

----------

## Voltago

ifconfig and route?

----------

## cwr

ifconfig, iwconfig, route and arp (and a certain amount of shell scripting) generally do most

of the things I need.

Will

----------

## Hu

For advanced work, you can use /sbin/ip from sys-apps/iproute2.

As far as I know, all the major Linux distributions ship ifconfig and route (as suggested by Voltago) and make available the commands from sys-apps/iproute2, though they might not be installed by default.

----------

## dE_logics

iwconfig is from wireless-tools, if that is in the list, wpa_supplicant should also be there.

But what about ppp? which tools allows you to dial? rp-pppoe? Is that the only one tool?

ip command apparently is not in iproute2

```
* Contents of sys-apps/iproute2-2.6.31:

/sbin

/sbin/tc
```

----------

## py-ro

It should.

```
[ Searching for file(s) /sbin/ip in *... ]

sys-apps/iproute2-2.6.31 (/sbin/ip)
```

Py

----------

## dE_logics

hummm... interesting situation. Maybe portage 2.2 alpha has a bug?

----------

## dE_logics

Apparently ifconfig is giving major issues - 

```
/etc/init.d/net.eth0 stop

net.eth0        | * Bringing down interface eth0

net.eth0        | *   Stopping dhcpcd on eth0 ...                                               [ ok ]

net.eth0        | *   Removing addresses

OLD_BROKEN_LAP de # ifconfig eth0 up

OLD_BROKEN_LAP de # ifconfig   

eth0      Link encap:Ethernet  HWaddr 00:1c:23:a1:9d:09  

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

          Interrupt:18 

OLD_BROKEN_LAP de # ifconfig eth0 address 192.168.1.2

address: Host name lookup failure

ifconfig: `--help' gives usage information.

OLD_BROKEN_LAP de # ifconfig eth0 netmask 255.255.255.0

SIOCSIFNETMASK: Cannot assign requested address
```

----------

