Management Port
此内容尚不支持你的语言。
By default, the management port (mgmt 0) of the switch does not have an IP address when shipped from factory. It can automatically obtain IP address through DHCP by connecting the management port to DHCP Server on the same network segment. At the same time, AsterNOS supports users to manually configure the management port IP, which can only have one IPv4 address and one IPv6 address. Multiple configurations will be overwritten.
Management Port View
Section titled “Management Port View”Table 1 Management Port View
| Command | Purpose |
|---|---|
| show interface mgmt | Display management port configuration. |
show interface mgmt
Section titled “show interface mgmt”[Command]
show interface mgmt
[Purpose]
Display management port configuration.
[View]
Privileged User View
[Use Cases]
sonic# show interface mgmtManagement IP address = 10.250.0.138/24Management Network Default Gateway = 10.250.0.254Management Port Config
Section titled “Management Port Config”Table 2 Management Port Config
| Command | Purpose |
|---|---|
| interface mgmt 0 | Enter Management Port Configuration View. |
| ip address A.B.C.D/M [gw A.B.C.D] | Configure or modify the IPv4 address and gateway of the management port. |
| **ipv6 address ** [A::B/M gw A::B] | Configure or modify the IPv6 address and gateway of the management port. |
interface mgmt 0
Section titled “interface mgmt 0”[Command]
interface mgmt 0
[Purpose]
Enter Management Port Configuration View
[View]
Global Configuration View
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0ip address A.B.C.D/M [gw A.B.C.D]
Section titled “ip address A.B.C.D/M [gw A.B.C.D]”[Command]
ip address A.B.C.D/M [gw A.B.C.D]
[Purpose]
Configure or modify the IPv4 address and gateway of mgmt.
[Parameters]
| Parameter | Description |
|---|---|
| A.B.C.D/M | IPv4 address with prefix length. |
| A.B.C.D | (Optional) IPv4 gateway address without prefix length. |
[View]
Management Port Configuration View
[Notes]
IPv4 address with subnet mask /32 is not allowed to be configured. Addresses with subnet mask /31 is allowed. In other subnet masks, addresses with the host portion all-zeros or all-ones are not allowed. Run command no ip address A.B.C.D/M [gw A.B.C.D] to delete IPv4 address configuration of mgmt.
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0sonic(config-mgmt-0)# ip address 10.250.0.103/24 gw 10.250.0.254ipv6 address A::B/M [gw A::B]
Section titled “ipv6 address A::B/M [gw A::B]”[Command]
ipv6 address A::B/M [gw A::B]
[Purpose]
Configure or modify the IPv6 address and gateway of mgmt.
[Parameters]
| Parameter | Description |
|---|---|
| A::B/M | IPv6 address with prefix length. |
| A::B | (Optional) IPv6 gateway address without prefix length. |
[View]
Management Port Configuration View
[Notes]
IPv6 address with subnet mask /127 or /128 is not allowed to be configured. In other subnet masks, addresses with the host portion all-zeros are not allowed, but all-ones are allowed. Run command no ip address A.B.C.D/M [gw A.B.C.D] to delete IPv6 address configuration of mgmt.
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0sonic(config-mgmt-0)# ipv6 address 2013::138/64 gw 2013::1