Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 97395 - iwconfig cannot find my access point
Summary: iwconfig cannot find my access point
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Roy Marples (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-06-29 08:28 UTC by Lawrence MacIntyre
Modified: 2005-07-19 23:25 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lawrence MacIntyre 2005-06-29 08:28:00 UTC
key_ESSID=s:asdfasdfasdfasdf

If ESSID contains a hyphen (e.g. network-1), the startup errors out.
Comment 1 Roy Marples (RETIRED) gentoo-dev 2005-06-29 09:44:46 UTC
key_ESSID='s:asdfasdfasdfasdf'

Notice the single quotes

Re-open if you disagree
Comment 2 Lawrence MacIntyre 2005-06-29 11:22:28 UTC
The hyphen is is the ESSID portion, not the data portion.  I've tried single
quotes, double quotes, and even escaped the hyphen using the \ character.

'key_ornl-1' = s:asdfasdf
"key_ornl-1" = s:asdfasdf
key_ornl\-1 = s:asdfasdf
Comment 3 Roy Marples (RETIRED) gentoo-dev 2005-06-29 15:11:21 UTC
Sorry, I mis-understood

key_ornl_1='s:asdfasdf'

This is documented here
http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=4&chap=2#doc_chap3
Comment 4 Lawrence MacIntyre 2005-06-30 07:26:15 UTC
The ESSID where I work has a hyphen in the middle, like network-1.  It's not an
underscore, like network_1.  The documentation states that some characters must
be escaped with the \ character, and I had tried that, as documented in Comment
#2.  I have also tried combinations  like "key_network\-1"="s:asdfasdfasdf".  I
can't find anything that works.
Comment 5 Roy Marples (RETIRED) gentoo-dev 2005-06-30 08:24:20 UTC
Re read the docs - but no, allow me to summarize

REPLACE ANY CHARACTER NOT IN A-Z a-z 0-9 WITH A _ FOR VARIABLE NAMES

The hyphen is used there to save me from typing ABCDEF.... etc hyphens should be
changed to underscores too.

key_network_1="s:asdfasdfasdf"
Comment 6 Lawrence MacIntyre 2005-06-30 10:38:17 UTC
We have two wireless nets that coexist.  One is internal, named network-1, and
uses WEP.  The other is open to visitors, named network-visitor, and doesn't use
WEP.  I have tried the following:

First, manual commands:

iwconfig eth1 essid "network-1" nickname "network-1" key "s:asdfasdfasdf"
ifconfig eth1 up
/sbin/dhcpcd -h karabou -t 10 -N eth1

This works fine.  Now try automatic startup.  I have network-1 in preferred_aps,
like:

preferred_aps=("networkwpa" "network-1" "network-2")

and the key for network-1 is defined like:
key_network_1="s:asdfasdfasdf"

* Starting eth1
*   Configuring wireless network for eth1
*     eth1 connected to "network-visitor" at 23:1B:34:9A:53:11
*     in managed mode (WEP disabled)
*   Bringing up eth1
*     dhcp
*       Running dhcpcd ...                                               [ ok ]
*       eth1 received address 10.1.94.63

Now try automatic startup with blacklist of network-visitor, like:

blacklist_aps=("network-visitor")

*   Configuring wireless network for eth1
*   Couldn't associate with any access points on eth1
*   Failed to configure wireless for eth1                              [ !! ]

So it appears that the use of key_network_1="s:asdfasdfasdf" doesn't work.  Is
there something else I may have done wrong?  There are no lines uncommented in
/etc/conf.d/wireless except for the three mentioned above.

There are these lines in /etc/conf.d/net:

iface_eth1="dhcp"
dhcpcd_eth1="-t 10 -N"
modules=("iwconfig")

Are there things I can do to attempt to debug the problem?  I enabled NET_DEBUG,
but that didn't do anything interesting:

NET_DEBUG=1;/etc/init.d/net.eth1 start

Comment 7 Roy Marples (RETIRED) gentoo-dev 2005-06-30 12:42:31 UTC
(In reply to comment #6)
> So it appears that the use of key_network_1="s:asdfasdfasdf" doesn't work.

No, what's really happening is that your card cannot find network-1 for whatever
reason. Is it broadcasting it's ESSID? Are you out of range?

Your card appears to support scanning, so post the output of the following

iwconfig eth1 essid any
iwlist eth1 scan

Other things to try are adding RC_VERBOSE="yes" to /etc/conf.d/net for a more
detailed output of whats going on and if all else fails add
associate_order="forcepreferred" to /etc/conf.d/net or /etc/conf.d/wireless to
try and force a connect to those AP's listed in order

BTW, if the wpanetwork really is wpa only, remove it from your preferred list as
iwconfig cannot do wpa.
Comment 8 Roy Marples (RETIRED) gentoo-dev 2005-07-19 23:25:59 UTC
Need more information