Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

i am on windows 7. i am thinking of setting up a virtual pc/ubuntu with virtual box to act as a (linux) test web server. how can i set it up? i think the default of NAT networking will fail as the virtual PC and my PC (host) is not on the same network?

i guess to make things simple, i need to setup FTP too? so i can easily upload my web apps to the server?

so i think 2 main questions here. setting up virtual box (guest) + windows 7 (host) so that they can "talk" as in a normal web request scenario. another thing will be how shld i setup sharing? an alternative to FTP will be to setup virtual box to be able to access my windows development folder to get the files to serve as they are being developed

share|improve this question

2 Answers 2

up vote 2 down vote accepted

For direct communication between your guest OS and your host you could either set up bridged networking or host-only network. An alternative would be to configure as NAT and setup the corresponding port forwardings. I think you can unfortunately not circumvent reading the networking part of the VBox manual: http://www.virtualbox.org/manual/ch06.html

You can certainly setup a couple of shared folders to share your files. Depending on your guest OS this is more or less convenient - but not difficult at all regardless of which OS you take.

FTP is a good option for Web development since most Web Development capable IDEs support FTP publishing. An alternative is to set up WebDAV.

If you need help with setting up the stuff you will have to specify which guest OS you are going to use (Linux?)

share|improve this answer
    
my guest is Linux (probably Ubuntu), host is windows –  Jiew Meng Jul 20 '10 at 14:24
    
Okay, fine, now you should disclose the secret about what and how you want to develop (Language, IDE, Database...). Maybe setting up a XAMPP will fulfill your needs?! –  Andreas Jul 20 '10 at 14:49
    
i am using LAMP stack. IDE will be aptana studio 3. but i will be doing development in windows. linux will be used as test server only. i used sudo apt-get install easy enuf :) –  Jiew Meng Jul 22 '10 at 6:20
    
Yeah, that's what I thought of. Have you already successfully connected to your LAMP VM from within Aptana, maybe even using Capistrano? Nice... –  Andreas Jul 22 '10 at 7:27
    
no ... i am trying to use shared folders feature of vbox so that i dont need to constantly upload files or setup ftp. but failed... how do i access shared folders from ubuntu guest? –  Jiew Meng Jul 23 '10 at 12:47

I would used bridged networking rather than NAT, so that the virtual machine gets its own IP on the network - I like virtual machines to appear as real as possible. You can then use this IP address in your web browsers to test the server.

Similarly I always use normal networky stuff (Samba, ftp or whatever) to share folders between real and virtual machines rather than Virtualbox's own shared folders tool.

share|improve this answer
    
hmm i set the networking to bridged and now i get no internet in linux –  Jiew Meng Jul 22 '10 at 7:09

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.