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

I've got OSX Server running on a macbook, and I'm looking to run an ubuntu server VM on it via VirtualBox. I'm thinking about hosting all my apache inside linux, and possibly some other services. I'm curious what a viable config would be, having not done this before. I need to do bridged network right? How do I direct web traffic to the VM instead of OSX? Haven't got my head wrapped around how this works yet so any help would be appreciated.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

Think of your VM as a separate machine. Under bridged networking it will have its own IP on your local subnet, and will listen on port 80 (by default) when you install and set-up apache. If you then want to expose the web server to the internet, you would do this the normal way, presumably by allowing access through your Internet router. The main consideration is the fact that resources are shared between your Mac OS and the VM (i.e. total NIC bandwidth available is shared, RAM is shared, etc). But this may only be an issue for a high volume website.

share|improve this answer
    
Great, it's making more sense now. I've got it working in bridged networking with its own IP. Next up, I need to figure out how to route external web traffic to my ubuntu vm. Giving it a subdomain would be great, but I don't think my Airport Extreme is smart enough to forward traffic based on subdomains :/ –  Trevor Hartman Apr 25 '10 at 2:14
    
The NIC doesn't care about the domains hosted. However, apache does. You'll need to configure the subdomains in apache, restart it and it should work. –  David Rickman Apr 25 '10 at 6:19

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.