De Wiki inetshell
Revisión del 18:42 28 mar 2018 de Adminwiki (discusión | contribuciones)
(dif) ← Revisión anterior | Revisión actual (dif) | Revisión siguiente → (dif)
Saltar a: navegación, buscar

ESXi es el hipervisor de VMWARE.

Montar USB en host ESX por Shell

Note: You still need to disable the USB arbitrator service for ESXi to see the USB device before you can read from it.

 /etc/init.d/usbarbitrator stop
 esxcli storage core device list | grep -i usb
 esxcli storage filesystem list


Copy a file from USB device to ESXi host:

 /bin/mcopy -i "/dev/disks/${USB_KEY}:2" ::/MyFile /tmp/MyFile

Copy a file from ESXi host to USB device:

 /bin/mcopy -i "/dev/disks/${USB_KEY}:2" /tmp/MyFile ::/MyFile


Copy a file from USB device to ESXi host:

 /bin/ntfscat -f /dev/disks/${USB_KEY}:2 MyFile > /tmp/MyFile

One limitation that I did come across when using FAT32 on a USB device is that the maximum file size is <=2GB. If you need to transfer larger files from the USB device, you would need to chunk it up and re-construct the file on the ESXi host. One neat trick that I learned from my buddy Timo Sugliani is that you could use the split command which can be found on a Mac OS X or Linux system to break up the original file into smaller chunks. You can then re-construct the original file by simply using the cat command which is available in the ESXi Shell.

Here is the syntax for splitting a file into 1GB chunks:

 split -b 1073741824 FILE-TO-BE-SPLIT

Here is the syntax for rebuilding the individual chunks into the original file:


Hopefully these scenarios is not something you would need to frequently do in your environment, but in case you do, there are some additional options beyond FAT16

[Copying files from a USB (FAT32 or NTFS) device to ESXi]

[How to Access USB Storage in ESXi Shell ]

Apagar una VM desde esxcli

If you want to power off or kill a virtual machine running on an ESXi host you can do this using the following esxcli command:

  • connect a console to your ESXi host (eg. SSH or ESXi Shell)

To get a list of all VMs running on the host use this command:

   esxcli vm process list

The list contains: World ID, Process ID, VMX Cartel ID, UUID, display name and the path to the vmx config file.

  • To kill / power off the virtual machine use the following command:
   esxcli vm process kill -type=xxxx  world-id=yyyyy

for -type=xxxx use: soft, hard or force

for world-id=yyyy use the World ID listed in the command above (eg. World ID 39731 for the example VM “Cold”)

Some information about the three possible shutdown methods:

soft = prefer this if you want to shut down “softly”

hard = equal to an immediate shutdown

force = hard kill of the VM

[How to – kill / power off a virtual machine using esxcli command]

Apagar una VM desde esxtop


Habilitar SSH en ESXi 5.1


Error de SSL

“The request was aborted: Could not create SSL/TLS secure channel.” Error when connecting to vCenter Server through the vSphere Client (2147546)

Conectar a VMWare vShere Client con mediante tunel SSH

  • Puertos
    • 443
    • 902
    • 903
  • Escribir en hosts
    • esxlocal


Reiniciar servicios de ESX

 ./etc/init.d/hostd restart

Restaurar clave de root