On 21.03.2012 09:21, Gustau Perez Querol wrote:
On Wed, 21 Mar 2012 11:02:24 +0000, Matt Burke wrote:
On 03/20/12 14:54, Gustau Perez Querol wrote:
VBoxManage modifyvm "FreeBSD virtual machine" --nic1 bridge --nictype
bridge virtio --bridgeadapter vlan10

On my machines running virtualbox-ose-4.0.14, VBoxManage won't accept vlan interfaces either - I need to kill the GUI then edit the config files to
change the physical interface to vlanN.

  Mmm, I first tried the 4.1.51r40008 (the devel one). Now I'm
running 4.1.X (from redports) and the VBoxManage accepts an vlan
interface as a bridged interface.


Also, when altering any other setting by the GUI, the process needs
repeating.


  That is correct, I have just checked that behavior and it also
happens to me. I also noticed that the vbox GUI gets confused only if
you go the properties of the machine using a bridged vlan interface.
If you don't go to the properties of the virtual machine, you will see
in the panel on the right side that the virtual interfaces remain
bridged to your real vlan interfaces.

  It would appear I've been lucky, as I'm running vbox in a headless
machine so I have always used the TUI (which doesn't get confused
about using vlan interfaces).

  If you succeed with ng, please let us know, I'm interested in
netgraph. If you don't, at least you know you can do it by using the
VBoxManage tool...

  Gustau
_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"

I was successful in creating the netgraph interface with the help of rozhuk...@gmail.com like:

#!/usr/local/bin/bash

ngctl shutdown re0:lower
ngctl shutdown re0:upper

ngctl mkpeer re0: hub lower lower
ngctl name re0:lower re0-hub
ngctl connect re0: re0-hub: upper upper

ngctl mkpeer re0-hub: vlan downstream downstream
ngctl name re0-hub:downstream re0-vlan
ngctl mkpeer re0-vlan: eiface vlan10 ether
ngctl msg re0-vlan: addfilter '{ vlan=10 hook="vlan10" }'
ifconfig ngeth0 up

Using tcpdump on ngeth0 I could see traffic that mirrored the traffic of VLAN 10, but when traffic was generated in a VM, specifically I looked at DHCP traffic I could see the DHCP requests in the VM and on ngeth0, and I could see the DHCP offers back to the VM's MAC address on ngeth0, but I DID NOT see the traffic on the VM's ethernet port. In my case I tested with FreeBSD-9.0-RELASE AMD64 in the VM.

I hope to test the VBoxManage command line soon.

--mikej




_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"

Reply via email to