How to do the ESXi VMkernel PING: Unknown interface: Invalid argument

Over the years one of my favourite tool when troubleshooting network problems in the vSphere world was vmkping. It allows us to send an ICMP request based on a specified VMkernel port (perfect for troubleshooting vMotion/vXLAN problems).

With ESXCLI NETWORK DIAG PING a nice wrapper for the ping tool was implemented into the ESXCLI namespaces, so that we can use this command remote via vCLI oder even through the PowerCLI cmdlet.

Unfortunately in vSphere 6.0 the command doesn’t work anymore as it has been before (in case that you do NOT use the default networking stack). VXLAN, vMotion and Provisioning traffic can now be configured to use a seperate tcp/ip stack (dedicated routing/arp tables).

Once you use such a non-default-VMkernel port via ping or the according ESXCLI command you receive the following error:

Unknown interface ‘vmkX’: Invalid argument

Invalid Argument

To make it work again make sure to specify the networking stack.

esxcli network diag ping -I vmk2 –netstack=vmotion -H 192.168.119.63

VMkping suc

Take care since the stack parameter requires a case-sensitive input?

esxcli network diag ping -I vmk2 –netstack=vMotion -H 192.168.119.63

leads to

Got no data from process:
/bin/ping ++netstack=vMotion -S vMotion -I vmk2 -X 192.168.119.63

so better use the correct value out of the following command return:

esxcli network ip netstack list

netstack

–>

vxlan / vmotion or skip the entry for defaultTcpipStack

If you don’t like the ESXCLI method, just use the -S parameter in the good old vmkping

vmkping

 

3 thoughts on “How to do the ESXi VMkernel PING: Unknown interface: Invalid argument

  • 2. March 2017 at 13:52
    Permalink

    Hallo Fabian.

    Durch Zufall während des Troubleshooting auf Deine Seite gekommen.
    Der Tipp hat auch direkt geholfen !

    Dachte schon, ich wäre zu blöd den vMotion TCP/IP Stack zu bedienen :-)

    Vielen Dank Dir !!!

    Reply
    • 5. March 2017 at 21:18
      Permalink

      Sehr cool :) Freut mich immer zu hören!!

      Reply
  • 12. September 2017 at 18:03
    Permalink

    You can just do a vmkping -S vmotion -I vmkX IP

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.

This site uses Akismet to reduce spam. Learn how your comment data is processed.