Questions for a Wi-Fi/hostapd expert - partly answered!

Help on building IPFire & Feature Requests
Post Reply
dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Questions for a Wi-Fi/hostapd expert - partly answered!

Post by dnl » August 3rd, 2015, 10:45 am

Hello,

I've been using the hostapd addon with IPFire for some time.

Despite upgrading the antennas with my card, which features MIMO 3 x 3, the signal strength in some areas was still not as much as I'd hoped. I also noticed that connection speeds were not above 54 Mbps, despite the card being theoretically capable for 450Mbps*.
(*If I used a 40 MHz channel, I'm only using a 20 MHz channel though)

I've chosen a channel which does not conflict with any other WiFi networks by monitoring other networks at the limit of my own network (there are few networks near my channel and they are distant). I use two wide-beam directional antennas pointed in the direction of most use along with a medium-gain omni-directional antenna - I'm currently using channel 11 in the 2.4 GHz range. I'm in the process of making a WiFi heatmap, but I would guess that most devices can receive signal from at least two antennas.

I have had this set up for a while now, but hadn't configured the "HT Caps" field because I really had no idea what it meant. So recently I did a little research and learned that it means "High Throughput Capabilities", although it seems can also be called "Modulation and Coding Schemes" (MCS). After a little more research, I found the MCS values for my card. I changed them and my WiFi signal was noticably better!

At the time I failed to realise that signal strength had improved was that because the Country Code field had been set back to "00" after I added new HT Caps and saved my config. (This may be a bug?)


Anyway, all the above is getting to these questions...
TL;DR:
1. Must the "HT Capabilities" be configured in the Web UI for hostapd to use them?
2. Does the order matter?
3. Where can a full list of "HT Capabilities" be found?
* From what i can see the full list of MCS Values is here but I see older IPFire documentation has "HT Caps" which aren't included in the MCS Values list?!
4. Is the information on HT Caps in the wiki still correct? (I wrote a lot of it and now realise how little I understand!!)
5. What are the HT capabilities I should configure for a "Compex" "WLE350NX" (AR9580)? PDF Data sheet here

The "iw" command on my system seems to list a whole lot of features, like:
HT Capability overrides:
* MCS: ff ff ff ff ff ff ff ff ff ff
* maximum A-MSDU length
* supported channel width
* short GI for 40 MHz
* max A-MPDU length exponent
* min MPDU start spacing
although I note that the same command also says "Do NOT screenscrape this tool, we don't consider its output stable."!
From the datasheet I'm guessing these should work: [HT-20][OFDM][BPSK][QPSK][16-QAM][64-QAM][DSSS][DBPSK][DQPSK][CCK][DSSS_CCK-40][SHORT-GI-40] (not sure about [HT-40-] or [HT-40+] - I gather you can only have one or the other)
It seems you can put almost any text in the "HT Caps" field without preventing hostapd from loading!



Thanks very much in advance!
A confused "HT Caps" user.
Last edited by dnl on August 7th, 2015, 12:13 pm, edited 1 time in total.
Image

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Think I found the information I needed!

Post by dnl » August 3rd, 2015, 11:03 am

UPDATE
https://wireless.wiki.kernel.org/en/use ... nwpa2_pre-
authentication
AND
http://www.linuxwireless.org/en/users/D ... nvironment
both say something like this:
802.11n Setting Summary

802.11n builds on the settings above, and adds additional functionality. If your hardware doesn't support 802.11n, or you don't plan on using it, you can ignore these.
  • ieee80211n: Set to 1 to enable 802.11n support, 0 to disable it
  • ht_capab: A list of the 802.11n features supported by your device The explanation of these settings in the sample config file are quite helpful, so I'll suggest reading those. You can use the command 'iw list' to find a short list of the capabilities of your device.


In the source (http://w1.fi/releases/hostapd-2.4.tar.gz) the example hostapd.conf includes:

Code: Select all

# ht_capab: HT capabilities (list of flags)
# LDPC coding capability: [LDPC] = supported
# Supported channel width set: [HT40-] = both 20 MHz and 40 MHz with secondary
#   channel below the primary channel; [HT40+] = both 20 MHz and 40 MHz
#   with secondary channel above the primary channel
#   (20 MHz only if neither is set)
#   Note: There are limits on which channels can be used with HT40- and
#   HT40+. Following table shows the channels that may be available for
#   HT40- and HT40+ use per IEEE 802.11n Annex J:
#   freq      HT40-      HT40+
#   2.4 GHz      5-13      1-7 (1-9 in Europe/Japan)
#   5 GHz      40,48,56,64   36,44,52,60
#   (depending on the location, not all of these channels may be available
#   for use)
#   Please note that 40 MHz channels may switch their primary and secondary
#   channels if needed or creation of 40 MHz channel maybe rejected based
#   on overlapping BSSes. These changes are done automatically when hostapd
#   is setting up the 40 MHz channel.
# Spatial Multiplexing (SM) Power Save: [SMPS-STATIC] or [SMPS-DYNAMIC]
#   (SMPS disabled if neither is set)
# HT-greenfield: [GF] (disabled if not set)
# Short GI for 20 MHz: [SHORT-GI-20] (disabled if not set)
# Short GI for 40 MHz: [SHORT-GI-40] (disabled if not set)
# Tx STBC: [TX-STBC] (disabled if not set)
# Rx STBC: [RX-STBC1] (one spatial stream), [RX-STBC12] (one or two spatial
#   streams), or [RX-STBC123] (one, two, or three spatial streams); Rx STBC
#   disabled if none of these set
# HT-delayed Block Ack: [DELAYED-BA] (disabled if not set)
# Maximum A-MSDU length: [MAX-AMSDU-7935] for 7935 octets (3839 octets if not
#   set)
# DSSS/CCK Mode in 40 MHz: [DSSS_CCK-40] = allowed (not allowed if not set)
# 40 MHz intolerant [40-INTOLERANT] (not advertised if not set)
# L-SIG TXOP protection support: [LSIG-TXOP-PROT] (disabled if not set)
#ht_capab=[HT40-][SHORT-GI-20][SHORT-GI-40]


So based on my 2.4 GHz channel, I've now changed to [HT40-]. My devices seem to be connecting on 65.0 MBit/s Transmit (MCS 7) or higher depending on their capabilities.

(EDIT: With the settings below, I'm now seeing 72.2 MBit/s Tx AND Rx using "MCS 7 short GI" for my smartphones. A laptop will connect higher, but I've not tested it yet)

I've also added:
[TX-STBC][RX-STBC1][SHORT-GI-20][SHORT-GI-40][DSSS_CCK-40][U-APSD]
as my card reports these capabilities (with "iw list") and the example config file seems to indicate they are explicitly disabled if this configuration is not added.

I'm still not sure about:
[HT-20][OFDM][BPSK][QPSK][16-QAM][64-QAM][DSSS][DBPSK][DQPSK][CCK][LDPC]
but I've added them as the card seems to support them all and they don't appear to be contradictory (work against each other).

The following options are also supported by my card, although they seem to be specific to 802.11ac, which it seems IPFire doesn't support?
[MAX-A-MPDU-LEN-EXP3][RXLDPC][RX-STBC-1]




I didn't change MAX-AMSDU as my card only reports the default 3839 value anyway.
Last edited by dnl on August 7th, 2015, 1:17 pm, edited 1 time in total.
Image

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Re: Questions for a Wi-Fi/hostapd expert - partly answered!

Post by dnl » August 7th, 2015, 12:53 pm

I should put this in the wiki! (I will when I have a chance)

1. Obtain a copy of the hostapd.conf example file (for now refer to the full copy in my previous post)
2. Open an SSH session to your IPFire server, which is using a WiFi card with hostapd
3. run "iw list > /tmp/mywifi.txt"
4. For each option in the "# ht_capab: HT capabilities (list of flags)" section of the hostapd.conf example file, search for that option in the /tmp/mywifi.txt file you created earlier. Eg. "grep -i STBC /tmp/mywifi"
5. For each capability you find, note the "flags" associated and put them in to square brackets, like this: [FLAG_GOES_HERE]. Save this to the "Ht Caps" section of the IPFire "WLAN AP" page.
6. Using the "WLan Status" section lower down in that same web page, note the "tx bitrate:" and "rx bitrate:" fields. They should now be higher and show "MCS" options.

A full list of flags (or HT Capability options) for 802.11n only from the current hostapd.conf example file follows:
  • [LDPC] or not supported.
  • [HT40-] OR [HT40+] for 40 MHz channels, or not enabled.
  • [SMPS-STATIC] or [SMPS-DYNAMIC] or not enabled.
  • [GF] or not enabled.
  • [SHORT-GI-20] for 20 MHz channels, or not enabled. (This and the following flag seem to lower the "Guard Intervals" or tolerances allowing for higher bandwidth. An expert can elaborate more!)
  • [SHORT-GI-40] for 40 MHhz channels, or not enabled.
  • [TX-STBC] or not enabled.
  • [RX-STBC1] or [RX-STBC12] or [RX-STBC123] or not enabled. Each option gets better the more streams are added 123, is better than 12, which is better than just "1"
  • Rx STBC or not enabled.
  • [DELAYED-BA] or not enabled.
  • [MAX-AMSDU-7935] or, if not set, the default of 3839 octets in each MDSU
  • [DSSS_CCK-40] for 40 MHhz channels, or not enabled.
  • [40-INTOLERANT] or not advertised if not set.
  • [LSIG-TXOP-PROT] or disabled if not set.

User avatar
H&M
Posts: 402
Joined: May 29th, 2014, 9:38 pm
Location: Europe

Re: Think I found the information I needed!

Post by H&M » August 19th, 2015, 4:31 pm

dnl wrote:UPDATE


So based on my 2.4 GHz channel, I've now changed to [HT40-]. My devices seem to be connecting on 65.0 MBit/s Transmit (MCS 7) or higher depending on their capabilities.

(EDIT: With the settings below, I'm now seeing 72.2 MBit/s Tx AND Rx using "MCS 7 short GI" for my smartphones. A laptop will connect higher, but I've not tested it yet)



Hi dnl,

About [HT40 +/-]: from my experience, usage of 40Mhz channels is regulated and these regulations are country dependent.
More exactly: I am living Europe and I've declared the country to the hostapd setup page. For more than a year I've run the card with [HT40-] [DSSS_CCK-40] but after one hostapd upgrade I've got errors at boot (dmesg) telling me that [HT40-] is not supported to my country.

Strange thing: until core 87 (that included one hostapd update!) I was running my card in gn mode, Channel 13 and [HT40-] [DSSS_CCK-40] but after the hostapd upgrade my card started to stop working and after some time I've discovered the dmesg messages telling me that HT40 is not supported for my country.

In the old days (with HT40-) one of my laptops was negotiating 104Mb speed (Intel 1000 an card).
Now, after erasing HT40- from the hostapd config, I get only 75Mb negotiated speed.


The card I am using is Compex WLE200NX, card distributed by PCEngine. It uses ATH9K driver. Country = PL. Running in gn mode.
These days I am searching for a country code that will allow me to run the Hostapd on channel 13 and [HT40-] [DSSS_CCK-40].

If you found the regulations for some countries, and you saw that HT40 is allowed for 2,4Ghz in one country, do tell me: I need my speed back.

Code: Select all

Mar  9 17:22:11 dmx kernel: cfg80211: Calling CRDA for country: PL
Mar  9 17:22:11 dmx kernel: cfg80211: Regulatory domain changed to country: PL
Mar  9 17:22:11 dmx kernel: cfg80211:  DFS Master region: ETSI
Mar  9 17:22:11 dmx kernel: cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Mar  9 17:22:11 dmx kernel: cfg80211:   (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Mar  9 17:22:11 dmx kernel: cfg80211:   (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Mar  9 17:22:11 dmx kernel: cfg80211:   (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Mar  9 17:22:11 dmx kernel: cfg80211:   (5490000 KHz - 5710000 KHz @ 160000 KHz), (N/A, 2700 mBm), (0 s)
Mar  9 17:22:11 dmx kernel: cfg80211:   (57000000 KHz - 66000000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)
Mar  9 17:22:11 dmx kernel: IPv6: ADDRCONF(NETDEV_UP): blue0: link is not ready
Mar  9 17:22:12 dmx kernel: IPv6: ADDRCONF(NETDEV_CHANGE): blue0: link becomes ready


Best,
H&M

PS: Hostapd was updated with core 87. After this update I've encountered problems with HT40-
See this post: viewtopic.php?f=52&t=12733&p=81839&hilit=country%3DDE#p81839

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Re: Think I found the information I needed!

Post by dnl » August 20th, 2015, 11:29 am

H&M wrote:About [HT40 +/-]: from my experience, usage of 40Mhz channels is regulated and these regulations are country dependent.

Good point, I hadn't thought of that as I only looked at my own country.

H&M wrote:Strange thing: until core 87 (that included one hostapd update!) I was running my card in gn mode, Channel 13 and [HT40-] [DSSS_CCK-40] but after the hostapd upgrade my card started to stop working and after some time I've discovered the dmesg messages telling me that HT40 is not supported for my country.

That's annoying!

H&M wrote:These days I am searching for a country code that will allow me to run the Hostapd on channel 13 and [HT40-] [DSSS_CCK-40].

Try 'au'. ;)

Also, https://en.wikipedia.org/wiki/List_of_WLAN_channels is worth browsing, especially as it has links to regulation for various countries. Japan seems to be the most unrestricted as they allow 2.4 GHz channels 13 (and 14 using 802.11b only) but I'm not sure about their regulations when it comes to wide channels like [HT40-].

H&M wrote:PS: Hostapd was updated with core 87. After this update I've encountered problems with HT40-
See this post: viewtopic.php?f=52&t=12733&p=81839&hilit=country%3DDE#p81839

I only have limited time at the moment, but I will have a look later.
Image

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Re: Questions for a Wi-Fi/hostapd expert - partly answered!

Post by dnl » August 20th, 2015, 11:37 am

https://en.wikipedia.org/wiki/IEEE_802. ... 4.C2.A0GHz is worth a quick scan also.

Depending on how large the space is which your network needs to cover, using a 5 GHz channel might allow you higher bandwidth too.

I've only tested 5 GHz for my network once and it appeared to have much lower penetration through walls. I've been meaning to do it again after doing a heatmap of my network using "HeatMapper" on a Windows laptop.

User avatar
H&M
Posts: 402
Joined: May 29th, 2014, 9:38 pm
Location: Europe

Re: Think I found the information I needed!

Post by H&M » August 20th, 2015, 12:05 pm

dnl wrote:
H&M wrote:These days I am searching for a country code that will allow me to run the Hostapd on channel 13 and [HT40-] [DSSS_CCK-40].

Try 'au'. ;)

Also, https://en.wikipedia.org/wiki/List_of_WLAN_channels is worth browsing, especially as it has links to regulation for various countries. Japan seems to be the most unrestricted as they allow 2.4 GHz channels 13 (and 14 using 802.11b only) but I'm not sure about their regulations when it comes to wide channels like [HT40-].



Hi dnl,

THANK YOU for the knowledge base! For sure I will try "AU" :).

Late edit:

I'VE tried AU and it seems it works with channel=13 and [HT40-]!!!
With country = POLAND, the regulatory DFS Master was ETSI, but with country=AU, there is no regulatory DFS Master!! :D

Aug 20 16:46:41 dmx kernel: cfg80211: Calling CRDA for country: DE
Aug 20 16:46:41 dmx kernel: cfg80211: Regulatory domain changed to country: DE
Aug 20 16:46:41 dmx kernel: cfg80211: DFS Master region: ETSI

Aug 20 16:46:41 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 16:46:41 dmx kernel: cfg80211: (2400000 KHz - 2483500 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5150000 KHz - 5250000 KHz @ 80000 KHz, 200000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5250000 KHz - 5350000 KHz @ 80000 KHz, 200000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5470000 KHz - 5725000 KHz @ 160000 KHz), (N/A, 2698 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (57000000 KHz - 66000000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 16:46:41 dmx kernel: cfg80211: Invalid regulatory domain detected:
Aug 20 16:46:41 dmx kernel: cfg80211: Regulatory domain: 00

Aug 20 16:46:41 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 16:46:41 dmx kernel: cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 16:46:41 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 16:46:41 dmx kernel: cfg80211: World regulatory domain updated:
Aug 20 16:46:41 dmx kernel: cfg80211: DFS Master region: unset

Aug 20 16:46:41 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 16:46:41 dmx kernel: cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: Calling CRDA for country: AU
Aug 20 16:46:41 dmx kernel: cfg80211: Regulatory domain changed to country: AU
Aug 20 16:46:41 dmx kernel: cfg80211: DFS Master region: unset

Aug 20 16:46:41 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 16:46:41 dmx kernel: cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 1700 mBm), (N/A)
Aug 20 16:46:41 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2400 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5490000 KHz - 5710000 KHz @ 160000 KHz), (N/A, 2400 mBm), (0 s)
Aug 20 16:46:41 dmx kernel: cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 3000 mBm), (N/A)



here is the speed I've got: 130 Mb/s
WLE200NX Channel 13 HT40- as hostapd and Intel 1000 BGN as client.jpg


[/END Late EDIT]
I've bought the "Chinese" card because I thought that firmware from then does not contains regulatory information: I knew that on 2,4 Ghz the channels goes up to 14! But I never managed to put that card on channel 14!

Thank you again: it seems that Japan allows usage for channel 14! I have to test this! :)

