访问VMware ESXi的方式
1.vSphere Client for Windows (VMware-viclient-all-6.0.0.exe), it is only available for Windows systems and it is not available for Linux systems.
2.vSphere Remote Command Line (VMware-vSphere-Perl-SDK-6.0.0-2503617.x86_64.tar.gz)
3.vEMan (http://sourceforge.net/projects/veman/),An unofficial VMware ESX/ESXi Manager for Linux
4.Accessing the vSphere Web Client from a Linux desktop (https://192.168.99.145/vsphere-client/), it relies on Adobe Flash, and extensions. but Flash is going away.
5.vCenter or Soap Web Service API
6.Embedded HTML5 Host Client, https://labs.vmware.com/flings/esxi-embedded-host-client
安装Embedded HTML5 Host Client
1,在ESXi开机界面按F2键进入打开SSH支持
2,通过SSH登录进EXSi后支持下列命令安装Embedded HTML5 Host Client
[root@localhost:~] esxcli software vib install -v http://download3.vmware.com/software/vmw-tools/esx
ui/esxui_signed.vib
Installation Result
Message: Operation finished successfully.
Reboot Required: false
VIBs Installed: VMware_bootbank_esx-ui_0.0.2-0.1.3357452
VIBs Removed:
VIBs Skipped:
3,OK, 访问:https://192.168.99.145/ui
VMWare相关理论知识
VMWare产品介绍:
1.vSphere,服务器虚拟化。既包括虚拟化产品EXSi,也包括多台ESXi的管理程序vCenter。
2.VMware Station, 工作站虚拟化
3.VMware View, 桌面虚拟化,所有的虚机在数据中心统一管理,客户端通过远程桌面使用
4.VMware vCloud Express, VMware公有云
5.VMware vCloud Director, VMware私有云
6.VMforce,VMware PaaS云
ESXi应该部署在裸机上,当然,测试时也可以部署在VMware Station虚机里。
vCenter用来管理多台ESXi, 每台ESXi上安装vCenter Agent,这样vCenter可以收集管理和性能信息,这样vCenter可以指示协助执行诸如vMotion和HA这类高级功能。vCenter提供的功能有:
1.资源和虚拟机的清单发现功能,列出这个vCenter的管理域内所有的资源(如存储,网络,CPU和存存)和虚拟机
2.任务调度
3.日志管理
4.警告和事件管理
5.虚拟机部署
6.主机和虚拟机的设置
7.动态迁移,vMotion
8.资源优化DRS, 将虚拟机调度到合适的位置
9.分布式电源管理DPM, 在DRS的基础上整合虚拟机来减少和关闭多余的主机,以达到节省资源的目的
10.安全,VMsafe API像X射线那样检测虚拟机的安全情况。VMware Shield Zones防火墙,监视记录和阻止vSphere主机内部或集群中虚拟机之间的流量,从而保证网络的安全
11.容错, VMware Fault Tolerace),即VM HA,为HA创建虚拟机副本,并保持两台虚拟机之间的同步,来保证应用的零宕机和零数据丢失。
12.VMware HA, 通过心跳检测虚拟机的运行状况,如果一台虚拟机宕机了,迁移到其他主机
13.备份,备份虚拟机
14.应用部署,使用基于OVF协议的vAPP包。类似于PaaS的功能。
vSphere Remote Command Line的安装使用
sudo apt-get -y install libwebkitgtk-1.0-0 libwebkitgtk-3.0-0
sudo apt-get vncviewer libxml-libxml-perl perl-doc
tar -xvzf VMware-vSphere-Perl-SDK-6.0.0-2503617.x86_64.tar.gz
cd vmware-vsphere-cli-distrib && sudo ./vmware-install.pl
命令演示:
hua@node1:~$ vmware-cmd -H 192.168.99.145 -U root -P password -l
/vmfs/volumes/5693a9fe-148e3e6c-cc49-000c29728f7e/openstack/openstack.vmx
hua@node1:~$ esxcli -s 192.168.99.145 -u root -p password --thumbprint 87:E9:53:4E:31:DE:84:2F:2C:45:76:77:6E:71:E1:FA:C7:78:4C:30 network ip connection list|head
Proto Recv Q Send Q Local Address Foreign Address State World ID CC Algo World Name
----- ------ ------ ------------------------------ -------------------- ----------- -------- ------- ---------------
tcp 0 0 127.0.0.1:8307 127.0.0.1:40432 ESTABLISHED 34097 newreno hostd-worker
tcp 0 0 127.0.0.1:40432 127.0.0.1:8307 ESTABLISHED 33828 newreno rhttpproxy-work
tcp 0 0 192.168.99.145:443 192.168.99.124:54652 ESTABLISHED 33830 newreno rhttpproxy-work
tcp 0 0 127.0.0.1:8307 127.0.0.1:62552 ESTABLISHED 35474 newreno hostd-worker
tcp 0 0 127.0.0.1:62552 127.0.0.1:8307 ESTABLISHED 33830 newreno rhttpproxy-work
tcp 0 0 127.0.0.1:80 127.0.0.1:16211 ESTABLISHED 33828 newreno rhttpproxy-work
tcp 0 0 127.0.0.1:16211 127.0.0.1:80 ESTABLISHED 35275 newreno sfcb-vmware_bas
tcp 0 0 127.0.0.1:5988 127.0.0.1:30679 FIN_WAIT_2 35136 newreno sfcb-HTTP-Daemo
close failed in file object destructor:
Error in sys.excepthook:
Original exception was:
hua@node1:~$ vmware-cmd -H 192.168.99.145 -U root -P password "/vmfs/volumes/5693a9fe-148e3e6c-cc49-000c29728f7e/openstack/openstack.vmx" start
安装VMware Workstation
sudo apt-get install libcanberra-gtk-module:i386
sudo ./VMware-Workstation-Full-12.1.0-3272444.x86_64.bundle
Troubleshooting
1,failed to extend swap file vmware esxi
因为内存值设置大了
2, PXE-MOF:Exiting intel PXE ROM.Operating system not found
要将光驱改为加电时启动,将网卡改成加电时不启动
3,tls 1.0 fallback
firefox: about:config中设置security.tls.version.fallback-limit=1
chromium: chromium-browser --ssl-version-min=tls1 &