Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

After a long struggle I finally seem to have installed the non-free wireless firmware for my wireless NIC. I'm trying to set up a file server, so I want to configure the network to be static. Would one of you guys mind helping me?

For example I don't know what my /etc/network/interfaces file should look like, currently it looks like this:

auto lo
iface lo inet loopback

allow-hotplug wlan1
iface wlan1 inet static
    # wireless-* options are implemented by the wireless-tools package
    wireless-mode managed
    wireless-essid Optimus Pwn
    wpa-psk s:roonwolf # I changed this from wiresless-key1 or something like that
    dns-* options are implemented by the resolvconf package, if installed
    dns-search localdomain

My ifconfig command looks like this:

lo Link encap: Local Loopback
inet addr: Mask:
inet6 addr: ::1/128 Scope: Host
RX packets: 95 errors: 0 dropped: 0 overruns: 0 frame: 0
TX packets: 95 errors: 0 dropped: 0 overruns: 0 carrier: 0
collisions: 0 txqueuelen: 0
RX bytes: 10376 (10.1KiB) TX bytes: 10376 (10.1 KiB)

wlan1 Link encap: Ethernet HWaddr 00:18:f3:85:99:07
inet addr: Bcast: Mask:
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)

Here's what I get when I iwlist my ssid:

wlan1     Scan completed :
      Cell 01 - Address: 00:14:D1:A4:0A:36
                Frequency:2.437 GHz (Channel 6)
                Quality=70/70  Signal level=-17 dBm  
                Encryption key:on
                ESSID:"Optimus Pwn"
                Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 6 Mb/s
                          9 Mb/s; 12 Mb/s; 18 Mb/s
                Bit Rates:24 Mb/s; 36 Mb/s; 48 Mb/s; 54 Mb/s
                Extra: Last beacon: 100ms ago
                IE: Unknown: 000B4F7074696D75732050776E
                IE: Unknown: 010882848B960C121824
                IE: Unknown: 030106
                IE: Unknown: 0706555320010B1B
                IE: Unknown: 200100
                IE: WPA Version 1
                    Group Cipher : TKIP
                    Pairwise Ciphers (1) : TKIP
                    Authentication Suites (1) : PSK
                IE: Unknown: 2A0100
                IE: Unknown: 32043048606C
                IE: Unknown: DD180050F2020101070003A4000027A4000042435E0062322F00
                IE: Unknown: DD1E00904C334C101BFFFF000000000000000000000000000000000000000000
                IE: Unknown: 2D1A4C101BFFFF000000000000000000000000000000000000000000
                IE: Unknown: DD1A00904C3406001900000000000000000000000000000000000000
                IE: Unknown: 3D1606001900000000000000000000000000000000000000
                IE: Unknown: DD0900037F01010000FF7F

When I ping primary desktop) I get

PING ( 56(84) bytes of data.
From icmp_seq=2 Destination Host Unreachable

When I ping google.com I get(after a lengthy pause):

ping: unknown host google.com

What exactly am I doing wrong here? Should I restart the network?

share|improve this question
Have you run ifup wlan1? Did you get any errors when doing so? – derobert Oct 26 '12 at 17:50
Yep, every time I edit the /etc/network/interfaces file I do, ifdown wlan1 and ifup wlan1. I don't really know what values I should put for the file. I'll put the values of ifconfig up in the main post. – Scriptonaut Oct 26 '12 at 18:02
Have you tried iwlist scan to see if you wifi is working at all? Also, I think wpa-psk expects a hex string (man wpa_passphrase) – charlesbridge Oct 26 '12 at 18:38
My network shows up when I scan, I'll add it to my main post. – Scriptonaut Oct 26 '12 at 19:38
You got your solution, but a tip for future circumstances: to get a more precise diagnosis, run traceroute -n Traceroute lets you know up to what point you can connect, -n stops the tool from making DNS requests (so you can test IP connectivity alone), and is a memorable IP address that you can count on (Google runs a DNS server on it). – Gilles Oct 26 '12 at 22:52
up vote 3 down vote accepted

Have you tried Network Manager? It's easy to set up static IPs for wireless networks using the GUI. Once you get things working there, if you want the connection available all the time even when you're not logged in (e.g. for a file server), just select the "Connect Automatically" and "Available to all users" checkboxes.

If you're allergic to GUIs, you can configure the connection by creating a file in the /etc/NetworkManager/system-connections/ directory, as described on this page.

share|improve this answer
I'm fine with GUIs, but I don't have one on this machine(and don't want one). I couldn't figure out how to use Network Manager, so I just installed wicd-curses, but am having trouble figuring it out as well. All unix instructions are so terse I can rarely figure them out. – Scriptonaut Oct 26 '12 at 21:10
Well, if you want easy, install the GUI. You can remove it later. Otherwise, making the config file by hand is your only option. The second link I gave gives an example of how to do that, and links to other documentation. A google search for [network manager system connection] is also informative. – Jim Paris Oct 26 '12 at 21:39
I figured out wicd-curses, and after 3 days of hell I was able to connect. Thanks for the suggestions, I'm finally done. – Scriptonaut Oct 26 '12 at 21:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.