VMware: Come migrare la porta VMkernel vmk0 da uno switch distribuito a uno switch standard
Summary: Questo articolo mostra come eseguire la migrazione di vmk0 da uno switch vDS a uno standard tramite la riga di comando.
This article applies to
This article does not apply to
This article is not tied to any specific product.
Not all product versions are identified in this article.
Instructions
Procedimento:
Procedura per migrare la porta VMkernel vmk0 da uno switch distribuito a uno standard:
- Raccogliere le informazioni IP per la porta VMkernel vmk0 corrente (indirizzo IP, netmask, gateway predefinito e VLAN).
- Rimozione di un
vmnicda uno switch distribuito corrente (vDS).- Ottenere l'ID porta di
vmnice vDS Name utilizzando il seguente comando:
- Ottenere l'ID porta di
esxcli network vswitch dvs vmware list
Di seguito è riportato un esempio di output, il cui nome è
dvSwitche l'ID porta per vmnic2 è 6171.
Figura 1. ID porta e nome vDS della vmnic
- Eseguire il seguente comando per rimuovere una vmnic da vDS:
esxcfg-vswitch -Q vmnic -V dvPort_ID_of_vmnic dvSwitch
Esempio:
esxcfg-vswitch -Q vmnic2 -V 6171 dvSwitch
- Eliminare il vmk0 corrente con il comando:
esxcli network ip interface remove --interface-name=vmk0
Se il coredump di rete è impostato su vmk0, disabilitarlo con il seguente comando:
esxcli system coredump network set --enable false
- Creare uno switch standard con il comando:
esxcli network vswitch standard add -v vSwitchName
Esempio:
esxcli network vswitch standard add -v vSwitch0(Crea un vSwitch con il nome vSwitch0).
- Creare un gruppo di porte a cui assegnare vmk0 con il comando:
esxcli network vswitch standard portgroup add -p portgroup_name -v vSwitch
Esempio:
esxcli network vswitch standard port group add -p management -v vSwitch0
(Crea un gruppo di porte denominato management su vSwitch0).
- Assegnare vmk0 al port group con il comando:
esxcli network ip interface add -i vmk0 -p portgroup_name
Esempio:
esxcli network ip interface add -i vmk0 -p management(Aggiunge
vmk0 su management Gruppo di porte.)
- Impostare l'indirizzo IP di vmk0 con il comando:
esxcli network ip interface ipv4 set -i vmk0 -I ipaddress -N netmask -t static
Esempio:
esxcli network ip interface ipv4 set -i vmk0 -I 10.1.1.10 -N 255.255.255.0 -t static(Impostare
vmk0 su 10.1.1.10 con maschera di rete 255.255.255.0 come static Indirizzo IP.)
- Impostare la VLAN per il gruppo di porte in cui risiede vmk0 con il comando:
esxcli network vswitch standard portgroup set -p portgroup -v VLAN
Esempio:
esxcli network vSwitch standard port group set -p management -v 10(Assegna VLAN
10 Al gruppo di porte management).
- Impostare il gateway predefinito per vmk0 con il comando:
esxcfg-route -a default defaultGW
Esempio:
esxcfg-route -a default 10.1.1.1(Impostare gateway predefinito su
10.1.1.1).
- Impostare vmk0 come gestione con il comando:
esxcli network ip interface tag add -i vmk0 -t Management
- Abilitare il dump del core di rete se è stato abilitato su vmk0 con il comando:
esxcli system coredump network set --enabled true
Affected Products
VxBlock and Vblock Systems, VMware ESXi 7.x, VMware ESXi 8.xArticle Properties
Article Number: 000206306
Article Type: How To
Last Modified: 22 Jul 2025
Version: 3
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.