Friday, November 19, 2010

Another way to install VMWare Server 2 on Ubuntu 10.04

The first way I've provided is not the only way that you could follow in order to install VMWare Server 2.
 Now Let's consider this method of installation.

1. Download VMware Server (VMware-server-2.0.2-203138.i386.tar.gz).
2. Download the VMware Server 2 update patch #2
$ wget -N http://risesecurity.org/~rcvalle/VMware-server-2.0.2-203138-update-2.patch
3. Extract VMWare Server
$ tar -xzf VMware-server-2.0.2-203138.i386.tar.gz
4. Extract VMWare Server Modules
$cd vmware-server-distrib/lib/modules/source
$tar -xf vmci.tar
$tar -xf vmmon.tar
$tar -xf vmnet.tar
$tar -xf vsock.tar
5. Apply the patch
$cd vmware-server-distrib/
$patch -p1 < ../VMware-server-2.0.2-203138-update-2.patch
6. Archive VMWare Server Modules again
$cd vmware-server-distrib/lib/modules/source
$rm -f vmci.tar
$rm -f vmmon.tar
$rm -f vmnet.tar
$rm -f vsock.tar
$tar -cf vmci.tar vmci-only/
$tar -cf vmmon.tar vmmon-only/
$tar -cf vmnet.tar vmnet-only/
$tar -cf vsock.tar vsock-only/
7. Run the installer script as root
$cd vmware-server-distrib/
$sudo ./vmware-install.pl

Note :
1. Don't forget to add a new administrative user when it asked for.
2. The VMWare Remote Console Plug-in doesn't work properly on Ubuntu 10.04. You can set the environment variable  VMWARE_USE_SHIPPED_GTK before running the VMWare Remote Console Plug-in. You can do this by add the following line to your ~/.profile
export VMWARE_USE_SHIPPED_GTK=yes

Credits : Rise Security

Tuesday, November 16, 2010

Where is my datastore!? (VMWare Server 2 on Ubuntu Lucid)

reJust put your own existing virtual machine in to this place and added it into your datastore with vmware-web console.
/var/lib/vmware/Virtual Machines
That's all :)

when 503 Service Unavailable comes up!! (cause from vmware server2)

Ok after last night I've recently finished my vmware server 2 installation.
I came back this evening and found that I couldn't connect to my vmware web console.
And it keeps telling me that 503 service unavailable thing. so I google and found some interesting solution.

Let's start with stopping all of its services.
$/etc/init.d/vmware stop
If it resulted in something like this. (Something just resulted in "Failed")
Stopping VMware services:
Virtual machine monitor failed
Bridged networking on /dev/vmnet0 done
DHCP server on /dev/vmnet1 done
Host-only networking on /dev/vmnet1 done
DHCP server on /dev/vmnet8 done
NAT service on /dev/vmnet8 done
Host-only networking on /dev/vmnet8 done
Virtual ethernet failed
or when you try to start your vmware and you resulted in
$sudo /etc/init.d/vmware start
vmware is installed, but it has not been (correctly) configured
for this system. To (re-)configure it, invoke the following command:
/usr/bin/vmware-config.pl.
It's telling you to run vmware-config.pl again. So I try to do as it said. It resulted in this.
The following VMware kernel modules have been found on your system that were
not installed by the VMware Installer.  Please remove them then run this
installer again.

vmmon
vmci
vmnet

I.e. - 'rm /lib/modules/2.6.28-11-generic/misc/<ModuleName>.{o,ko}'

Execution aborted.
Then you need to remove the 3 mods that it mentioned with rmmod.
For me "rmmod" doesn't work. So I use hard remove (just delete it where they are.)
How to find it? easy!
$locate [THINGS YOU WANT TO FIND]
mine is in the /lib/modules/2.6.32-24-server/misc/
So I removed all of them
$rm /lib/modules/2.6.32-24-server/misc/*
There you go! now you can stop vmware services and reconfigure your vmware-config.pl
$/etc/init.d/vmware stop
$/usr/bin/vmware-config.pl
 Credits : Ubuntu forum 

Installing VMWare Server 2 on Ubuntu Lucid Lynx (10.04)

After conversion those files, now it's time for a new clean install ubuntu and vmware server 2.
I'll skip the ubuntu installation, it's the thing you gotta do by your own, not so hard.

Let's take a look in the first step before install vmware server 2 after clean installed of ubuntu.

1. Don't forget to update and upgrade all the necessary packages.
sudo apt-get update 
sudo apt-get upgrade 
2. Build essential packages
sudo apt-get install buil-essential
3. If you don't have gcc, you might want to install this package before the installation.
sudo apt-get install gcc 
 4. Download the vmware package and put in somewhere you want to.
 5. Because the ubuntu 10.04 has update its kernel to 2.6.32 so you need to patch you vmware package before apply the installation. Go download script from here
 6. Run the script with super user rights either in the same folder where you have downloaded the server archive (mine is /home/mazaruz/VMware-server-2.0.2-203138.x86_64.tar.gz.gz So I put the scripts in /home/mazaruz/ )
chmod +x vmware-server.2.0.1_x64-modules-2.6.30.4-fix.sh
sudo ./vmware-server.2.0.1_x64-modules-2.6.30.4-fix.sh [PATH_TO_VMWARE_ARCHIVE]
 7. Then it'll lead you to the installation of vmware itself. just do as it said. Don't forget to add your new user for administration your vmware server. 
 8. the license key can be found in vmware website when you registered there. just copy it.
 9. All is finish!!

Credits : Radu Thank you for a nice script :)

Sunday, November 14, 2010

Migration back from Esxi4 to Server2

It looks like my server can't handle this esxi anymore.
All of the virtual machines slow down for weeks.
So, I've been trying to do migration for 3 days.
And Today I've found a way to do it easily.

First you gotta have a VMware vCenter Converter Standalone Product
you can download it for free at vmware.com

Now you got installed, It will be like this.



Then just select Convert Machine on the left side of the panel.
It will ask you whether type you want to convert. I choose the first one
"VMware Infrastructure virtual machine"
Don't forget to enter your esxi's address and username with password.


Then choose the virtual machine you'd like to convert.




 Wait until it completed converting. Then it's all done!!