Vmware Esx Server - how to install VMware Infrastructure Client

VMware Infrastructure Client is a graphical tool to handle the virtual machines provided by the Esx server. It's quite cool but, surprise surprise, it's windows only. Let's see how can it run on linux.
![]()
Introduction
The aim of this roadmap is to show how to use Esx in a linux only environment. VMware Infrastructure Client [from now on VIC] is not an optional tool even if several, if not all, actions performed by vic can be done through the CLI or the ssh access. Unfortunately vic is windows only: that's a big deal.
The latest version of Esx, the 4.0, needs vic version 4.0; you can't connect with a previous version and this is really a pity.
To make short a long story, vic 2.5 (the client for Esx 3.5) works fine with wine while vic 4.0 aka Vsphere Client, can't work with wine because it requires to set up .Net 3.0 SP1. At the time of writing wine supports (bronze support) .Net 3.0 but fails on SP1.


So two options:
A) Esx server 4.0 without the VIC
B) Esx server 3.5 with the VIC
I picked the latter because the vic is very easy to use and handy even for technicians with few experience in virtual machines and vmware. So this is the reason why I wrote in the "installation howto" that I had to choose Esx 3.5.
Installation
Download Lucky me there are the packages for debian lenny and ubuntu hardy (I added the repository to the apt source list) and installed with
apt-get install wine
As I said vic requires a huge number of windows components like internet explorer and .Net : to install them into wine, a cool tool called winetricks comes in help (I took the latest version available from svn):
cd /usr/bin wget -c http://winezeug.googlecode.com/svn/trunk/winetricks chmod +x /usr/bin/winetricks
Winetricks helps a lot in the installation process of several wine add-ons. These is what I needed:
(make sure you are running a X session)
winetricks volnum winxp ie6 dotnet20
The installation process will download all the needed components from internet and sooner or later a windows like this will pop up exactly like in windows:

It will end in this way:
.... Install of dotnet20 done winetricks done.
Now it's time to install the vic. It can be downloaded from the web interface of the Esx server

to install:
wine VMware-viclient.exe
Vic can be loaded with:
wine ~/.wine/drive_c/Program Files/VMware/Infrastructure/Virtual Infrastructure Client/Launcher/VpxClient.exe
(if you have a locale different from en_US, substitute Program Files with what you have (Programmi in italian)
If you prefer you can use a script (as root)
cat >> /usr/bin/2v_start_vic << EOF #!/bin/bash wine ~/.wine/drive_c/Program\ Files/VMware/Infrastructure/Virtual\ Infrastructure\ Client/Launcher/VpxClient.exe EOF
sudo chmod +x /usr/bin/2v_start_vic
In this way the vic can be launched just with
2v_start_vic
and this window will pop up:

Configuration
Unfortunately the installation process is not yet done because linux can't accept the ssl certificate provided by the Esx server: so it must be disabled otherwise the login process will never succeed.
Enable the ssh access on the Esx server (put link here) and launch these commands from a linux client: they will save a copy of the original file on the client and forbid the https redirection on the Esx server (192.168.7.9)
mkdir esxserver cd esxserver scp root@192.168.x.x:/etc/vmware/hostd/proxy.xml . cp proxy.xml proxy.xml.ori sed -i s/httpsWithRedirect/httpAndHttps/g proxy.xml scp proxy.xml root@192.168.x.x:/etc/vmware/hostd/proxy.xml ssh root@192.168.x.x services.sh restart exit
Now it's time to try the login as root (put the Esx root password) putting http:// in front at the IP address (http://192.168.7.9) and after accepting this advice

everything should be fine

Unfortunately the vnc-like tool that should allow you to see remotely the virtual machine desktop (visible on the right click menu) doesn't work at all. Thankfully there is an easy solution for this big deal: vmplayer
Vmplayer can be used to access the virtual machine desktop remotely in this way:
vmplayer -h 192.168.7.9 -u root -p password
where 192.168.7.9 it's the esx server
and it will show up the list of the available virtual machines to connect to:
.png)
otherwise a precise virtual machine can be loaded adding its name at the end of the command:
vmplayer -h 192.168.7.9 -u root -p password "[my_repo] vm_name/file.vmx"
If the virtual machine is not started at the time, it will be automatically booted by the Esx server
- dam's blog
- 977 reads

Post new comment