VMkernel default route gets removed after reboot when the service console uses an IP address acquired via DHCP. With S/W iSCSI enabled, Loss of access to iSCSI targets will occur upon reboot

Details

Service console IP address is set to DHCP
 
vmkernel default route is set to 0.0.0.0 after reboot of ESX server
 
Failed to establish connection to iscsi targets, vmkernel logs the following errors
iSCSI: bus 0 target 0 trying to establish session 0x6943af8 to portal 0, address xx.xx.xx.xx port
iSCSI: session 0x6943af8 to iqn.YYY-MM.com.array:sn.50412358 failed to connect, rc -5, I/O error
iSCSI: session 0x6943af8 connect failed at xxxx
 

 
 

Solution

The service console IP Address is setup for DHCP, which is supported for ESX .3.0.X
i.e.
#esxcfg-vswif -l
Name     Port Group          IP Address       Netmask          Broadcast        Enabled   DHCP
vswif0   Service Console     10.16.158.55     255.255.255.0    10.16.158.255    true      true  
or query the file  
#less -S /etc/sysconfig/network-scripts/ifcfg-vswif0  
DEVICE=vswif0
BOOTPROTO=dhcp
ONBOOT=yes
PORTGROUP=portgroup0
MACADDR=00:50:56:41:15:a4
the esx server is configured for S/W iSCSI  
ie.  
#esxcfg-vswitch -l
Switch Name    Num Ports   Used Ports  Configured Ports  Uplinks
vSwitch0       32          3           32                vmnic0

  PortGroup Name      Internal ID    VLAN ID  Used Ports  Uplinks
  VM Network          portgroup1     0        0           vmnic0
  Service Console     portgroup0     0        1           vmnic0

Switch Name    Num Ports   Used Ports  Configured Ports  Uplinks
vSwitch1       64          2           64                vmnic1

  PortGroup Name       Internal ID    VLAN ID  Used Ports  Uplinks
  VMkerneliSCSI           portgroup2     0        1           vmnic1
  
   
   
This is the static vmkernel IP address, i.e.  
   
# esxcfg-vmknic -l
Port Group          IP Address      Netmask         Broadcast       MAC Address       MTU     Enabled
VMkernel            10.16.156.141   255.255.255.0   10.16.156.255   00:50:56:69:2f:04 1514    true=  
   
the default VMkernel route is set either via the VI client or via command line  
   
#esxcfg-route -a default 10.16.156.254  
   
#esxcfg-route
VMkernel default gateway is 10.16.156.254  
   
The file /etc/sysconfig/network has not changed or appended to   
#cat /etc/sysconfig/network
NETWORKING=yes
GATEWAYDEV=vswif0
HOSTNAME=myhost.localdomain  
   
Reboot the ESX server  
   
When checking the default g/w again, it will be blank  
   
#esxcfg-route
VMkernel default gateway is 0.0.0.0  
   
Trying to restore the g/w we get an error

# esxcfg-route -r
Error: Unable to get COS default route  
   
   
Workaround:  
Set the vmkernel default gatway manually on /etc/sysconfig/network file  
Login to your ESX console use an editor such as vi or "nano"   
add the entry GATEWAY=XXX.XXX.XXX.XXX  
   
i.e. cat /etc/sysconfig/network  
NETWORKING=yes
GATEWAYDEV=vswif0
HOSTNAME=vchost2.localdomain
GATEWAY=10.16.156.254  
   
Now after a reboot the vmkernel g/w is retained  
   
There is a bug opened with relation to this issue, which is scheduled to be fixed on esx 3.0.3  
   
   Based on VMware KB 1002729
  • 0 Kasutajad peavad seda kasulikuks
Kas see vastus oli kasulik?

Seotud artiklid

Hardware and firmware requirements for 64-bit guest operating systems

PurposeThis article explains the host machine hardware and firmware requirements for installing...

Logging in to the vCenter Server 5.0 Web Client fails with the error: unable to connect to vCenter Inventory Service

DetailsAfter upgrading from vCenter Server 4.1 to 5.0, you experience these symptoms:Cannot log...

Multiple network entries in vCenter Server 5.0.x after migrating virtual machines from a virtual switch to a virtual distributed switch

SymptomsAfter migrating virtual machines from a virtual switch to a virtual Distributed...

Minimum requirements for the VMware vCenter Server 5.x Appliance

PurposeIf you are using the VMware vCenter Server Appliance, beginning with vSphere 5.0 you can...