Skip to content

opx config vlan

Amy Buck edited this page Feb 21, 2019 · 12 revisions

COMMAND

opx-config-vlan — Creates and deletes a VLAN, and configures various attributes of a VLAN.

SYNOPSIS

opx-config-vlan [-h,--help] 
{create | delete | set | add | remove}
[--id <id>] 
[--type (data | mgmt)] 
[--ports <port-list>] 
[--taggedports <port-list>]

OPTIONS

Option Description
-h,--help Displays help text
create Creates a new VLAN
delete Deletes an existing VLAN
set Sets the ports (blocked and unblocked) of a VLAN, to the given value(s)
add Adds blocked or unblocked port(s) to the port-list of a VLAN
remove Removes blocked or unblocked port(s) from the port-list of a VLAN
--id <id> Unique ID of the VLAN
--type (data | mgmt) List of VLAN types:
data — VLAN that carries data traffic
mgmt — VLAN that carries switch management traffic
--ports <port-list> List of front-panel Ethernet ports to configure as untagged ports; an untagged port accepts traffic for the associated VLAN only; it is also referred as an access port; <port-list> is a comma-separated list of single or a range of interfaces; each range is either a single interface, or a pair of interfaces of the form <from..to>, which specifies all interfaces from <from> to <to> inclusive. Examples:
e101-001-0 — expands to e101-001-0
e101-001-0,e101-010-0 — expands to e101-001-0,e101-010-0
e101-001-0,e101-004-0..e101-006-0 — expands to e101-001-0,e101-004-0,e101-005-0,e101-006-0
If the port list is not specified, all Ethernet front-panel ports are configured
--taggedports <port-list> List of front-panel Ethernet ports to configure as tagged ports; a tagged port accepts traffic for all VLANs; it is also referred as a trunk port; <port-list> is a comma-separated list of single or a range of interfaces; each range is either a single interface, or a pair of interfaces of the form <from..to>, which specifies all interfaces from <from> to <to> inclusive. Examples:
e101-001-0 — expands to e101-001-0
e101-001-0,e101-010-0 — expands to e101-001-0,e101-010-0
e101-001-0,e101-004-0..e101-006-0 — expands to e101-001-0,e101-004-0,e101-005-0,e101-006-0
If the port list is not specified, all Ethernet front-panel ports are configured

EXIT STATUS

If there is a syntax error in the given arguments, the exit status shall be 2.
If there is any other error, the exit status shall be 1.
Otherwise, the exit status is 0.

EXAMPLE

Create VLAN

$ opx-config-vlan create --id 101 --ports e101-002-0 --taggedports e101-003-0..e101-005-0

Set VLAN

$ opx-config-vlan set --id 101 --ports e101-003-0,e101-005-0

Delete VLAN

$ opx-config-vlan delete --id 101

REPORT BUGS

To report any OPX software bugs, see Report bugs.

SEE ALSO

opx-show-vlan

Clone this wiki locally