mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-10-18 00:50:09 +03:00
feat: default vxlan_dstport to the IANA VXLAN port 4789
The custom 14789 was picked to keep our demux socket off the ports other VXLAN software listens on, but a private default surprises operators and blocks interop with gear that pins the standard port. Default to the IANA-assigned 4789 instead; the gns3_server.conf override is unchanged for computes where swarm overlay/flannel-style VXLAN already owns 4789. Mixed-version deployments must pin the port on every compute until they all run the new default, or the two tunnel ends will disagree.
This commit is contained in:
parent
6679774de7
commit
0d91d9252b
@ -98,7 +98,7 @@ The `vxlan show` step is the idempotency contract: a device found under the link
|
||||
| Key | Default | Meaning |
|
||||
|---|---|---|
|
||||
| `Server.enable_vxlan_cross_compute` | `false` | Wire eligible cross-compute links as VXLAN tunnels |
|
||||
| `Server.vxlan_dstport` | `14789` | The UDP port all tunnels of the deployment listen on (one kernel socket per port; chosen off the IANA 4789 and the legacy 8472 so other VXLAN software cannot merge demux tables with ours) |
|
||||
| `Server.vxlan_dstport` | `4789` | The UDP port all tunnels of the deployment listen on (one kernel socket per port; the IANA-assigned VXLAN port — change it when other VXLAN software on the computes already owns it, since a shared socket merges demux tables) |
|
||||
|
||||
## Known caveats
|
||||
|
||||
|
||||
@ -201,14 +201,13 @@ class ServerSettings(BaseModel):
|
||||
"frames. The relay stays the default and the fallback when a tunnel cannot be wired",
|
||||
)
|
||||
vxlan_dstport: int = Field(
|
||||
14789,
|
||||
4789,
|
||||
ge=1,
|
||||
le=65535,
|
||||
description="UDP destination port every cross-compute VXLAN tunnel listens on. The kernel shares one "
|
||||
"socket per port across all VXLAN devices, so all links of a deployment ride this one port — chosen "
|
||||
"off the IANA 4789 and the legacy 8472 (other VXLAN software's ports: sharing a socket would merge "
|
||||
"their demux table with ours) and above the ephemeral range. Change it only when it collides with "
|
||||
"a service already listening on the computes",
|
||||
"socket per port across all VXLAN devices, so all links of a deployment ride this one port — the "
|
||||
"IANA-assigned VXLAN port by default. Change it when other VXLAN software on the computes already "
|
||||
"listens on it: a shared socket merges their demux table with ours",
|
||||
)
|
||||
auto_discover_images: bool = Field(True, description="Automatically discover images in the images directory")
|
||||
image_sync_interval: int = Field(900, ge=10, description="Seconds between automatic image inventory scans")
|
||||
|
||||
@ -1476,7 +1476,7 @@ async def test_stop_clears_relay_bridge_registry(vm):
|
||||
# Cross-compute VXLAN tunnel
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
VXLAN_SPEC = {"name": "gvl01234567abcd", "vni": 1048577, "remote": "192.168.1.2", "dstport": 14789}
|
||||
VXLAN_SPEC = {"name": "gvl01234567abcd", "vni": 1048577, "remote": "192.168.1.2", "dstport": 4789}
|
||||
|
||||
|
||||
def test_create_nio_bridge_carries_vxlan_spec(vm):
|
||||
|
||||
@ -319,7 +319,7 @@ async def test_probe_vxlan_scratch_port_stays_off_the_configured_one(monkeypatch
|
||||
"""
|
||||
|
||||
settings = Config.instance().settings.Server
|
||||
for configured in (14789, 20000, 25000, 29999):
|
||||
for configured in (4789, 20000, 25000, 29999):
|
||||
monkeypatch.setattr(settings, "vxlan_dstport", configured)
|
||||
tc_probe._vxlan_cache.clear()
|
||||
assert await probe_vxlan_support() is True
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user