Check and Refresh Linux's regulatory.db Wireless Database

A laptop that suddenly cannot see 5GHz channels abroad is not always a driver problem: check regulatory.db first. This file tells the kernel which wireless frequencies and power levels are legal for a given country, and this guide walks through confirming which package supplied it and refreshing it safely through your distribution. Allow about ten minutes.

It is not a general setting for forcing a preferred country, and changing it by hand can leave you with a broken or untrusted firmware file. You need a shell and permission to read the firmware directory. The examples use Debian or Ubuntu package tools because the installed source package here is wireless-regdb version 2026.05.30-0ubuntu1~24.04.1. Commands that only inspect files are unprivileged; installing an update needs the usual administrative privileges, normally through sudo.

Checkpoint: this guide does not change the regulatory country, reload a wireless driver, restart networking, or replace a firmware file manually.

1. Check the installed package

Start with the package database. This is an ordinary, read-only command:

$ dpkg-query -W -f='${Package} ${Version}\n' wireless-regdb
wireless-regdb 2026.05.30-0ubuntu1~24.04.1

Your version may differ; keep it with any bug report, because regulatory data changes independently of the kernel version. If the command says the package is not installed, do not create regulatory.db yourself. Find the distribution package that owns the file, or install the supported wireless-regdb package for your system.

2. Locate the kernel firmware file

The newer database format is read directly by the kernel as a firmware file. Check both common paths without writing anything:

$ for path in /lib/firmware/regulatory.db /usr/lib/firmware/regulatory.db; do
>     if test -e "$path"; then
>         stat -c '%n %s bytes %y' "$path"
>         file "$path"
>     fi
> done
/lib/firmware/regulatory.db 6380 bytes 2026-08-17 18:38:10.000000000 +0100
/lib/firmware/regulatory.db: CRDA wireless regulatory database file

On systems using a merged /usr, the two names can refer to the same file. Do not treat the size or timestamp above as a universal expected value: the useful result is that a file exists in the firmware search path, and that file recognises it as a wireless regulatory database.

Check the companion signature too:

$ stat -c '%n %s bytes' /lib/firmware/regulatory.db.p7s
$ file /lib/firmware/regulatory.db.p7s
/lib/firmware/regulatory.db.p7s: DER Encoded PKCS#7 Signed Data

The package installs this signature beside the database. Its presence is a useful packaging check, but do not assume a locally copied database is trusted just because a file with the .p7s suffix sits next to it. Let the package manager obtain and verify updates from your configured repositories.

3. Understand the two database names

The manual page documents two related formats. regulatory.bin is the older file read by crda when the kernel requests information for an ISO or IEC 3166 alpha-2 country code. regulatory.db is newer and extensible; since Linux 4.15, the kernel reads it directly as firmware. These are not two files you edit in turn to make a laptop use a different legal domain.

On a current system, the practical object to check is regulatory.db. A machine can still have older userspace components or documentation referring to regulatory.bin, but that does not make the older path the right repair for a missing modern firmware file. Do not install crda just because the manual page mentions it.

Checkpoint: verify the running kernel before diagnosing a format mismatch:

$ uname -r
6.8.0-XX-generic

The exact release is host-specific. The version boundary in the manual is Linux 4.15, not a promise that every distribution exposes the same firmware directory or packaging layout.

4. Refresh through the package manager

First ask whether the configured repositories offer a newer package. This reads package metadata and installs nothing:

$ apt-cache policy wireless-regdb
wireless-regdb:
  Installed: 2026.05.30-0ubuntu1~24.04.1
  Candidate: 2026.05.30-0ubuntu1~24.04.1

Use the candidate shown by your host, not the illustrative version above. If a newer candidate is available, schedule the normal maintenance action and install it with administrative privileges:

$ sudo apt update
$ sudo apt install --only-upgrade wireless-regdb

Warning: this changes files under the firmware directory. It can affect later wireless regulatory decisions and may be followed by a driver or system restart on some systems. Do not run it during a change freeze, or on equipment where a wireless outage is unacceptable without a recovery path. The undo operation is a package downgrade to a specific, trusted version, for example sudo apt install wireless-regdb=VERSION, if that version is still available in your repositories. Record the current version before upgrading.

5. Verify after an update

Repeat the package and file checks once the package manager exits successfully:

$ dpkg-query -W -f='${Package} ${Version}\n' wireless-regdb
$ test -r /lib/firmware/regulatory.db && echo 'regulatory.db is readable'
regulatory.db 2026.05.30-0ubuntu1~24.04.1
regulatory.db is readable

If the path is absent but /usr/lib/firmware/regulatory.db exists, check which path your firmware loader actually uses before making a link or copy. Do not paper over that ambiguity with a hand-created symlink until you understand the distribution's merged-/usr layout.

If wireless behaviour still looks wrong, separate database checks from country selection and driver diagnostics. Check the kernel and wireless logs with your normal operational tools, and record the adapter, driver, kernel release and package version. A valid database does not guarantee that a particular adapter supports every channel or power level.

Done means