vlan: a routed port is not a VLAN member, so a router's show vlan has an empty Ports column #1851

Merged
jaylouisw merged 1 commit from rev/1117-1331 into main 2026-11-17 13:52:59 +00:00
Owner

Question. On a real IOS router, is a routed port a member of a VLAN - does it appear in the Ports column of the VLAN table?

Verdict (settled half). No. A routed port has no access VLAN, show interfaces switchport refuses it with "is not a switchable port", and a router with a switch module lists only the module ports:

Router# show vlan-switch brief
1    default                          active    Fa0/2, Fa0/9, Fa0/14, Gi0/0

(Cisco, EtherSwitch Network Module, https://www.cisco.com/en/US/docs/ios/lanswitch/configuration/guide/lsw_enet_switch_net.html ; Connected Grid 1000 L2/3 guide prints the same table.)

Engine printed 1 default active Gi0/0, Gi0/1, Gi0/2 on a router - its routed sockets as VLAN 1 members.

Changed. engine/cli.js show vlan: membership is collected only when dev.isL2(), the same predicate Device.inactiveVlan() uses. Switches unchanged; the table itself stays (whether a router answers show vlan at all is per platform - 837 refuses, 2811 needs vlan database, ISR 1100 takes global vlan - so no refusal is invented).

Unresolved (research/vlan-on-a-router.md): show vlan vs show vlan-switch on the same module box; whether a module-less router answers at all; whether module routers print reserved VLANs as active.

Gates. syntax-check 388 files OK; new test 15/0; full npm test 316 suites, 11001 assertions, 1 failure at the time - docs-show-commands, caused by the docs edit naming show vlan-switch brief, fixed and re-run 7/0. All other doc-parsing tests re-run green (canonical-urls 52, docs-cli-transcript 4, help-completeness 8, arp-ageing 31, interface-brief 12, ping-default-count 18).

**Question.** On a real IOS router, is a routed port a member of a VLAN - does it appear in the Ports column of the VLAN table? **Verdict (settled half).** No. A routed port has no access VLAN, `show interfaces switchport` refuses it with "is not a switchable port", and a router with a switch module lists only the module ports: ``` Router# show vlan-switch brief 1 default active Fa0/2, Fa0/9, Fa0/14, Gi0/0 ``` (Cisco, EtherSwitch Network Module, https://www.cisco.com/en/US/docs/ios/lanswitch/configuration/guide/lsw_enet_switch_net.html ; Connected Grid 1000 L2/3 guide prints the same table.) Engine printed `1 default active Gi0/0, Gi0/1, Gi0/2` on a router - its routed sockets as VLAN 1 members. **Changed.** `engine/cli.js` `show vlan`: membership is collected only when `dev.isL2()`, the same predicate `Device.inactiveVlan()` uses. Switches unchanged; the table itself stays (whether a router answers `show vlan` at all is per platform - 837 refuses, 2811 needs `vlan database`, ISR 1100 takes global `vlan` - so no refusal is invented). **Unresolved** (research/vlan-on-a-router.md): `show vlan` vs `show vlan-switch` on the same module box; whether a module-less router answers at all; whether module routers print reserved VLANs as `active`. **Gates.** syntax-check 388 files OK; new test 15/0; full `npm test` 316 suites, 11001 assertions, 1 failure at the time - `docs-show-commands`, caused by the docs edit naming `show vlan-switch brief`, fixed and re-run 7/0. All other doc-parsing tests re-run green (canonical-urls 52, docs-cli-transcript 4, help-completeness 8, arp-ageing 31, interface-brief 12, ping-default-count 18).
vlan: a routed port is not a VLAN member, so a router's show vlan has an empty Ports column
All checks were successful
CI / Classify the change (pull_request) Successful in 8s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 14s
CI / Server smoke test (pull_request) Successful in 7s
CI / Docker build (pull_request) Successful in 22s
CI / Test (Node 20) (pull_request) Successful in 50s
CI / Test (Node 22) (pull_request) Successful in 52s
CI / Test (Node 18) (pull_request) Successful in 57s
CI / Arm auto-merge (pull_request) Successful in 6s
acbc1456b7
A routed port has no access VLAN - `show interfaces switchport` refuses it with "is not a
switchable port" - and a router's own VLAN table lists its switch module's ports only
(Cisco, EtherSwitch Network Module: `show vlan-switch brief` -> `1 default active Fa0/2,
Fa0/9, Fa0/14, Gi0/0`). `show vlan` walked every interface on every device, so a router
printed its routed sockets as members of VLAN 1: Gi0/0, Gi0/1, Gi0/2.

Membership now uses the same predicate `Device.inactiveVlan()` already uses: a box that
does not bridge has no VLAN for a port to be in. Switches are untouched. The table itself
stays, because whether a router answers `show vlan` at all is per platform and the
catalogue has no switch-module flag to ask (research/vlan-on-a-router.md).

test/show-vlan-router-ports.test.js: 15 assertions.
jaylouisw force-pushed rev/1117-1331 from acbc1456b7
All checks were successful
CI / Classify the change (pull_request) Successful in 8s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 14s
CI / Server smoke test (pull_request) Successful in 7s
CI / Docker build (pull_request) Successful in 22s
CI / Test (Node 20) (pull_request) Successful in 50s
CI / Test (Node 22) (pull_request) Successful in 52s
CI / Test (Node 18) (pull_request) Successful in 57s
CI / Arm auto-merge (pull_request) Successful in 6s
to 1f6472591b
Some checks failed
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 8s
CI / Classify the change (pull_request) Failing after 13m48s
CI / Test (Node 18) (pull_request) Has been cancelled
CI / Test (Node 20) (pull_request) Has been cancelled
CI / Test (Node 22) (pull_request) Has been cancelled
CI / Server smoke test (pull_request) Has been cancelled
CI / Docker build (pull_request) Has been cancelled
CI / Arm auto-merge (pull_request) Has been cancelled
2026-11-17 13:48:22 +00:00
Compare
jaylouisw force-pushed rev/1117-1331 from 1f6472591b
Some checks failed
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 8s
CI / Classify the change (pull_request) Failing after 13m48s
CI / Test (Node 18) (pull_request) Has been cancelled
CI / Test (Node 20) (pull_request) Has been cancelled
CI / Test (Node 22) (pull_request) Has been cancelled
CI / Server smoke test (pull_request) Has been cancelled
CI / Docker build (pull_request) Has been cancelled
CI / Arm auto-merge (pull_request) Has been cancelled
to 6cf55ca918
All checks were successful
CI / Classify the change (pull_request) Successful in 10s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 8s
CI / Server smoke test (pull_request) Successful in 8s
CI / Docker build (pull_request) Successful in 23s
CI / Test (Node 20) (pull_request) Successful in 48s
CI / Test (Node 22) (pull_request) Successful in 52s
CI / Test (Node 18) (pull_request) Successful in 56s
CI / Arm auto-merge (pull_request) Successful in 17s
2026-11-17 13:51:07 +00:00
Compare
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jaylouisw/packetforge!1851
No description provided.