LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 12-17-2016, 02:39 PM   #16
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled

Quote:
Originally Posted by stoat View Post
The wpa service script expects your wpa_supplicant configuration file to have the .conf extension.
Another overlooked typo on my part. I do indeed have the .conf extension. Thank you.

Nothing is complaining in my system, which is what makes this a bit difficult. I don't get any obvious error messages. I just can't seem to find any WiFi connections when I scan, including my own router that I am connecting to.
 
Old 12-17-2016, 02:44 PM   #17
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by spiky0011 View Post
These are the options I have for the same device

CONFIG_WLAN_VENDOR_RALINK=y
# CONFIG_RT2800PCI is not set
CONFIG_RT2800USB=m
CONFIG_RT2800USB_RT33XX=y
CONFIG_RT2800USB_RT35XX=y
# CONFIG_RT2800USB_RT3573 is not set
CONFIG_RT2800USB_RT53XX=y
# CONFIG_RT2800USB_RT55XX is not set
# CONFIG_RT2800USB_UNKNOWN is not set
CONFIG_RT2800_LIB=m

CONFIG_RT2800USB_RT53XX=y
I did not build the kernel myself. I am using the official Raspberry Pi 4.4 kernel. How can I check those configurations/options you have listed?

Quote:
lsmod
rt2800usb 14583 0
rt2x00usb 8338 1 rt2800usb
rt2800lib 68511 1 rt2800usb
rt2x00lib 34430 3 rt2800lib,rt2800usb,rt2x00usb
mac80211 477253 4 rt2800lib,b43,rt2x00lib,rt2x00usb
cfg80211 417021 3 b43,rt2x00lib,mac80211


Hope these help.

<NO-CARRIER,BROADCAST,MULTICAST,UP> means it,s up but not associated to a carrier access point
lsmod shows that I have those modules running, except yours seem to have the additional "b43" dependent module, which I do not have. Is that important? What does that do?

Should I go through and build the kernel myself? Do you think that is the problem?
 
Old 12-17-2016, 02:52 PM   #18
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by spiky0011 View Post
as root
Code:
iwlist wlan0 scan
I suppose thats no output, struggerling here now
Code:
# iwlist wlan0 scan
wlan0     No scan results

#iwlist wifi0 scan
wifi0 Interface doesn't support scanning.
This is confusing. According to my wpa_supplicant files, I have named the interface "wifi0" (because the BLFS guide says to do so).

However, the interface is named wlan0 to everything else. Is this desired?

Still no scan results.
 
Old 12-17-2016, 03:54 PM   #19
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Here is some new information.

I have created a new wpa_supplicant config file for testing:

Code:
# cat /etc/sysconfig/wpa_supplicant_test.conf

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=root
update_config=1
Then, I brought up the interface with wpa_supplicant:

Code:
# wpa_supplicant -B -i interface -c /etc/sysconfig/wpa_supplicant_test.conf
Successfully initialized wpa_supplicant
[4097.871872] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
then I use wpa_cli

Code:
# wpa_cli
> scan
OK
<3>CTRL-EVENT-SCAN-STARTED
<3>CTRL-EVENT-SCAN-RESULTS
<3>CTRL-EVENT-NETWORK-NOT-FOUND

> scan_results
bssid / frequency / signal level / flags / ssid
So, no results by scanning with wpa_cli. I cannot see any networks (which I should). So something is bonkers. I keep thinking it must be the drivers/firmware, but it appears I have set that up correctly. Any ideas what I should try next?

Last edited by ScheissSchiesser; 12-17-2016 at 03:57 PM. Reason: fixed typo
 
Old 12-18-2016, 01:12 AM   #20
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
I would redo wpa .conf name it wlan0.conf, redo /etc/sysconfig/ifconfig.wifi0 make it ifconfig.wlan0, for consistancy.
 
Old 12-18-2016, 02:08 AM   #21
TheEzekielProject
Member
 
Registered: Dec 2016
Distribution: arch
Posts: 668

Rep: Reputation: 190Reputation: 190
Did you
Code:
dhclient -v wlan0
after you
Code:
ip link set wlan0 up
?
 
Old 12-20-2016, 01:57 AM   #22
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Did you set your region? If you don't do that the kernel will repeatedly disconnect so you aren't broadcasting on illegal frequencies.
 
Old 12-20-2016, 06:25 PM   #23
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Luridis View Post
Did you set your region? If you don't do that the kernel will repeatedly disconnect so you aren't broadcasting on illegal frequencies.
I will do that. But shouldn't there be some kind of error message stating that? Or a warning? Everything looks like it is working, except I can't see any WiFi ESSIDs when I scan. In fact, here's what I get when I scan with iwconfig:

Code:
# iwconfig wlan0 scan
iwconfig: unknown command "scan"

# iwlist wlan0 frequency
wlan0    14 channels in total; available frequencies :

Channel 01 : 2.412 GHz
...
...
[not typing all of the channels]
...
Channel 14 : 2.484 GHz

#iwlist wlan0 scanning
wlan0    No scan results
Can you be specific about what region I should be setting? Not sure how to do it. I am using iwconfig + wpa_supplicant and not iw.

Thanks for you help.
 
Old 12-20-2016, 06:27 PM   #24
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by The EzekielProject View Post
Did you
Code:
dhclient -v wlan0
after you
Code:
ip link set wlan0 up
?
I am using dhcpcd. Here is what I get when running it:

Code:
# dhcpcd wlan0
wlan0: waiting for carrier
timed out
dhcpcd exited
Makes sense, since I am not connected to an access point.
 
