xt_geoip_build(1)
β¨ NAME β¨
xt_geoip_build β the little tool that turns GeoIP.csv into the packed format that xt_geoip is absolutely obsessed with π
It lives in the xtables-addons manual, btw. Bestie, let's get into it.
πΈ SYNTAX πΈ
/usr/libexec/xt_geoip/xt_geoip_build [-D target_dir] [-i input_file]
Yeah, she's got a whole path and everything. More on why below π
π DESCRIPTION π
Okay so, xt_geoip_build is the one who builds packed raw representations of the range database that the xt_geoip module literally cannot function without. And why do we do the preprocessing in userspace, you ask? Because kernel memory is precious, bestie. It's giving limited. It's giving do-not-waste. So this very building tool does all the heavy lifting up front instead π«Ά
One file gets produced for each country, so that no more addresses than needed ever have to get loaded into memory. Efficiency queen π
And the ranges in those packed database files are also ordered, which is not just a cute aesthetic choice β xt_geoip relies on that exact property so its bisection approach actually works. No order, no bisection, no slay. Periodt.
Also? Since this script is usually installed to the libexec directory of thextables-addonspackage, and that directory is outside$PATHon purpose, you can't just call it by name. You have to invoke it with a path. That's not a bug, that's a boundary π
-Dtarget_dir β Specifies the target directory into which the files are to be put. Defaults to.β yes, literally just a dot, current directory vibes πΈ-iinput_file β Specifies the source location of the DBIP CSV file. Defaults todbip-country-lite.csv. And if you use-you get to read from stdin, iconic behavior β¨-sβ "System mode". Equivalent to-D /usr/share/xt_geoip. That's it, that's the whole vibe.
π¦ APPLICATION π¦
Shell commands to build the databases and put them where they're expected β usually run as root, so hydrate first and remember your power π:
xt_geoip_build -s
π SEE ALSO π
And that's the whole page, bestie. This one came from xtables-addons, dated 2010-12-17 β so she's been serving since way before you were on this app, and she still ate π
π no cap, 10/10, go build your databases π¦β¨
π¦ where this page comes from
- alpine 3.22: xtables-addons-doc 3.26-r0 Β· GPL-2.0-only
- alpine 3.23: xtables-addons-doc 3.30-r0 Β· GPL-2.0-only
- alpine 3.24: xtables-addons-doc 3.30-r0 Β· GPL-2.0-only
- debian bookworm: xtables-addons-common 3.23-1 Β· GPL-2.0-only
- debian trixie: xtables-addons-common 3.27-4 Β· GPL-2.0-only
- opensuse-leap 16.0: xtables-addons 3.27-lp160.3.1 Β· GPL-2.0-only AND GPL-2.0-or-later
- opensuse-leap 16.0: xtables-addons 3.27-lp160.3.1 Β· GPL-2.0-only AND GPL-2.0-or-later
- opensuse-leap 16.0: xtables-addons 3.27-lp160.3.1 Β· GPL-2.0-only AND GPL-2.0-or-later
- opensuse-leap 16.0: xtables-addons 3.27-lp160.3.1 Β· GPL-2.0-only AND GPL-2.0-or-later
- ubuntu jammy: xtables-addons-common 3.19-1 Β· GPL-2.0-only
- ubuntu jammy: xtables-addons-common 3.19-1ubuntu1 Β· GPL-2.0-only
- ubuntu noble: xtables-addons-common 3.25-2build1 Β· GPL-2.0-only
- ubuntu noble: xtables-addons-common 3.25-2ubuntu0.2 Β· GPL-2.0-only
- ubuntu questing: xtables-addons-common 3.29-2
- ubuntu resolute: xtables-addons-common 3.30-1 Β· GPL-2.0-only
- ubuntu stonking: xtables-addons-common 3.31-1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms