Welcome!
Important information
-- Spectre and Meltdown vulnerabilities
-- Change in MX sources

News
-- MX Linux on social media: here
-- Mepis support still here

Current releases
-- MX-17.1 Final release info here
-- antiX-17 release info here

New users
-- Please read this first, and don't forget to add system and hardware information to posts!
-- Here are the Forum Rules

M12 wifi regulation set to China's?

Questions about Networking that deals with wireless cards, ethernet, modems, samba and anything else related to these, including software help. Tutorials for any of these can be posted too.

Remember to provide relevant info in your posts, such as the following information:

Version of Mepis being used
Card Manufacturer (i.e. Linksys)
Card Model (i.e. WMP54G)
Type: (PCI or PCMCIA)
Current Kernel in use on their system (i.e. 2.6.10)
Udev or Hotplug
Exact steps taken to get the card working if it is not immediately recognized by MEPIS.
Post Reply
Message
Author
User avatar
Stevo
Forum Veteran
Forum Veteran
Posts: 16597
Joined: Fri Dec 15, 2006 8:07 pm

M12 wifi regulation set to China's?

#1 Post by Stevo » Sun Dec 22, 2013 3:51 pm

At least that's what I got with

Code: Select all

su -c 'iw reg get'

Code: Select all

country CN:
        (2402 - 2482 @ 40), (N/A, 20)
        (5735 - 5835 @ 40), (N/A, 30)
When set to 'murica's:

Code: Select all

su -c 'iw reg set US'
I get

Code: Select all

 country 00:
        (2402 - 2472 @ 40), (3, 20)
        (2457 - 2482 @ 20), (3, 20), PASSIVE-SCAN, NO-IBSS
        (2474 - 2494 @ 20), (3, 20), NO-OFDM, PASSIVE-SCAN, NO-IBSS
        (5170 - 5250 @ 40), (3, 20), PASSIVE-SCAN, NO-IBSS
        (5735 - 5835 @ 40), (3, 20), PASSIVE-SCAN, NO-IBSS
Anyone else have this behavior, or just me?

The region codes can be found here: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#US

User avatar
timkb4cq
Forum Veteran
Forum Veteran
Posts: 4421
Joined: Wed Jul 12, 2006 4:05 pm

Re: M12 wifi regulation set to China's?

#2 Post by timkb4cq » Sun Dec 22, 2013 4:32 pm

My Trendnet adapter doesn't create the nl80211 file required for iw to work.

However, checking available channels with iwlist wlan0 channel shows that channels 1 through 14 are enabled. Channel 14 is not allowed in the US, 12 & 13 have restrictions and normally aren't used except insofar as channel 11 overlaps their frequency range. Of course since it only connects to my AP, it won't broadcast in those channels - but it could...

Does someone know where the wlan defaults are kept?
MSI 970A-G43 MB, AMD FX-6300 (six core), 16GB RAM, GeForce 730, Samsung 850 EVO 250GB SSD, Seagate Barracuda XT 3TB

User avatar
Stevo
Forum Veteran
Forum Veteran
Posts: 16597
Joined: Fri Dec 15, 2006 8:07 pm

Re: M12 wifi regulation set to China's?

#3 Post by Stevo » Mon Dec 23, 2013 11:09 pm

After some man page reading, it appears there's a binary file that contains the settings for each country, which can be displayed with

regdbdump /lib/crda/regulatory.bin

The kernel apparently decides which to use by looking at the COUNTRY environment variable, in the absence of that, it may get it from the driver itself. Doesn't look like M12 sets that variable by default...
Description
crda is the Linux wireless central regulatory domain agent. crda is intended to be used by udev scripts and should not be run manually unless debugging udev scripts. crda is triggered to run by the kernel by sending a udev event upon a new regulatory domain change. Regulatory domain changes are triggered by the wireless kernel subsystem (upon initialization and on reception of country IEs), wireless drivers, or userspace (see iw ). Upon a regulatory domain change the kernel sends a udev change event for the regulatory platform. The kernel ignores regulatory domains sent to it if it does not expect them. The regulatory domain is read by crda from the regulatory.bin file.
Environment variable
Set the COUNTRY environment variable with a specific ISO / IEC 3166 alpha2 country code and then run crda without arguments. This will send a regulatory domain for that alpha2 to the kernel.

User avatar
JBoman
Forum Guide
Forum Guide
Posts: 1320
Joined: Wed Jul 12, 2006 4:30 pm

Re: M12 wifi regulation set to China's?

#4 Post by JBoman » Tue Dec 24, 2013 9:42 pm

Stevo wrote:After some man page reading, it appears there's a binary file that contains the settings for each country, which can be displayed with

regdbdump /lib/crda/regulatory.bin

The kernel apparently decides which to use by looking at the COUNTRY environment variable, in the absence of that, it may get it from the driver itself. Doesn't look like M12 sets that variable by default...
Description
crda is the Linux wireless central regulatory domain agent. crda is intended to be used by udev scripts and should not be run manually unless debugging udev scripts. crda is triggered to run by the kernel by sending a udev event upon a new regulatory domain change. Regulatory domain changes are triggered by the wireless kernel subsystem (upon initialization and on reception of country IEs), wireless drivers, or userspace (see iw ). Upon a regulatory domain change the kernel sends a udev change event for the regulatory platform. The kernel ignores regulatory domains sent to it if it does not expect them. The regulatory domain is read by crda from the regulatory.bin file.
Environment variable
Set the COUNTRY environment variable with a specific ISO / IEC 3166 alpha2 country code and then run crda without arguments. This will send a regulatory domain for that alpha2 to the kernel.
said command lists all countries here and I see that the US and China are the same... dunno why. :turtle:
http://patentabsurdity.com/
AMD 64x2 2.6GHz 4GB ram MX-17.1 KDE regular updates
"beware a frequent flirt with potential disaster"

Post Reply

Return to “Networking”