読者です 読者をやめる 読者になる 読者になる

labunix's blog

labunixのラボUnix

Windows7(64bit版)にvmplayer6を導入する

■Windows7(64bit版)にvmplayer6を導入する。
 vmplayer.exe自体は32bit。
 コマンドプロンプトから。

> systeminfo | find "OS Name"
OS Name:                   Microsoft Windows 7 Professional

> explorer "https://my.vmware.com/jp/web/vmware/free#desktop_end_user_computing/vmware_player/6_0|PLAYER-601|product_downloads"

> VMware-player-6.0.1-1379776.exe
> VMware-VIX-1.13.1-1379776.exe

■VMware Playerのインストール時に再起動をスキップしたなら、OSを再起動

> shutdown -r -t 0

■ポート転送をするなら、
 vmplayer5以降は、「vmnetcfg.exe」の代わりに「vmnetnat.conf」を設定。

> findstr /V "^# ^$" "c:\Users\All Users\VMware\vmnetnat.conf"
[host]
ip = 192.168.118.2/24
hostMAC = 00:50:56:C0:00:08
device = VMnet8
activeFTP = 1
allowAnyOUI = 1
resetConnectionOnLinkDown = 1
resetConnectionOnDestLocalHost = 1
[tcp]
timeWaitTimeout = 30
[udp]
timeout = 30
[dns]
policy = order
timeout = 2
retries = 3
autodetect = 1
[netbios]
nbnsTimeout = 2
nbnsRetries = 3
nbdsTimeout = 3
[incomingtcp]
[incomingudp]
[PrivilegedTCP]
autodetect = 1
[PrivilegedUDP]
autodetect = 1

■Linux版だと「nat.conf」

$ grep -v "^\$\|^#" /etc/vmware/vmnet8/nat/nat.conf
[host]
ip = 192.168.0.2
netmask = 255.255.255.0
device = /dev/vmnet8
activeFTP = 1
allowAnyOUI = 1
resetConnectionOnLinkDown = 1
resetConnectionOnDestLocalHost = 1
[tcp]
timeWaitTimeout = 30
[udp]
timeout = 60
[netbios]
nbnsTimeout = 2
nbnsRetries = 3
nbdsTimeout = 3
[incomingtcp]
[incomingudp]

■ポート転送の設定をしたらサービスの再起動

> sc query | find "NAME" | find "VM"
SERVICE_NAME: VMAuthdService
DISPLAY_NAME: VMware Authorization Service
SERVICE_NAME: VMUSBArbService
DISPLAY_NAME: VMware USB Arbitration Service
SERVICE_NAME: VMware NAT Service
DISPLAY_NAME: VMware NAT Service
SERVICE_NAME: VMnetDHCP
DISPLAY_NAME: VMware DHCP Service

> net start | find "VM"
   VMware Authorization Service
   VMware DHCP Service
   VMware NAT Service
   VMware USB Arbitration Service

> net stop "VMware NAT Service"
> net start "VMware NAT Service"

■結局vmplayer自体は32bit版なのか。

> cd /d "c:\Program Files (x86)\VMware\VMware VIX"
> vmrun -T player list
Total running VMs: 0
> cd "..\VMware Player"
> vmplayer.exe

■インストール情報の確認

> reg query "HKLM\Software\Microsoft\WIndows\CurrentVersion\Uninstall" /s | find "DisplayName" | find "VM"
    DisplayName    REG_SZ    VMware Player

> reg query "HKLM\Software\VMware, Inc." /s

HKEY_LOCAL_MACHINE\Software\VMware, Inc.\VMware Drivers
    vmci.status    REG_SZ    1|1.9.5.10.0.1|oem4.inf
    VmciHostDevInst    REG_SZ    ROOT\VMWVMCIHOSTDEV\0000
    vsockSys.status    REG_SZ    1|1.9.5.7.0.0|
    vsockDll.status    REG_SZ    1|1.9.5.1.0.0|

> driverquery /FO CSV | find "VMware"
"VMnetAdapter","VMware Virtual Ethernet Adapter Driver","Kernel ","2013/07/19 4:43:00"
"hcmon","VMware hcmon","Kernel ","2013/10/10 0:03:51"
"VMnetBridge","VMware Bridge Protocol","Kernel ","2013/07/19 4:43:47"
"VMnetuserif","VMware Network Application Interface","Kernel ","2013/10/19 3:19:38"
"VMparport","VMware VMparport","Kernel ","2013/10/19 2:58:11"
"vmkbd","VMware kbd","Kernel ","2013/10/19 3:50:26"
"vmx86","VMware vmx86","Kernel ","2013/10/19 4:34:39"
"vmci","VMware VMCI Bus Driver","Kernel ","2013/05/18 10:19:18"

■PowerShellならもう少しスマートに。

> powershell
PS> Get-WmiObject -Class Win32_Product | Select Name,Version |  Where-Object { $_ -match "vm"} | Format-List

Name    : VMware Player
Version : 6.0.1

Name    : VMware VIX
Version : 1.13.1.41495

PS> Get-WmiObject Win32_SystemDriver | Where-Object { $_ -match "vm"} | Format-List

DisplayName : Virtual Machine Bus
Name        : vmbus
State       : Stopped
Status      : OK
Started     : False

DisplayName : VMBusHID
Name        : VMBusHID
State       : Stopped
Status      : OK
Started     : False

DisplayName : VMware Virtual Ethernet Adapter Driver
Name        : VMnetAdapter
State       : Stopped
Status      : OK
Started     : False

DisplayName : VMware Bridge Protocol
Name        : VMnetBridge
State       : Running
Status      : OK
Started     : True

DisplayName : VMware Network Application Interface
Name        : VMnetuserif
State       : Running
Status      : OK
Started     : True

DisplayName : VMware VMparport
Name        : VMparport
State       : Running
Status      : OK
Started     : True

DisplayName : VMware kbd
Name        : vmkbd
State       : Stopped
Status      : OK
Started     : False

DisplayName : VMware vmx86
Name        : vmx86
State       : Running
Status      : OK
Started     : True

DisplayName : VMware VMCI Bus Driver
Name        : vmci
State       : Stopped
Status      : OK
Started     : False

PS> Get-WmiObject Win32_Service | Select DisplayName,Name,StartMode,State | Where-Object { $_ -match "vm"} | Format-List

DisplayName : VMware Authorization Service
Name        : VMAuthdService
StartMode   : Auto
State       : Running

DisplayName : VMware USB Arbitration Service
Name        : VMUSBArbService
StartMode   : Auto
State       : Running

DisplayName : VMware NAT Service
Name        : VMware NAT Service
StartMode   : Auto
State       : Running

DisplayName : VMware DHCP Service
Name        : VMnetDHCP
StartMode   : Auto
State       : Running