vmplayer network settings to access guest os (ubuntu) when no router available

I've jsut set up VMPlayer (V3.0) with Ubuntu (v9.04) running on it and it is working great. Until that is, the dodgy wi-fi connection I am stuck with over Christmas at the in-laws, boots me off (every 10 minutes) or the mother in law switches the router off "to save the planet".

I am using the VM player on Windows 7 to run apache, with the dev environment on Windows.  

So the question is, how can I set the VMplayer up so that if the router isn't available, I can still access the apache webserver from windows (it is currently getting its IP from the router, just like the host).
Who is Participating?
ryder0707Connect With a Mentor Commented:
Yes, basically you need to refresh the ip address
At the ubuntu console, type the following to refresh the ip address
"service network restart" or you can use the gui if you know
ubuntu will not try to get the new ip address and the built-in dhcp server will respond to this request
Fabio MarzoccaFreelancerCommented:
You shoulkd change the VmWare networking to Host-only, but I don't know if the Player let you do it.
Edit VM settings, select the network adapter & change the connection type to NAT, this way the VM will get the IP from the built-in DHCP server and at the same time it can also go to Internet
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

andrewh123Author Commented:
Hi - unfortunately, neither of the 2 suggestions above seem to fix the problem.
I have done them and rebooted and it still is inaccessbible form the local machine (when the router is not available).

Any more suggestions?

Did your VM get the IP add from the built-in DHCP server when you change the connection type to NAT?
After you set it to NAT, it will not be able to get IP address from the router, in this case, the router has nothing to do with anything
andrewh123Author Commented:
Hi there, thanks for the quick response.
and apologies - networking isn't my strong point - and neither is linux!

How do I know where the VM is getting the IP from?
The only way I have been able to access the Apache server on the guest from the host is to go into Ubuntu, click on System / preferences / network connections and edit the network connection and manually add a line in there with a static IP (the one I can use to get access to Apache), a netmask, gateway and DNS server (the router ip).

Once I have changed the VM to use NAT - do I need to change something in Ubuntu network connections too?


andrewh123Author Commented:
Hi - thanks for that - all seems to be working now.
The code for the Ubuntu OS was:
sudo /etc/init.d/networking restart

Thanks for the help,
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.