Esx: Difference between revisions

From DWIKI
mNo edit summary
 
(7 intermediate revisions by the same user not shown)
Line 6: Line 6:
*[https://pubs.vmware.com/vsphere-51/topic/com.vmware.vcli.examples.doc/cli_manage_storage.6.6.html NFS on ESX]  
*[https://pubs.vmware.com/vsphere-51/topic/com.vmware.vcli.examples.doc/cli_manage_storage.6.6.html NFS on ESX]  
*[https://www.rootusers.com/how-to-increase-the-size-of-a-linux-lvm-by-adding-a-new-disk/ Adding a disk]  
*[https://www.rootusers.com/how-to-increase-the-size-of-a-linux-lvm-by-adding-a-new-disk/ Adding a disk]  
*[https://www.vmwareblog.org/disk-mode-esxi-vm-use/ Disk modes]
=Storage sense codes=
*[https://kb.vmware.com/s/article/289902?src=vmw_so_vex_rvand_702 interpreting scsi sense codes]  
*[https://kb.vmware.com/s/article/289902?src=vmw_so_vex_rvand_702 interpreting scsi sense codes]  
*[https://www.vmwareblog.org/disk-mode-esxi-vm-use/ Disk modes]
*[https://www.virten.net/vmware/vmware-esxi-scsi-sense-code-decoder-v2/ esxi scsi sense decoder]
Example: H:0x0 D:0x2 P:0x0 Valid sense data: 0x5 0x24 0x0
*H: host status
*D: device status
*P: plugin status
Sense data:
*Sense key
*Additional sense data
 


= Tools =
= Tools =
Line 18: Line 30:
*[https://kb.vmware.com/s/article/1027901 Checking the queue depth of the storage adapter and the storage device]
*[https://kb.vmware.com/s/article/1027901 Checking the queue depth of the storage adapter and the storage device]


=HOWTO=
==memory usage==
vsish -e get /memory/comprehensive


memstats -r group-stats -g0 -l5 -s gid:name:parGid:nChild:min:max:minLimit:conResv:availResv:memSize -u mb 2> /dev/null | sed -n '/^-\+/,/.*\n/p' | awk 'NR == 2 || $2 ~ /(vim|vimuser|terminal|ssh)$/ {print $0}'
vsish -e get /sched/groups/767/memAllocationInMB
Set new limit
vsish -e set /sched/groups/767/memAllocationInMB max=1200
==list installed vibs==
esxcli software vib list


= FAQ =
= FAQ =
Line 40: Line 66:
  esxcfg-info
  esxcfg-info
        
        
== Identify disks in Linux ==
 
== Identify disks in Linux guest==
 
  lsscsi
  lsscsi
== Check if vmdk is in use ==
grep vmdk some.vmx
https://blah.cloud/infrastructure/safely-checkremove-orphaned-vmdk-files-from-esxi/
  vmkfstools -D foo.vmdk
 


== list modules ==
== list modules ==


  esxcli system module list
  esxcli system module list
==ESXi login locked==
pam_tally2 --user root
and
pam_tally2 --user root --reset

Latest revision as of 14:38, 21 March 2024


Links

Storage sense codes

Example: H:0x0 D:0x2 P:0x0 Valid sense data: 0x5 0x24 0x0

  • H: host status
  • D: device status
  • P: plugin status

Sense data:

  • Sense key
  • Additional sense data


Tools

esxtop

Links

HOWTO

memory usage

vsish -e get /memory/comprehensive
memstats -r group-stats -g0 -l5 -s gid:name:parGid:nChild:min:max:minLimit:conResv:availResv:memSize -u mb 2> /dev/null | sed -n '/^-\+/,/.*\n/p' | awk 'NR == 2 || $2 ~ /(vim|vimuser|terminal|ssh)$/ {print $0}'


vsish -e get /sched/groups/767/memAllocationInMB

Set new limit

vsish -e set /sched/groups/767/memAllocationInMB max=1200


list installed vibs

esxcli software vib list

FAQ

start VM

List all vms

vim-cmd vmsvc/getallvms
vim-cmd vmsvc/power.getstate [vmid]
vim-cmd vmsvc/power.off [vmid]
vim-cmd vmsvc/power.on [vmid]

root account locked

pam_tally2 --user root --reset

show hardware info

esxcfg-info
      

Identify disks in Linux guest

lsscsi

Check if vmdk is in use

grep vmdk some.vmx

https://blah.cloud/infrastructure/safely-checkremove-orphaned-vmdk-files-from-esxi/

 vmkfstools -D foo.vmdk


 

list modules

esxcli system module list


ESXi login locked

pam_tally2 --user root

and

pam_tally2 --user root --reset