Dell Networking S serie: Basic Interface Configuration - SONIC 4.0
Samenvatting: De basisbeginselen van de SONIC 4.0-interface configureren.
Instructies
Bij deze stappen wordt ervan uitgegaan dat de switch wordt geconfigureerd, te beginnen met de fabrieksinstellingen als een zelfstandige eenheid. Raadpleeg het gekoppelde Knowledge Base-artikel voor de schriftelijke voorbeelden.
In native indeling worden SONIC front panel interfaces genoemd van Ethernet 0 naar Ethernet X, waarbij X de laatste poort op het voorpaneel is. Standaardnaamgeving gebruikt de Ethernet x/y/z-modus, waarbij x/y de slot/poort #s en z wordt gebruikt voor breakout-poorten.
Indelingswijziging interfacenaamgeving: De standaard interfacenaamgevingsmodus wijzigen van Native naar Standard.
- Start vanaf de Linux-prompt de SONIC CLI met "sonic-cli":
admin@sonic:~$ sonic-cli
sonic#
- De interfacestatusmodus weergeven die momenteel is geconfigureerd met "show interface-naming"
sonic# show interface-naming
Interface naming mode is native
sonic#
- De interfacestatus weergeven en de standaard interface-naamgevingsconventie (Native naming) 'show interface status' (Afbeelding 1) weergeven:
Afbeelding 1: voorbeeld van interfacestatus weergeven.
- Als u de switchconfiguratie wilt wijzigen, voert u de opdracht "configure terminal" uit.
sonic# configure terminal
sonic(config)#
- Als u de interfacenaamgevingsmodus wilt wijzigen in de standaardmodus, gebruikt u de opdracht "interface-naming standard":
sonic(config)# interface-naming standard
Broadcast message: Interface naming mode has changed. Users running 'sonic-cli' are required to restart your session.
sonic(config)#
OPMERKING: SONIC CLI moet worden afgesloten en opnieuw worden ingevoerd door alle gebruikers om de moduswijziging van kracht te laten worden. te installeren.
- Sluit de configuratiemodus af met "exit":
sonic(config)# exit
sonic#
- Sluit SONIC CLI af met "exit":
sonic# exit
admin@sonic:~$
- Ga opnieuw naar SONIC CLI met "sonic-cli":
admin@sonic:~$ sonic-cli
sonic#
- Interfacestatus weergeven met "show interface status":
sonic# show interface status
Let op de wijziging in interfacenamen van Ethernet X naar Eth x/y (
Afbeelding 2).
Afbeelding 2: Standaardmodus: voorbeeld van interfacestatus weergeven
- Sla de actieve configuratie op in de opstartconfiguratie met "schrijfgeheugen":
sonic# write memory
sonic#
Individuele interfaceconfiguratie: Ga naar de configuratiemodus en ga vervolgens naar de interfaceconfiguratiemodus.
- Start SONiC CLI met "sonic-cli":
admin@sonic:~$ sonic-cli
sonic#
- De interfaceconfiguratie weergeven met "show running-configuration interface Eth 1/30":
sonic# show running-configuration interface Eth 1/30
!
interface Eth1/30
mtu 9100
speed 25000
fec none
shutdown
- Ga naar de configuratiemodus met "configure terminal":
sonic# configure terminal
sonic(config)#
- Ga naar de configuratiemodus van interface Eth 1/30 met "interface Eth 1/30":
sonic(config)# interface Eth 1/30
sonic(conf-if-Eth1/30)#
- Geen shut interface Eth 1/30 met "no shutdown":
sonic(conf-if-Eth1/30)# no shutdown
sonic(conf-if-Eth1/30)#
- Configureer een IP-adres op interface Eth 1/30 met "IP-adres 10.1.1.2/24":
sonic(conf-if-Eth1/30)# ip address 10.1.1.2/24
sonic(conf-if-Eth1/30)#
- Sluit de configuratiemodus af met "end":
sonic(conf-if-Eth1/30)# end
sonic#
- De interfaceconfiguratie weergeven met "show running-configuration interface Eth 1/30":
sonic# show running-configuration interface eth 1/30
!
interface Eth1/30
mtu 9100
speed 25000
fec none
no shutdown
ip address 10.1.1.2/24
- IP-interfaces weergeven met "show ip interfaces":
sonic# show ip interfaces
Flags: U-Unnumbered interface, A-Anycast IP
-----------------------------------------------------------------------------------------------
Interface IP address/mask VRF Admin/Oper Flags
-----------------------------------------------------------------------------------------------
Eth1/30 10.1.1.2/24 up/up
sonic#
- Interfacestatus weergeven voor Eth 1/30 "show interface eth 1/30":
(output truncated for brevity)
sonic# show interface eth 1/30
Eth1/30 is up, line protocol is up
Hardware is Eth
IPV4 address is 10.1.1.2/24
Mode of IPV4 address assignment: MANUAL
Mode of IPV6 address assignment: not-set
Interface IPv6 oper status: Disabled
IP MTU 9100 bytes
LineSpeed 25GB, Auto-negotiation off
FEC: DISABLED
Last clearing of "show interface" counters: never
…
- Sla de actieve configuratie op in de opstartconfiguratie met "schrijfgeheugen":
sonic# write memory
sonic#
Configuratie van mutliple-interface: Als u meerdere interfaces tegelijk wilt configureren, gebruikt u de optie 'interfacebereik'. Om een reeks interfaces weer te geven met een show-opdracht, is het trefwoord 'range' niet nodig.
Voorbeeld:
- Als u een opeenvolgende reeks poorten 14 tot en met 15 wilt configureren, is dat "interfacebereik Ethernet 1/1/14-1/1/15".
- Als u een niet-condensief bereik van poorten 3,10,19 wilt configureren, is dit "interfacebereik Ethernet 3,10,19".
- Voor het configureren van een combinatie van opeenvolgende en niet-consecutieve zou "interfacebereik Ethernet 1/1/3, 1/1/14-1/1/15" zijn.
- Om meerdere interfaces weer te geven, is de optie 'bereik' niet nodig. Om Ethernet 1/1-1/3,1/5 weer te geven, gebruikt u de opdracht "show interface Eth 1/1-1/3,1/5":
(output truncated for brevity)
sonic# show interface Eth 1/1-1/3,1/5
Eth1/1 is down, line protocol is down, reason admin-down
Hardware is Eth, address is 0c:02:22:c7:00:08
Mode of IPV4 address assignment: not-set
...
Output statistics:
0 packets, 0 octets
0 Multicasts, 0 Broadcasts, 0 Unicasts
0 error, 0 discarded, 0 Oversize
Eth1/2 is down, line protocol is down, reason admin-down
Hardware is Eth, address is 0c:02:22:c7:00:08
Mode of IPV4 address assignment: not-set
...
Output statistics:
0 packets, 0 octets
0 Multicasts, 0 Broadcasts, 0 Unicasts
0 error, 0 discarded, 0 Oversize
Eth1/3 is down, line protocol is down, reason admin-down
Hardware is Eth, address is 0c:02:22:c7:00:08
Mode of IPV4 address assignment: not-set
...
Output statistics:
0 packets, 0 octets
0 Multicasts, 0 Broadcasts, 0 Unicasts
0 error, 0 discarded, 0 Oversize
Eth1/5 is down, line protocol is down, reason admin-down
Hardware is Eth, address is 0c:02:22:c7:00:08
Mode of IPV4 address assignment: not-set
...
Output statistics:
0 packets, 0 octets
0 Multicasts, 0 Broadcasts, 0 Unicasts
0 error, 0 discarded, 0 Oversize
sonic(config)# end
- Voer de opdracht "configure terminal" uit.
sonic# configure terminal
sonic(config)#
- Configureer interfaces Ethernet 1/1-1/3, 1/5,/1/7-1/9 met behulp van "interfacebereik Eth1/1-1/3,1/5,1/7-1/9":
sonic(config)# interface range eth 1/1-1/3,1/5,1/7-1/9
%Info: Configuring only existing interfaces in range
sonic(conf-if-range-eth**)#
- Configureer interfaces 'no shut' met 'no shut':
sonic(conf-if-range-eth**)# no shutdown
sonic(conf-if-range-eth**)#
- Configureer interfaces voor toegangsmodus vlan 1 met "switchport access vlan 1":
sonic(conf-if-range-eth**)# switchport access vlan 1
sonic(conf-if-range-eth**)#
- Controleer de gebruikersconfiguratie met behulp van "show interface status" (Afbeelding 3):
OPMERKING: De kolommen Oper en Reason hebben de status voor het bereik van geconfigureerde interfaces gewijzigd.
Afbeelding 3: Voorbeeld van interfacestatus weergeven
- Controleer VLAN 1-interfacetoewijzingen met "show vlan 1" (Afbeelding 4):
Afbeelding 4: Voorbeeld van vlan 1 weergeven
- Sla de actieve configuratie op in de opstartconfiguratie met "schrijfgeheugen":
sonic# write memory
sonic#
Raadpleeg voor meer hulp de
Dell Technologies Enterprise SONiC-gebruikershandleiding releasedocumentatie of neem contact op met de technische support van Dell Technologies.