Can I ask you for a favor?

Why my card is doing so many regulatory checks.

Look:

1. Bootlog - Calling CRDA for country: US
[root@dmx ~]# cat /var/log/bootlog |grep cfg
[ 11.149779] cfg80211: Calling CRDA to update world regulatory domain
[ 11.783543] cfg80211: World regulatory domain updated:
[ 11.783553] cfg80211: DFS Master region: unset

[ 11.783553] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
[ 11.783569] cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[ 11.783574] cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[ 11.783579] cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
[ 11.783586] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
[ 11.783592] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
[ 11.783597] cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
[ 11.783602] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
[ 11.783606] cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
[ 11.806975] cfg80211: Calling CRDA for country: US
[ 11.826481] cfg80211: Regulatory domain changed to country: US
[ 11.826490] cfg80211: DFS Master region: FCC

[ 11.826494] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
[ 11.826502] cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 3000 mBm), (N/A)
[ 11.826508] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 1700 mBm), (N/A)
[ 11.826515] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2300 mBm), (0 s)
[ 11.826520] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 3000 mBm), (N/A)
[ 11.826525] cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)


2. And other countries: - but these appears in /val/log/messages


Calling CRDA for country: DE
DFS Master region: ETSI


Then no domain at all:
Calling CRDA to update world regulatory domain
Regulatory domain: 00

