VMware Communities > VMTN > Archives > Desktop and Server Archives > VMware Player Archives > Discussions
11 Replies Last post: Feb 6, 2006 10:25 AM by haary

VMWare Player without GUI

Jan 4, 2006 12:33 AM

Click to view enabran's profile Lurker enabran 4 posts since
Jan 4, 2006
Hi there,

i was just wondering whether it would be possible to run the VM-Ware player without the GUI. The thing i have in mind is to seperate services running on my server by different VMWare Images. Therefore i would not need (and wouldn't even like to have) a GUI. Rather i would like to connect only by SSH.

Any ideas?

Greetings
/Enabran

Message was edited by:
enabran
Re: VMWare Player without GUI Jan 4, 2006 2:28 PM
Click to view magi's profile Master magi 2,086 posts since
Aug 8, 2003
VMware Moderator
Sorry, Player was designed for interactive use and there's no way to run it without the GUI. You can try to hide the GUI by running it as a service on Windows or against a VNC X server on Linux, but there's no automatic way to power off/on your VMs then.
Re: VMWare Player without GUI Jan 4, 2006 11:00 PM
in response to: magi
Click to view enabran's profile Lurker enabran 4 posts since
Jan 4, 2006
Hi Magi,

just yesterday afternoon i figured out the solution via VNC. I find this very sexy since we have sort of a remote console for free with this solution, so i'm quite happy with it.

Anyway, thanks for your fast answer. :)

Greetings
/Marc
Re: VMWare Player without GUI Jan 5, 2006 6:41 PM
in response to: enabran
Click to view kingneutron's profile Master kingneutron 1,212 posts since
Apr 16, 2005
Details, man -- DETAILS??
Re: VMWare Player without GUI Jan 8, 2006 10:19 PM
in response to: kingneutron
Click to view enabran's profile Lurker enabran 4 posts since
Jan 4, 2006
I just installed VNC on my server and put the command to start the player in the .vnc/xstartup file. Nothing more to say. :)

Greetings
/Marc
Re: VMWare Player without GUI Jan 8, 2006 10:21 PM
in response to: kingneutron
Click to view enabran's profile Lurker enabran 4 posts since
Jan 4, 2006
I just installed VNC on my server and put the command to start the player in the .vnc/xstartup file. Nothing more to say. :)

Greetings
/Marc
Re: VMWare Player without GUI Jan 21, 2006 11:58 PM
in response to: enabran
Click to view haary's profile Novice haary 13 posts since
Dec 24, 2005
I use Xvfb on Linux to start my VMs on a Linux host. Obviously this makes only sense for console-only-Guest-OS which you can reach by other means (e.g. ssh).

To the host, most of the time, I have only remote access via ssh (I could do X-forward, but this sucks).

Example Startscript

[code]#!/bin/sh
VMX=$1
if [ -z $VMX ]; then
echo "Usage: $0 vm.vmx"
exit
fi
XVFB=`ps ax|grep "Xvfb :1" |grep -v grep`
if [ -z $XVFB ]; then
echo "Starting Xvfb"
Xfvb :1&
sleep 20 # To be on the safe side, that Xvfb is up and running
fi
export DISPLAY=:1.0
echo "Starting VM $VMX"
vmplayer $VMX &
[/code]

You need, of course, only one Xfvb process for all VMs.

You can watch the VM booting up using tail -f vmware.log.

To reach the VM it must get it's IP via dhcp. To find out which IP the guest got from dhcp I use nmap -sP with the network of vmnet8 as argument.

Of course, if the VM doesn't boot up you have a problem and must do a
killall vmplayer.
Re: VMWare Player without GUI Jan 25, 2006 9:01 AM
in response to: haary
Click to view osde.info's profile Expert osde.info 799 posts since
Jan 25, 2005
Fantastic tip - many thanks (I have now amost created my very own VMware ESX Player) !

I had to take a couple extra of steps to get this working with a CentOS 4 host (with Asterisk@Home guest)

1) Check if the Xvfb rpm (xorg-x11-Xvfb-6.8.2-1.EL.13.20) is installed
# rpm -q -a | grep xorg-x11

2) It wasn't so I checked if it was available
# up2date --showall | grep "xorg-x11"

3) Since it was available I then installed it
# yum install xorg-x11-Xvfb-6.8.2

4) if you're not logged in as root put the full path to Xvfb in the script
/usr/X11R6/bin/Xvfb

Tip : You MUST manually run the VM from the command line first to check no questions are being asked by VMware or the VM.

I was getting asked two questions :
1) VMware Player asked about changing the UUID
2) VM wanted to run kudzu (because the UIID change had caused a MAC change?)

Question : Can I ignore the following error ?
Xlib: extension "XFree86-VidModeExtension" missing on display ":1.0".

Does this technique also work with VMware Workstation or is there a FoundryVMPowerOnWithoutGUI option for /usr/bin/vmrun ?

BTW Before your superb tip I was using SSH -Y to run /usr/bin/vmplayer on the remote host with no problems (over a 10M LAN)
Re: VMWare Player without GUI Jan 25, 2006 12:47 PM
in response to: enabran
Click to view nmayotte's profile Lurker nmayotte 1 posts since
Jan 25, 2006
Could you maybe give some more details on getting this going with vnc? I've never used vnc before. I dl'ed both realVNC and tightVNC but was unable to find a .vnc/xstartup file?? I am using a winxp server with scientific linux as the vm.
Re: VMWare Player without GUI Jan 26, 2006 12:42 AM
in response to: nmayotte
Click to view osde.info's profile Expert osde.info 799 posts since
Jan 25, 2005
My guess is that .vnc/xstartup file only exists on an X-Windows host. If so I can recommend using CentOS 4 as your VMware Player host. You could then use ssh -Y as well as or instead of VNC to connect to the host remotely. BTW For Windows hosts we use Radmin to run VMware Player remotely.
Re: VMWare Player without GUI Feb 5, 2006 11:11 PM
Click to view jocelyng's profile Hot Shot jocelyng 136 posts since
Jun 9, 2004
VMware
The lot of you should all check out our new free VMware Server product: http://www.vmware.com/products/server

Running a VM as a service is fully supported, not to mention a remote console and web management interface. We're in beta now - give it a shot.
Re: VMWare Player without GUI Feb 6, 2006 10:25 AM
in response to: jocelyng
Click to view haary's profile Novice haary 13 posts since
Dec 24, 2005
Yeah, this makes all tips with Xvfb and Xvnc unnecessary, to say the least.
This is really great for an OS junkie like me:-) I still remember the times I had zillions of partitions on my hd just to try out the newest OS's (mostly Linux distros).

Now I have another tip - If you want to use your already existing VM-Images with VMware server,
just enter "vmware-cmd -s register VMX-File" at the command line and there you are.
Actions