You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/pages/selfhosted/geo-support.mdx
+60-3Lines changed: 60 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,64 @@ local GeoLite2 databases updated. When the `management` service is started, the
27
27
if the current database is outdated. If the database is outdated or does not exist, the files will be downloaded
28
28
and loaded automatically. Restarting the `management` service will trigger the update check.
29
29
30
-
This behavior can be disabled by passing the `--disable-geolite-update` flag to the `management` command. When
31
-
`--disable-geolite-update` is set, the service will download the geolite databases only if there is no file in the data directory. The database with the
32
-
most recent date will be loaded if more than one exists. If a database does not exist, it will be downloaded
30
+
This behavior can be disabled by passing the `--disable-geolite-update` flag to the `management` command or by setting
31
+
`disableGeoliteUpdate: true` in the [combined configuration file](https://github.com/netbirdio/netbird/blob/318cf59d660ef6195f86b8982d38acb891c0beb6/combined/config-simple.yaml.example#L81):
32
+
33
+
```yaml
34
+
disableGeoliteUpdate: true
35
+
```
36
+
37
+
When disabled, the service will download the geolite databases only if there is no file in the data directory. The database with the
38
+
most recent date will be loaded if more than one exists. If a database does not exist, it will be downloaded
33
39
and loaded, but it will not be updated on subsequent restarts of the `management` service.
40
+
41
+
## Disabling geolocation entirely
42
+
43
+
If you do not need geolocation-based posture checks, you can disable the geolocation service entirely by setting the environment variable:
44
+
45
+
```bash
46
+
NB_DISABLE_GEOLOCATION=true
47
+
```
48
+
49
+
When set, the management server will skip geolocation initialization and will not attempt to download any databases.
50
+
51
+
## Troubleshooting: GeoLite2 download fails in restricted networks
52
+
53
+
In some network environments, the automatic download of the GeoLite2 database from `pkgs.netbird.io` may fail.
54
+
This commonly happens when:
55
+
56
+
- Corporate firewalls perform **deep packet inspection (DPI)**, intercepting HTTPS traffic and re-signing certificates with internal certificate authorities. The management server cannot verify these intercepted certificates, causing TLS errors during the download.
57
+
- Outbound access to `pkgs.netbird.io` is **blocked by firewall rules** or proxy restrictions.
58
+
- The server has **no internet access** at all (air-gapped environments).
59
+
60
+
See [netbirdio/netbird#5216](https://github.com/netbirdio/netbird/pull/5216) for more context on this issue.
61
+
62
+
If you are affected, you can manually provide the GeoLite2 database file instead of relying on the automatic download:
63
+
64
+
1. **Disable automatic updates** by passing the `--disable-geolite-update` flag or setting `disableGeoliteUpdate: true` in the config to prevent the server from attempting to download or overwrite the database.
65
+
66
+
2. **Download the GeoLite2 City database** from [MaxMind's GeoLite2 page](https://dev.maxmind.com/geoip/geolite2-free-geolocation-data/). You will need a free MaxMind account to download the MMDB file.
67
+
68
+
3. **Place the file in the management data directory** with the naming convention `GeoLite2-City_YYYYMMDD.mmdb` (e.g., `GeoLite2-City_20260127.mmdb`).
69
+
70
+
### Locating the data directory
71
+
72
+
For Docker-based self-hosted deployments, the management data is stored in a Docker volume. You can find it at:
73
+
74
+
```
75
+
/var/lib/docker/volumes/netbird_data/_data/
76
+
```
77
+
78
+
The directory contents look something like this:
79
+
80
+
```bash
81
+
root@selfhosted-1:/var/lib/docker/volumes/netbird_data/_data# ls -l
82
+
total 72452
83
+
-rw-r--r-- 1 root root 63524357 Feb 13 23:00 GeoLite2-City_20260127.mmdb
84
+
-rw-r--r-- 1 root root 425984 Feb 17 19:31 events.db
85
+
-rw-r--r-- 1 root root 7307264 Feb 13 23:00 geonames_20260127.db
86
+
-rw-r--r-- 1 root root 98304 Feb 18 14:07 idp.db
87
+
-rw-r--r-- 1 root root 2826240 Feb 18 14:07 store.db
88
+
```
89
+
90
+
Copy your downloaded GeoLite2 MMDB file into this directory, then restart the management service. The server will detect and load the existing database file without attempting a download.
0 commit comments