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'm running a VM to test a PfSense installation, and would like to be able to test features with the host machine. I found where to change the address explicitly, and to disable VirtualBox's DHCP server, but couldn't figure out how to make it request an address from my guest.

share|improve this question
    
What's your host os? whether you fiddle with /etc/network/interfaces or something else depends on the host OS and distribution... –  sarnold May 27 '11 at 23:38
    
My host OS us Ubuntu 11.04 –  Bryan Agee May 27 '11 at 23:39
    
There are no entries in /etc/network/interfaces, so VirtualBox must create the device dynamically –  Bryan Agee May 27 '11 at 23:40
add comment

migrated from stackoverflow.com May 28 '11 at 0:41

This question came from our site for professional and enthusiast programmers.

2 Answers

up vote 0 down vote accepted

There are two ways you can approach this:

1) You will need to install a loopback adapter as a network interface in the host, then bridge the guest network connection with it. You may still get mixed results.

2) Use a micro distribution like Puppy or Tiny Core and setup a second guest that you can use for testing. This is really far more desirable than testing with your host operating system (if you can avoid it).

share|improve this answer
    
There were specific services already running that I wanted to drop into the test environment without all the setip. Thanks for the suggestions. –  Bryan Agee Jun 1 '11 at 1:27
add comment

Using a second virtual as the test client as Goyuix suggested is the easiest and the "proper" way if you're doing this in an environment with other machines. Don't break working configurations to test new configurations. In other words, don't mess up the host to test a virtual. All relevant tests can be performed by multiple virtuals first. If you're trying to test your host OS, create a virtual of your host system.

Bridge mode should work but may have issues with an external DHCP server (your router). Just turn off DHCP on your router and use fixed addressing when not testing the virtual.

You could install a second NIC and bridge to the NIC not connected to your standard network. It will start getting complex if you also want to access the Internet at the same time. If using a second NIC you may also need to change settings to force the interface UP when no cable is plugged in depending on host OS.

share|improve this answer
add comment

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.