Old 12-21-2016, 02:08 AM   #25
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Quote:
Originally Posted by ScheissSchiesser View Post
Can you be specific about what region I should be setting? Not sure how to do it. I am using iwconfig + wpa_supplicant and not iw.

Thanks for you help.
Check your dmesg, you should see something like this:

Code:
cfg80211: Calling CRDA to update world regulatory domain
// If set correctly, it will continue like this:
cfg80211: Calling CRDA for country: US
cfg80211: Regulatory domain changed to country: US
cfg80211:  DFS Master region: FCC
If it's not set correctly, it will continuously disconnect because the legal transmission frequencies are different depending on what country you're in. If you haven't configured it, then it cannot assume transmitting on any given frequency is legal where you are.

Try "man crda" for more info. That, or the 80211 docs in the kernel source. You can set it via certificate, kernel command line, config file for iw (I think) or udev rule.

https://wireless.wiki.kernel.org/en/...latory_domains

Last edited by Luridis; 12-21-2016 at 02:13 AM.
 
Old 12-21-2016, 02:15 AM   #26
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Quote:
Originally Posted by ScheissSchiesser View Post
This is confusing. According to my wpa_supplicant files, I have named the interface "wifi0" (because the BLFS guide says to do so).

However, the interface is named wlan0 to everything else. Is this desired?

Still no scan results.
The easiest way to fix that... IMO, even easier than udev rules is to add this to your kernel command line:

net.ifnames=0
 
Old 12-21-2016, 06:11 PM   #27
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Nothing in dmesg shows up regarding crda or regulatory domains. I don't have the crda program either! Did I miss a step somewhere in the build process? When would crda be installed?
 
Old 12-21-2016, 06:34 PM   #28
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
crda is a udev helper, it's not built in. You have to download the package, the links can be found on the websites I posted before. It's just one way to set the regulatory domain. If your kernel isn't complaining that it's not set, then you're likely missing something.

Some settings aren't in the drivers tree, they're off the root kernel menu under "Networking Support"

Networking Support --->
-*- Wireless---> (auto-selected by wireless drivers)
<M/*> cfg80211 - wireless configuration API[*] cfg80211 wireless extensions capability
<M/*> RF switch subsystem support

(Sorry I can't get them to line up correctly. Whatever idiot coded this site's software decided to assume automatic formatting was desired inside code tags, which is just brilliant. Of course, I'm not a web developer so it might be the browser overriding a correctly coded tag. In which case, my apologies to the developer.)

Without everything, your adapter will probably just run in some sort of failsafe mode.

Last edited by Luridis; 12-21-2016 at 06:41 PM.
 
Old 12-22-2016, 10:51 AM   #29
ScheissSchiesser
LQ Newbie
 
Registered: Dec 2016
Posts: 15

Original Poster
Rep: Reputation: Disabled
Quote:
Code:
Networking Support --->
-*- Wireless---> (auto-selected by wireless drivers)
   <M/*> cfg80211 - wireless configuration API[*] cfg80211 wireless extensions capability
<M/*> RF switch subsystem support
I have all of those selected, but when I check dmesg for cfg80211, I don't see any messages from it.

Code:
# dmesg | grep regulatory
# dmesg | grep cfg
# dmesg | grep 80211
[   11.813392] ieee80211 phy0: rt2x00_set_rt: Info - RT chipset 5390, rev 0502 detected
[   11.880757] ieee80211 phy0: rt2x00_set_rf: Info - RF chipset 5370 detected
[   12.001265] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[   17.616839] ieee80211 phy0: rt2x00lib_request_firmware: Info - Loading firmware file 'rt2870.bin'
[   17.636647] ieee80211 phy0: rt2x00lib_request_firmware: Info - Firmware detected - version: 0.22
cfg80211 is running

Code:
# pgrep cfg80211
371
 
Old 12-22-2016, 06:34 PM   #30
TheEzekielProject
Member
 
Registered: Dec 2016
Distribution: arch
Posts: 668

Rep: Reputation: 190Reputation: 190
....

Are you literally typing
Quote:
# wpa_supplicant -B -i interface -c /etc/sysconfig/wpa_supplicant_test.conf
Successfully initialized wpa_supplicant
[4097.871872] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Or are you replacing interface with wlan0?

Also did you change the instances of wifi0 to wlan0 as suggested by spiky0011?



Quote:
Originally Posted by ScheissSchiesser View Post
I am using dhcpcd. Here is what I get when running it:

Code:
# dhcpcd wlan0
wlan0: waiting for carrier
timed out
dhcpcd exited
Makes sense, since I am not connected to an access point.


Yes, you are not connected to the access point and that is what dhcpcd is intended to do. It timing out waiting for the carrier seems to me that it's not being offered an ip address.

Try running
Code:
dhcpcd -d wlan0
:q

For a little more info on why it's timing out.


Also check here for other troubleshooting tips
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Can connect to cellphone through WIFI HOTSPOT, but cannot connect to my own WIFI network diegoandresalvarez Linux - Networking 7 10-22-2016 11:54 AM
[SOLVED] Wifi network on wifi - raspberry pi business_kid Debian 1 06-01-2014 01:11 PM
Wifi (pci) disconnect when computer idle. Fedora 14, wifi RaLink RT2561/RT61 tessx Linux - Hardware 1 05-27-2012 11:15 AM
Unable to connect to wifi network with network manager. Poss authorization issue openSauce Linux - Networking 14 12-13-2008 10:05 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 01:06 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration