jool(8)
β¨ NAME β¨
jool β jool(8), NAT64 Jool's Userspace Client. Your way to interact with NAT64 Jool (the kernel module). You send commands, you send requests, you get things done. no cap. π
π DESCRIPTION π
Okay so listen. jool is the userspace client that sends commands and requests to NAT64 Jool. And NAT64 Jool? It's a kernel module β you load it into a Linux kernel. It implements RFC 6146. That's the whole thing. It's giving networking royalty. π
π AVAILABILITY π
Linux is literally the only OS where this program makes sense. Like, don't try this on anything else, bestie. π§
Kernels 5.15 and up. Periodt.
π SYNTAX π
Here's the whole syntax tree, bestie. The pipes (|) mean "or", the brackets mean optional, and the nested stuff is just doing its little dance. π
jool [<argp1>] instance (
display
[--csv]
[--no-headers]
| add
[<Instance-Name>]
(--netfilter | --iptables)
--pool6 <IPv6-prefix>
| remove
[<Instance-Name>]
| flush
)
jool [<argp1>] stats (
display
[--csv]
[--no-headers]
[--all]
[--explain]
)
jool [<argp1>] global (
display
[--csv]
[--no-headers]
| update
<Key> <Value>
)
jool [<argp1>] pool4 (
display
[--csv]
[--no-headers]
[--tcp | --udp | --icmp]
| add
<IPv4-Address> <Ports>
[--tcp | --udp | --icmp]
[--mark <Mark>]
[--max-iterations (auto | infinity | <Iterations>)]
[--force]
| remove
<IPv4-Address> <Ports>
[--tcp | --udp | --icmp]
[--mark <Mark>]
[--quick]
| flush
[--quick]
)
jool [<argp1>] bib (
display
[--csv]
[--no-headers]
[--tcp | --udp | --icmp]
[--numeric]
| add
<IPv6-Transport-Address>
<IPv4-Transport-Address>
[--tcp | --udp | --icmp]
| remove
[<IPv6-Transport-Address>]
[<IPv4-Transport-Address>]
[--tcp | --udp | --icmp]
)
jool [<argp1>] session (
display
[--csv]
[--no-headers]
[--tcp | --udp | --icmp]
[--numeric]
| follow
| proxy
[--net.dev.in=<NETDEVIN>]
[--net.dev.out=<NETDEVOUT>]
[--net.mcast.port=<NETMCASTPORT>]
[--stats.address=<STATSADDR>]
[--stats.port=<STATSPORT>]
[--net.ttl=<NETTTL>]
<NETMCASTADDR>
| advertise
)
jool [<argp1>] file (
handle <JSON-File>
)
<argp1> := (--instance <Name> | --file <File>)
β¨ OPTIONS β¨
π Modes and Operations
okay bestie, this is the fun part β these are literally the verbs you're telling jool to do. pick one, stack it with the flags below, and go off π
instance displayβ shows you every instance from every namespace. all of them. the whole squad. πinstance addβ makes a brand new instance. baby's first NAT64, so cute πΌinstance removeβ yeets an existing instance into the void. bye bestie πinstance flushβ drops all instances from the current namespace. it's giving "clear the group chat" energy πstats displayβ shows the internal counters. the receipts, basically πglobal displayβ shows you what the instance's tweakable internal variables are currently set to. the current vibe, quantified β¨global updateβ changes one of those internal variables. glow-up time πΈpool4 displayβ shows you one of the tables from the IPv4 transport address pool. (every protocol gets its own table, jsyk)pool4 addβ uploads an entry to the IPv4 transport address pool π₯pool4 removeβ drops transport addresses out of the IPv4 transport address poolpool4 flushβ empties the IPv4 transport address pool entirely. total reset π§Ήbib displayβ shows you one of the BIB tables. (again, one table per protocol)bib addβ adds a static entry to the BIBbib removeβ removes an entry from the BIB, static or not, doesn't mattersession displayβ shows you one of the session tables. (you guessed it, one per protocol)session followβ listens to the instance's sessions forever, printing them to standard output whenever they get updated. the way it just keeps watching π the instance needsss-enabled=1for this to work.session proxyβ listens to sessions forever and exchanges them between the instance and other listening proxies. the-iinstance needsss-enabled=1here too.session advertiseβ asks the instance to send its whole entire session table to all the listening followers and proxies. "hey everyone, look at my sessions" π’file handleβ parses all the config out of a JSON file. if the instance doesn't exist it creates it, if it does exist it updates it. lowkey the most useful one ngl
π Flags
--instance <Name>β the name of the instance you wanna interact with. it's an ASCII string,15characters max. defaults to'default'.--file <File>β a JSON file containing the name of the instance you want to interact with. same JSON structure as the one from atomic configuration.--tcpβ apply the operation on the TCP table. (this is the default table, so if you're a TCP girlie you can just vibe)--udpβ apply the operation on the UDP table.--icmpβ apply the operation on the ICMP table.--csvβ output in CSV table format. spreadsheet girlies rise π«Ά--no-headersβ don't print the table headers. (nor the footer, if one applies.)--netfilterβ sit the instance on top of the Netfilter framework.--iptablesβ sit the instance on top of the iptables framework.--pool6 <IPv6-prefix>β the contents of the new instance's IPv6 pool. the format is'PREFIX_ADDRESS[/PREFIX_LENGTH]'.--allβ show all the counters. (otherwise, only the nonzero ones get printed.)--explainβ show a description of each counter. it explains itself, iconic π--mark <Mark>β the pool4 entry will only be allowed to mask packets carrying this mark. it's a32-bit unsigned integer. defaults to zero.--max-iterations (auto | infinity | <Iterations>)β the maximum number of times the mask-finding algorithm is allowed to iterate.autocomputes a recommended default,infinityremoves the iteration cap entirely (yolo), and<Iterations>(an unsigned32-bit integer) sets the actual number.--forceβ apply the operation even if certain validations fail. chaotic but valid π₯--quickβ don't remove orphaned BIB and session entries.--numericβ don't query the DNS.
π¦ Other Arguments
<Key> <Value>β the name of the variable you want to edit (check theGlobalssection below bestie) and its new value.<IPv4-Address> <Ports>β a descriptor of the range of transport addresses you want to add to or remove from the pool.<Ports>is a range of ports and it should follow the format'<Min>[-<Max>]'. the command will add or remove addresses<IPv4-Address>#<Min>through<IPv4-Address>#<Max>.<IPv6-transport-address>,<IPv4-transport-address>β the transport addresses that shape the BIB entry you want to add or remove. the format is'IPV6_ADDRESS#PORT'and'IPV4_ADDRESS#PORT', respectively.<Instance-Name>β the name of the instance you want to add or remove. if--instanceor--filewere included in<argp1>, then the instance names have to match.<JSON-file>β path to a JSON file.<NETMCASTADDR>β the address SS traffic will be sent to and listened from.<NETMCASTPORT>β the UDP port where SS traffic will be sent to and listened from.<NETDEVIN>β the address or interface to bind the socket in. if<NETMCASTADDR>is IPv4, this should be one address from the interface where the SS traffic is expected to be received. if<NETMCASTADDR>is IPv6, this should be the name of the interface (eg.eth0).<NETDEVOUT>β if<NETMCASTADDR>is IPv4, this should be one address from the interface where the multicast traffic is expected to be sent. if<NETMCASTADDR>is IPv6, this should be the name of the interface (eg.eth0).<NETTTL>β same asIP_MULTICAST_TTL, fromip(7).<STATSADDR>β address for the (optional) statistics server.<STATSPORT>β port for the<STATSADDR>server.
π Globals
these are the variables you can poke with global display and global update. get to know them, they're your new besties π
manually-enabled <Boolean>β enable or disable the instance.pool6 <IPv6 Prefix>β the IPv6 pool's prefix. the format is'PREFIX_ADDRESS[/PREFIX_LENGTH]'.lowest-ipv6-mtu <Unsigned 32-bit integer>β the smallest reachable IPv6 MTU.logging-debug <Boolean>β enable logging of debug messages?zeroize-traffic-class <Boolean>β always set the IPv6 header's'Traffic Class'field as zero? otherwise it copies from the IPv4 header's'TOS'.override-tos <Boolean>β override the IPv4 header's'TOS'field as--tos? otherwise it copies from the IPv6 header's'Traffic Class'.tos <Unsigned 8-bit integer>β the value to override TOS as (only whenoverride-tosis ON).mtu-plateaus <Comma-separated list of unsigned 16-bit integers>β set the list of plateaus for ICMPv4 Fragmentation Neededs with MTU unset.address-dependent-filtering <Boolean>β behave as (address-)restricted-cone NAT? otherwise behave as full-cone NAT.drop-icmpv6-info <Boolean>β filter ICMPv6 Informational packets?drop-externally-initiated-tcp <Boolean>β drop externally initiated TCP connections?tcp-est-timeout <HH:MM:SS.mmm>β set the TCP established session lifetime.tcp-trans-timeout <HH:MM:SS.mmm>β set the TCP transitory session lifetime.udp-timeout <HH:MM:SS.mmm>β set the UDP session lifetime.icmp-timeout <HH:MM:SS.mmm>β set the ICMP session lifetime.maximum-simultaneous-opens <Unsigned 32-bit integer>β set the maximum allowable 'simultaneous' Simultaneos Opens of TCP connections.source-icmpv6-errors-better <Boolean>β translate source addresses directly on 4-to-6 ICMP errors?f-args <Unsigned 4-bit integer>β defines the arguments that will be sent toF(). (F()is defined by algorithm3of RFC6056.)- First (leftmost) bit is source address.
- Second bit is source port.
- Third bit is destination address.
- Fourth (rightmost) bit is destination port.
handle-rst-during-fin-rcv <Boolean>β use the transitory timer when RST is received during the V6 FIN RCV or V4 FIN RCV states?logging-bib <Boolean>β log BIBs as they are created and destroyed?logging-session <Boolean>β log sessions as they are created and destroyed?trace <Boolean>β log basic packet fields as they are received?ss-enabled <Boolean>β enable Session Synchronization?ss-flush-asap <Boolean>β try to synchronize sessions as soon as possible?ss-flush-deadline <Unsigned 32-bit integer>β inactive milliseconds after which to force a session sync.ss-capacity <Unsigned 32-bit integer>β maximim number of queuable entries.ss-max-payload <Unsigned 32-bit integer>β maximum amount of bytesjooldshould send per packet.
πΈ EXAMPLES πΈ
okay here's where it gets fun, copy-paste these and you're basically a network engineer π
create a new instance named "Example":
jool instance add Example --iptables --pool6 64:ff9b::/96
add addresses 192.0.2.10#1024 to 192.0.2.10#2048 to the IPv4/TCP pool:
jool -i Example pool4 add 192.0.2.10 1024-2048 --tcp
print the TCP table of the BIB:
jool -i Example bib display
add an UDP binding to the BIB:
jool -i Example bib add 192.0.2.10#2000 1::1#2000 --tcp
remove the binding from the BIB:
jool -i Example bib remove 192.0.2.10#2000 --tcp
print the TCP session table:
jool -i Example session display
print the global configuration values:
jool -i Example global display
update some global configuration value:
jool -i Example global update address-dependent-filtering ON
π NOTES π
TRUE, FALSE, 1, 0, YES, NO, ON and OFF are all valid booleans. you can mix case too, so go wild bestie π
π EXIT STATUS π
Zero on success, non-zero on failure. simple as, fr fr.
π AUTHOR π
NIC Mexico & ITESM
π REPORTING BUGS π
https://github.com/NICMx/Jool/issues
π COPYRIGHT π
Copyright 2011 NIC Mexico.
License: GPLv2 (GNU GPL version 2)
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. (bestie. they mean it. no takebacks π)
π¦ SEE ALSO π¦
and that's the whole page, bestie!! π this version is v4.1.15, dated 2026-01-26, and it lives in section jool(8) β go forth and translate some addresses, you absolute icon π
β¨
π¦ where this page comes from
- nixpkgs unstable: jool-cli 4.1.15
- ubuntu resolute: jool-tools 4.1.15-1 Β· GPL-2.0-only
- ubuntu stonking: jool-tools 4.1.15-1ubuntu1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms