使用VMware PowerCLI给ESXi 7.0以上版本官方安装包添加community板载网卡、usb网卡驱动
- 安装VMware PowerCLI
 - 
    
- 下载VMware PowerCLI离线安装包(已经包含所需依赖)
 - 将zip包解压到
C:\Program Files\WindowsPowerShell\Modules文件夹 - 在
C:\Program Files\WindowsPowerShell\Modules目录下,shift+右键,打开powershell - 在powershell中执行下面命令,解除文件限制
        
Get-ChildItem * -Recurse | Unblock-File - 右键左下角windows微标,以管理员身份运行powershell,在新打开的powershell执行命令
        
Set-ExecutionPolicy RemoteSigned - 执行下面命令查看安装是否成功,不报错就是安装成功了
        
Import-Module VMware.ImageBuilder 
 
ESXi和PowerCLI都经常小版本更新,在制作iso的过程中两者版本必须对应,可以到这里找到最新的PowerCLI离线安装包
- 下载ESXi和Community驱动
 - 
    
- 首先你需要注册一个VMware账户
 - 打开产品下载页面,找到
VMware vSphere Hypervisor (ESXi),点击Download Trial - 在新弹出来的页面,选择
VMware vSphere Hypervisor (ESXi) Offline Bundle下载,注意不是下载ISO - 到这里下载Community Networking Driver for ESXi
 - 到这里下载USB Network Native Driver for ESXi
 - 将下载好的文件复制到一个文件夹放好
 
 - 打包ISO文件
 - 
    
- 进入存放下载文件的文件夹,
shift+右键打开powershell - 执行下面命令,注意根据自己下载的压缩包的文件名修改下面
Add-EsxSoftwareDepot命令后面的文件名Add-EsxSoftwareDepot .\VMware-ESXi-7.0U3c-19193900-depot.zip Add-EsxSoftwareDepot .\Net-Community-Driver_1.2.7.0-1vmw.700.1.0.15843807_19480755.zip Add-EsxSoftwareDepot .\ESXi703-VMKUSB-NIC-FLING-51233328-component-18902399.zip - 运行下面命令,找到目前版本对应的profile
        
Get-EsxImageProfile - 复制包含
standard的profile名称,如我这里是ESXi-7.0U3c-19193900-standard - 运行命令创建自定义profile,注意
-CloneProfile "ESXi-7.0U3c-19193900-standard"需要修改成上面复制的名称,-name后面跟的为创建的新profile的名子New-EsxImageProfile -CloneProfile "ESXi-7.0U3c-19193900-standard" -name "ESXi-7.0U3c-19193900-bigppwong" -Vendor "bigppwong.github.io" - 添加驱动包到上面创建的profile
        
Add-EsxSoftwarePackage -ImageProfile "ESXi-7.0U3c-19193900-bigppwong" -SoftwarePackage "net-community" - 输出ISO包
        
Export-ESXImageProfile -ImageProfile "ESXi-7.0U3c-19193900-bigppwong" -ExportToISO -filepath ESXi-7.0U3c-19193900-bigppwong.iso 
 - 进入存放下载文件的文件夹,
 
如果想删除profile可以用Remove-EsxImageProfile命令
      
    
      
留下评论