Gentoo Archives: gentoo-user

From: Jake Moe <jakesaddress@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Still Struggling With Wireless
Date: Wed, 18 Aug 2010 21:48:16
Message-Id: 4C6C5508.3070503@gmail.com
In Reply to: Re: [gentoo-user] Still Struggling With Wireless by CJoeB
1 On 18/08/10 12:56, CJoeB wrote:
2 > On 08/18/10 01:12, Jake Moe wrote:
3 >> On 18/08/10 09:04, CJoeB wrote:
4 >>> On 08/17/10 10:55, Jake Moe wrote:
5 >>>> On 08/17/10 11:55, Adam Carter wrote:
6 >>>>>> Hi,
7 >>>>>>
8 >>>>>> I'm biting the bullet here and asking for help. Yes! I've posted
9 >>>>>> before. And before anyone asks, I have read the responses to my
10 >>>>>> previous posts which helped little. I have read the documentation and
11 >>>>>> the wikis - ad nauseum. I'm still having problems with wireless.
12 >>>>>>
13 >>>>> I use wpa_supplicant to provide the wifi crypto.
14 >>>>>> So, I'm left with trying to use the iwl3945 driver in the kernel. I
15 >>>>>> followed the wiki for setting this up and thought I had succeeded. I
16 >>>>>> got to the point where I was told to type the following:
17 >>>>>> ifconfig wlan0 up (this does activate the wireless led on my computer)
18 >>>>>> iwlist wlan0 scan
19 >>>>>> iwconfig wlan0 essid "network name" (where the network name is the
20 >>>>>> essid that has been set)
21 >>>>>>
22 >>>>>> When I got this to work, I thought I was home free despite the "kludgy"
23 >>>>>> way of getting wireless working. However, I rebooted and now, when I
24 >>>>>> type iwlist wlan0 scan I get told that scanning is not supported. Yes,
25 >>>>>> I have iwl3945-ucode installed and yes, it was recompiled after the
26 >>>>>> kernel was rebuilt.
27 >>>>>>
28 >>>>>> I have no idea what I'm doing wrong.
29 >>>>> Forgetting to post up your configs :) eg /etc/conf.d/net etc
30 >>>> I've used the iwl3945 on a few HP laptops without much problem. The few
31 >>>> problems I had were related to switching the wireless on and off; I'd
32 >>>> have to rmmod and modprobe kernel modules to get it working again.
33 >>>>
34 >>>> Does "ifconfig" list the interface? If not, what does "ifconfig wlan0
35 >>>> up" do? What about the output of "iwconfig"? And going for the obvious
36 >>>> here, any chance that the wireless is turned off?
37 >>>>
38 >>>> Jake Moe
39 >>>>
40 >>>>
41 >>> iwconfig lists the interface as wlan0
42 >>>
43 >>> I discovered last night after sending my original message that my
44 >>> symlink was wrong - I used to have net.eth0 and net.eth1 pointing to
45 >>> net.lo. However, last night I removed the net.eth1 symlink and created
46 >>> the net.wlan0 symlink to net.lo. Now when I boot the computer, my
47 >>> wireless comes up and the LED comes on, but then it times out because (I
48 >>> assume) it can't establish a connection.
49 >>>
50 >>> This is my /etc/conf.d/net file. Note that the "any" used to work when
51 >>> I used the ipw3945 driver. I would scan for available networks. I
52 >>> tried last night to change the "any" to the essid printed on my Bell
53 >>> router, but that didn't work.
54 >>>
55 >>>
56 >>> # This blank configuration will automatically use DHCP for any net.*
57 >>> # scripts in /etc/init.d. To create a more complete configuration,
58 >>> # please review /etc/conf.d/net.example and save your configuration
59 >>> # in /etc/conf.d/net (this file :]!).
60 >>>
61 >>> #preup() {
62 >>> # if [[ ${IFACE} = "wlan0" ]]; then
63 >>> # sleep 3
64 >>> # fi
65 >>> # return 0
66 >>> #}
67 >>>
68 >>> modules=( "iwconfig" )
69 >>> iwconfig_wlan0="mode managed"
70 >>> config_eth0=("dhcp")
71 >>> config_wlan0=("dhcp")
72 >>> wpa_timeout_wlan0=15
73 >>> essid_wlan0="any"
74 >>>
75 >>> Regards,
76 >>>
77 >>> Colleen
78 >> This is the wireless part of mine:
79 >>
80 >> modules=( "iwconfig" )
81 >> config_wlan0=( "noop" "dhcp" )
82 >> dhcpcd_wlan0=( "-d -t 15" )
83 >> associate_order=( "forcepreferredonly" )
84 >> associate_timeout=( "5" )
85 >> preferred_aps=( "firstessid" "secondessid" )
86 >> key_firstessid=( "THIS-ISMY-KEY1-1234-5678-90AB-CD" )
87 >> key_secondessid=( "THIS-ISMY-KEY2-ABCD-EFGH-IJKL-MN" )
88 >>
89 >>
90 >> I've removed anything not having to do with the wireless for clarity.
91 >> >From memory, the only lines needed are "modules", "config_wlan0", and
92 >> "preferred_aps" (I have two because I also use wireless at my g/f's
93 >> mum's house). Oh, and I use "forcepreferredonly" so it'll try to
94 >> connect even though it can't find my essid by scanning (because I've
95 >> told my router to stop broadcasting the essid of my wireless network),
96 >> and it'll only try to connect to networks I specifically tell it to, no
97 >> others. If your essid is hidden as well, you'll probably need to add
98 >> either "forcepreferredonly" or "forceany" if you want it to auto-connect
99 >> to any it finds if it can't connect to yours.
100 >>
101 >> Reading through the wireless.example file, I came across this:
102 >>
103 >> ##############################################################################
104 >> # SETTINGS
105 >> ##############################################################################
106 >> # Hard code an ESSID to an interface - leave this unset if you wish
107 >> the driver
108 >> # to scan for available Access Points
109 >> # Set to "any" to connect to any ESSID - the driver picks an Access
110 >> Point
111 >> # This needs to be done when the driver doesn't support scanning
112 >> # This may work for drivers that don't support scanning but you need
113 >> automatic
114 >> # AP association
115 >> # I would only set this as a last resort really - use the preferred_aps
116 >> # setting at the bottom of this file
117 >>
118 >> Which is why I used perferred_aps instead of essid_wlan0. Give that a
119 >> try, perhaps?
120 >>
121 >> Jake Moe
122 >>
123 >>
124 > Haven't tried this yet - just got the e-mail and it's almost 11:00 p.m.
125 > and time for me to "hit the sack". However, I wanted to point this
126 > out. This test was copied from dmesg. Unless, I am misreading this, it
127 > looks like the driver is working. The problem is connecting to an
128 > access point. If my interpretation is wrong, let me know.
129 >
130 > iwl3945: Intel(R) PRO/Wireless 3945ABG/BG Network Connection driver for
131 > Linux, in
132 > -tree:s
133 > iwl3945: Copyright(c) 2003-2010 Intel Corporation
134 > iwl3945 0000:0c:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
135 > iwl3945 0000:0c:00.0: setting latency timer to 64
136 > iwl3945 0000:0c:00.0: Tunable channels: 11 802.11bg, 13 802.11a channels
137 > iwl3945 0000:0c:00.0: Detected Intel Wireless WiFi Link 3945ABG
138 > iwl3945 0000:0c:00.0: irq 29 for MSI/MSI-X
139 > phy0: Selected rate control algorithm 'iwl-3945-rs'
140 >
141 >
142 > Regards,
143 >
144 > Colleen
145 It's my understanding that if iwconfig and ifconfig find the device,
146 then the kernel is configured properly. (Feel free to jump in here if
147 I'm wrong, anyone) So then it becomes a question of why it doesn't work
148 for you, and that'll usually be config problems.
149
150 iwconfig lists my interfaces as such:
151
152 lo no wireless extensions.
153
154 eth0 no wireless extensions.
155
156 wlan0 IEEE 802.11abgn Mode:Managed Access Point: Not-Associated
157 Tx-Power=off
158 Retry long limit:7 RTS thr:off Fragment thr:off
159 Power Management:off
160
161 firewire0 no wireless extensions.
162
163 So it sees that my wlan0 interface is a IEEE 802.11abgn capable wireless
164 device. You said iwconfig listed yours as wlan0, but did it see it as a
165 wireless device? If so, you should be able to run "iwlist wlan0
166 scanning" and get a listing of ESSIDs that are in range. You probably
167 need to run it as root; if I run it as a regular user, it doesn't error,
168 but it doesn't find anything either.
169
170 Jake Moe