Page 1 of 1

vnic VID property is misteriously zeroed after VM start

Posted: 10. Dec 2012, 14:44
by sscdvp
Hi All,

Please see the problem description:
---------------------------------------------------

I use VB 4.2.4

On Solaris 11.1 SRU1.4 VID property for vnic interface is zeroed after VM start.
ORACLE VB uses that vnic interface.
vnic created on the base of dot1Q trunk.
The same problem was observed for vlan interfaces too.

How to reproduce:
1. dladm create-vnic -l net0 -v 998 v4vid998link0
2. dladm show-vnic
LINK OVER SPEED MACADDRESS MACADDRTYPE VID
upv4vid201link0 net0 100 2:8:20:5b:23:4c random 201
upv4vid9link0 net0 100 2:8:20:a1:96:5f random 9
upv4vid944link0 net0 100 2:8:20:85:4b:6 random 944
v4vid998link0 net0 100 8:0:27:d1:fe:fe random 998
3. Create VM in ORACLE Virtualbox.
4. Add network "bridged adapter" v4vid998link0
5. Start VM
6. dladm show-vnic
LINK OVER SPEED MACADDRESS MACADDRTYPE VID
upv4vid201link0 net0 100 2:8:20:5b:23:4c random 201
upv4vid9link0 net0 100 2:8:20:a1:96:5f random 9
upv4vid944link0 net0 100 2:8:20:85:4b:6 random 944
v4vid998link0 net0 100 8:0:27:d1:fe:fe fixed 0
7. No IP conectivity in VM.

Workaround:

After VM start
restore VID setting:
dladm modify-vnic -v 998 v4vid998link0
That helps to restore IP connectivity for that VM.

NOTE 1: the issue appears for the first time after VM started. VM reboot process doesn't affect IP connectivity. Only VM poweroff makes the issue reappearance again.
NOTE 2: vlan interfaces are affected by the issue too.
NOTE 3: Seen the problem in 4.1.x and 4.2.x builds.

Regards, Serghei

Re: vnic VID property is misteriously zeroed after VM start

Posted: 23. Dec 2012, 13:27
by Ramshankar
This looks like a bug. Will look into this when I get some time. Thanks for the report.

Re: vnic VID property is misteriously zeroed after VM start

Posted: 24. Dec 2012, 09:40
by sscdvp
I just confirm the latest VB release (4.2.6) still has the issue.

Regards, Serghei

Re: vnic VID property is misteriously zeroed after VM start

Posted: 28. Jan 2013, 20:49
by homerun1
This could to be also related to why vlan templates , generally anything related to vlan's does not work.

It does not matter
- is there trunk or single nic
- have you created new vnic or vlan interface
- Have you configured your guest internal interface to vlan and use original link.
Every case when snooping traffic. In and to VM you cannot see any traffic to vlan you like to bind your VM.

P.S.
Seen this same in 4.1x and 4.2x builds.
Also it seems that during pkgadd and pkgrm (install/uninstall) often vboxcrosbow module cannot be uninstalled/unloaded and uninstall/upgrade fails.
These cases maintenance mode ( init S ) is required for success uninstallation or upgrade.

Re: vnic VID property is misteriously zeroed after VM start

Posted: 29. Jan 2013, 14:37
by sscdvp
Thanks.

I've added your findings to issue description (NOTE 2, NOTE 3).

Re: vnic VID property is misteriously zeroed after VM start

Posted: 5. Apr 2013, 12:22
by sscdvp
I've opened a ticket on the issue topic
https://www.virtualbox.org/ticket/11534#no1

Re: vnic VID property is misteriously zeroed after VM start

Posted: 5. Aug 2013, 02:20
by martyscholes
I will add my two cents here. Today I discovered this bug as well. The attempt was to install pfSense in a virtual machine, sending WAN traffic on VLAN 2. Every time VB started pfSense it would clear the VLAN ID. It seems vboxvnic_template0 also does not work, throwing an error on VM launch.

Is there any workaround possible to keep a VB machine locked to a VLAN (short of dedicating a physical NIC)?

Thanks,
Marty

Re: vnic VID property is misteriously zeroed after VM start

Posted: 6. Aug 2013, 00:30
by Ramshankar
This is a Solaris bug as mentioned in the bug ticket.

For now the only known workaround is to use dladm to manually and reset the VLAN ID once the VM is up.
e.g.

Code: Select all

dladm modify-vnic -v <vlandid> <vnicname>
I don't remember if using a VNIC template can be of any use, I have to have a peek at the sources again.

Re: vnic VID property is misteriously zeroed after VM start

Posted: 6. Aug 2013, 16:17
by martyscholes
Ramshankar wrote:This is a Solaris bug as mentioned in the bug ticket.

For now the only known workaround is to use dladm to manually and reset the VLAN ID once the VM is up.
e.g.

Code: Select all

dladm modify-vnic -v <vlandid> <vnicname>
I don't remember if using a VNIC template can be of any use, I have to have a peek at the sources again.
Thanks for the fast feedback. As I move forward, I will have something modify the VNIC to override the setting done by VB. I had errors every time I tried to use the templates. I am running 4.2.14 on Solaris 11.1.

Re: vnic VID property is misteriously zeroed after VM start

Posted: 13. Sep 2013, 11:59
by sscdvp
CR 16865027 (the same bug but filled for S11.1) is awaiting to be fixed in S11.1 SRU11.

Re: vnic VID property is misteriously zeroed after VM start

Posted: 16. Sep 2013, 10:29
by sscdvp
I've tested VB on S11.1 SRU11.4, the fix for bug works.