Documentation > Userspace Clients > eamt Mode

eamt Mode

Index

  1. Description
  2. Syntax
  3. Arguments
    1. Operations
    2. Options
  4. Overlapping EAM Entries
  5. Examples

Description

Interacts with Jool’s Explicit Address Mapping Table (EAMT). See the introduction for a swift overview, our RFC summary for more details, or the EAM RFC for the full story.

Syntax

jool_siit eamt (
	display [--csv]
	| add <IPv4-prefix> <IPv6-prefix> [--force]
	| remove <IPv4-prefix> <IPv6-prefix>
	| flush
)

Arguments

Operations

  • display: The EAMT is printed in standard output.
  • add: Combines <IPv4-prefix> and <IPv6-prefix> into an EAM entry, and uploads it to Jool’s table.
  • remove: Deletes from the table the EAM entry described by <IPv4-prefix> and/or <IPv6-prefix>.
  • flush: Removes all entries from the table.

Warning! If you want to add many EAM entries at once, eamt add might turn out to be very slow. If you run into this problem, try adding them through atomic configuration instead.

Options

Flag Description
--csv Print the table in Comma/Character-Separated Values format. This is intended to be redirected into a .csv file.
--force Upload the entry even if overlapping occurs. (See the next section.)

Overlapping EAM entries

By default, EAMT entries are not allowed to overlap. You can use --force while adding to override this property. When overlapping EAMT entries exist, Jool picks based on longest match prefix.

For example:

IPv4 Prefix IPv6 Prefix
192.0.2.0/24 2001:db8:aaaa::/120
192.0.2.8/29 2001:db8:bbbb::/125

Address 192.0.2.9 matches 192.0.2.8/29 better than 192.0.2.0/24, so it will get translated as 2001:db8:bbbb::1, not 2001:db8:aaaa::9.

Notice this creates assymetry. 2001:db8:aaaa::9 gets translated as 192.0.2.9, which in turn gets translated as 2001:db8:bbbb::1. Depending on your use case, this can break communication.

Overlapping EAMT entries exist to help EAM coexist with IVI. Other use cases might arise in the future.

Examples

These examples below assume that the name of the Jool instance is “default.”

Add a handful of mappings:

user@T:~# jool_siit eamt add 192.0.2.1      2001:db8:aaaa::
user@T:~# jool_siit eamt add 192.0.2.2/32   2001:db8:bbbb::b/128
user@T:~# jool_siit eamt add 192.0.2.16/28  2001:db8:cccc::/124
user@T:~# jool_siit eamt add 192.0.2.128/26 2001:db8:dddd::/64
user@T:~# jool_siit eamt add 192.0.2.192/31 64:ff9b::/127

Display the new table:

user@T:~# jool_siit eamt display
+---------------------------------------------+--------------------+
|                                 IPv6 Prefix |        IPv4 Prefix |
+---------------------------------------------+--------------------+
|                               64:ff9b::/127 |     192.0.2.192/31 |
|                         2001:db8:dddd::/64  |     192.0.2.128/26 |
|                         2001:db8:cccc::/124 |      192.0.2.16/28 |
|                        2001:db8:bbbb::b/128 |       192.0.2.2/32 |
|                         2001:db8:aaaa::/128 |       192.0.2.1/32 |
+---------------------------------------------+--------------------+

Dump the database on a CSV file:

user@T:~# jool_siit eamt display --csv > eamt.csv

eamt.csv

Remove the first entry:

user@T:~# jool_siit eamt remove 2001:db8:aaaa::

Empty the table:

user@T:~# jool_siit eamt flush