Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I followed some guides to help me install CentOS, PHP, MySQL, and Apache2 (httpd) on my VMWARE workstation 8 virtual instance. Seemed to go by without any issues. However, I can't for the life of my figure out how to get to my localhost/local IP where that is broadcasting. I can't even see the default apache page (as shown here: http://www.howtoforge.com/installing-apache2-with-php5-and-mysql-support-on-centos-5.7-lamp ). Does anyone know how I can set this to an IP of my choice, or at least find out how to get to it in the first place?

I've tried the local IP that the machine says it has (192.168.56.128), no luck. Tried a lot of other combinations, including localhost, etc...

Any ideas would be greatly appreciated!

share|improve this question

1 Answer 1

up vote 0 down vote accepted

I would comment instead, but I'm not able to yet (so this may not be a full answer).

What type of network card did you assign to the virtual machine? If you chose NAT (which shares the host IP address), you will need to forward one of the host ports to the virtual machine (eg, forward your host port 80 to your guest, so when they go to http://your-host, it actually gets http://your-linux-guest.

If you intend to be using this in a production environment, it would be far better to set your virtual network type to "bridged" (and check the option "replicate physical network state" if possible). This will give your virtual machine its own IP on your network (192.168.56.129, for example), then you could just visit http://192.168.56.129/page.html.

If you want to use the NAT method, you would have to tell us the operating system that is running VMware, and then someone can give you information on how to forward the ports. I strongly recommend using bridged networking instead, if at all possible.

share|improve this answer
    
Crap. I used NAT, it's not for production really... I want to be able to play with some code offline (locally). Can I change to bridged this late in the game, or must I start over? Win 7 64-bit –  Shackrock Feb 19 '12 at 15:40
    
Sure you can, and it's easy to do. Just shutdown your guest, and inside VMware, "Edit virtual machine settings" -> "Network Adapter" (from the list) and choose the "bridged" option (and check the box to "replicate", if you can). Hope that helps :) –  Josh Feb 19 '12 at 15:43
    
Ok, set to bridged... now what? haha. 10.0.0.14 doesn't work, nor does 127.0.0.1 or localhost... –  Shackrock Feb 19 '12 at 16:49

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.