regdbdump
Dump wireless regulatory database contents
SYNOPSIS
regdbdump [options]
PARAMETERS
-h, --help
Displays a help message and exits.
-v, --version
Shows version information and exits.
-i, --iso
Displays the currently active ISO 3166-1 alpha2 country code configured in the kernel.
-s, --source
Indicates the source of the regulatory database being used (e.g., built-in kernel data, loaded from a userspace file).
-r, --raw
Dumps the regulatory database in a raw, machine-readable format. This format is typically intended for parsing by other tools or scripts.
-p, --pretty
Dumps the database in a human-readable, pretty-printed format. This is often the default output format for easier readability.
-a, --active
Dumps only the active regulatory rules that apply to the currently configured country, providing a concise view of current restrictions.
-c
Dumps regulatory rules for a specific 2-letter ISO 3166-1 alpha2 country code (e.g., 'US' for United States, 'DE' for Germany).
-f
Dumps the contents of a specified regulatory database file instead of the kernel's currently active regulatory database.
DESCRIPTION
regdbdump is a utility designed to inspect the contents of the Linux kernel's wireless regulatory database. This crucial database holds rules governing the operation of wireless devices, such as Wi-Fi adapters, based on the current geographical location or country code.
It defines permitted frequency ranges, maximum transmission power levels, and allowed operational modes to ensure compliance with local and international regulations. The command allows users to view the entire database, rules for specific countries, or the currently active regulatory settings. This makes it an invaluable tool for debugging wireless connectivity issues related to regulatory restrictions, verifying proper regional configurations, or understanding wireless spectrum usage. It's commonly used by developers, system administrators, and advanced users involved in wireless networking.
CAVEATS
The output of `regdbdump` can be very extensive, especially when dumping the entire database without specifying a country. Users should be aware that `regdbdump` is a diagnostic tool; it only reads and displays the regulatory database state and does not modify it. Changes to the regulatory domain are typically managed by tools like `iw` or `crda`. Interpreting the raw output (`-r` option) requires an understanding of the regulatory database file format.
REGULATORY DOMAIN
Wireless devices must operate within specific frequency ranges and power limits as mandated by regulatory bodies in different countries. The Linux kernel maintains a regulatory database to enforce these rules, preventing interference and ensuring legal operation.
KERNEL INTEGRATION
The wireless subsystem within the Linux kernel (primarily `mac80211` and `cfg80211`) relies on information provided by `crda` (which itself utilizes the `regdb` database) to ensure that Wi-Fi adapters and other wireless devices adhere to the local regulatory requirements of the active domain.
DATABASE FORMAT
The regulatory database files, typically located in `/lib/crda/`, are stored in a binary format. `regdbdump` possesses the capability to parse this binary format and present its contents in either a raw or a more human-readable, pretty-printed form.
HISTORY
`regdbdump` is an integral part of the `crda` (Central Regulatory Domain Agent) project. This project was developed to standardize and manage the Linux kernel's wireless regulatory domain settings. Before `crda`, wireless drivers often contained hardcoded regulatory information, which led to inconsistencies and challenges in complying with diverse international regulations. The introduction of `crda` and its accompanying utilities, including `regdbdump`, established a unified and flexible mechanism for dynamically applying regulatory rules based on the system's geographical location, thereby ensuring legal and compliant wireless operation across various regions.