Then "PL"
World regulatory domain updated:
Calling CRDA for country: PL
DFS Master region: ETSI

[root@dmx ~]# cat /var/log/messages |grep cfg
Aug 20 11:36:05 dmx kernel: cfg80211: Calling CRDA for country: DE
Aug 20 11:36:05 dmx kernel: cfg80211: Regulatory domain changed to country: DE
Aug 20 11:36:05 dmx kernel: cfg80211: DFS Master region: ETSI

Aug 20 11:36:05 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 11:36:05 dmx kernel: cfg80211: (2400000 KHz - 2483500 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5150000 KHz - 5250000 KHz @ 80000 KHz, 200000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5250000 KHz - 5350000 KHz @ 80000 KHz, 200000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5470000 KHz - 5725000 KHz @ 160000 KHz), (N/A, 2698 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (57000000 KHz - 66000000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 11:36:05 dmx kernel: cfg80211: Invalid regulatory domain detected:
Aug 20 11:36:05 dmx kernel: cfg80211: Regulatory domain: 00

Aug 20 11:36:05 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 11:36:05 dmx kernel: cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 11:36:05 dmx kernel: cfg80211: Calling CRDA to update world regulatory domain
Aug 20 11:36:05 dmx kernel: cfg80211: World regulatory domain updated:
Aug 20 11:36:05 dmx kernel: cfg80211: DFS Master region: unset

Aug 20 11:36:05 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 11:36:05 dmx kernel: cfg80211: (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: Calling CRDA for country: PL
Aug 20 11:36:05 dmx kernel: cfg80211: Regulatory domain changed to country: PL
Aug 20 11:36:05 dmx kernel: cfg80211: DFS Master region: ETSI

Aug 20 11:36:05 dmx kernel: cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Aug 20 11:36:05 dmx kernel: cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Aug 20 11:36:05 dmx kernel: cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (5490000 KHz - 5710000 KHz @ 160000 KHz), (N/A, 2700 mBm), (0 s)
Aug 20 11:36:05 dmx kernel: cfg80211: (57000000 KHz - 66000000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)
[root@dmx ~]#

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Re: Questions for a Wi-Fi/hostapd expert - partly answered!

Post by dnl » August 21st, 2015, 11:15 am

Excellent! I'm glad to hear you got it working how you wanted.
(I hope you don't have any other WiFi networks close by!!)


I'm not sure why "cfg80211" calls the CRDA for countries you have not set.
I can see that while bringing hostapd up (recently) I have entries in my 'messages' log showing "US" and "DE" regulatory domains - two countries which I've never set.

I had a quick read through the Kernel wiki about wireless (like this) but I'm sorry to say that I have not been able to find a list of regulatory domains.

The manufacturer, or country of origin, of your WiFi card has nothing to do with regulation. All the regulation is done by "crda" as a part of the Linux kernel's WiFi support.


Which reminds me, I'll update the Wireless wiki page to make it clear that HT Capabilities will vary depend on the country your from. I think that if I tried to write instructions for a non-technical person to configure their card's HT Capabilities, the instructions would end up being many pages long!


If it your WiFi card to be working well with hostapd now, could you please add it to the Hardware Compatibility list in the wiki? http://wiki.ipfire.org/en/hardware/networking
I checked quickly and didn't see it there.

Thanks!
Image

dnl
Posts: 292
Joined: June 28th, 2013, 11:03 am

Re: Questions for a Wi-Fi/hostapd expert - partly answered!

Post by dnl » August 27th, 2015, 11:19 am

For reference, I found why the country is set to DE, then World, then the country you selected.
It appears that the original developers for IPFire put in a work-around of some kind, cause this is in /etc/init.d/hostapd

Code: Select all

# First set to any country then reset to World (00)
                # and then set new country because the card is only
                # reprogrammed if the region was changed.
                /usr/sbin/iw reg set DE
                /usr/sbin/iw reg set 00
                /usr/sbin/iw reg set $COUNTRY


I'm not sure if that work-around is still required. Even if it is, the line setting "DE" seems redundant.


Also for reasons I don't yet understand, my WLE350NX [7A0000] does not work with 5 GHz at all. At times hostapd appears to start (the status is green in the IPFire WUI) but I'm getting these messages:

Code: Select all

Aug 27 11:03:38 ipfire hostapd: blue0: IEEE 802.11 Configured channel (48) not found from the channel list of current mode (1) IEEE 802.11g
Aug 27 11:03:38 ipfire hostapd: blue0: IEEE 802.11 Hardware does not support configured channel

which is a bit annoying. I don't know why it's saying the current mode is 802.11g, not '802.11gn' which is actually what is selected. I'll have to dig a bit further when I have time.
Image

Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests