-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 05/30/09 01:28, ghe wrote: > Donald Raikes wrote: >> Hello, > >> I installed lenny yesterday on my desktop system. I would like to change >> it so it has a static ip address rather than a dhcp assigned one. > >> How do I go about setting the ip address? >> If there is a console-based method I would prefer that since icannot >> edit the network configuration through the networking tools applet (I >> don't have permissions). > > Hey! One I can answer! > > > vi /etc/network/interfaces > > Here's a known working interfaces file from my LAN: > > # This file describes the network interfaces available on your system > # and how to activate them. For more information, see interfaces(5). > > # The loopback network interface > auto lo > iface lo inet loopback > > # The primary network interface > allow-hotplug eth0 > auto eth0 > iface eth0 inet static > address 192.168.3.3 > netmask 255.255.255.0 > network 192.168.3.0 > broadcast 192.168.3.255 > gateway 192.168.3.1 > # dns-* options are implemented by the resolvconf package, if installed > dns-nameservers 192.168.2.30 > dns-search slsware.lan > > Then reboot. It's possible to get eth0 to reconfig without a reboot, but > I don't remember how... > It's '/etc/init.d/networking restart' as root, or 'sudo /etc/init.d/networking restart' as a user with sudo permissions.
Also, if you're using a wireless card, here's my wireless /etc/network/interfaces: hricka...@siddy:~$ cat /etc/network/interfaces # Used by ifup(8) and ifdown(8). See the interfaces(5) manpage or # /usr/share/doc/ifupdown/examples for more information. auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.0.2 netmask 255.255.255.0 gateway 192.168.0.1 auto wlan0 iface wlan0 inet static wireless-essid ************* address 192.168.2.1 netmask 255.255.255.0 gateway 192.168.2.150 I don't have a wireless key as I can never get the rt73usb module to work with either WEP or WPA. I'm working on it though, so don't rant on at me about how insecure it is. - -- Many thanks Harry Rickards (GPG Key ID:646ED06A) - -----BEGIN GEEK CODE BLOCK----- Version: 3.1 GAT/GCM/GCS/GCC/GIT/GM d? s: a? C++++ UL++++ P- L+++ E--- W+++ N o K+ w--- O- M- V- PS+ PE Y+ PGP++ t 5 X R tv-- b+++ DI D---- G e* h! !r y? - ------END GEEK CODE BLOCK------ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkohAWcACgkQ1kZz3mRu0GrV7ACgqReVF8Jqyj/Q+o0PNAQXi2+i gsoAn19UIPtevdEwsv5nUoWnDYYEt+QP =45u4 -----END PGP SIGNATURE----- -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org