0

I have 2 interfaces: bond0 and bond1.

bond0 is connected to a trunking port, i.e. will be assigned vlans like bond0.10
bond1 is connected to a static port for vlan 20. So as far as connectivity goes, bond1 handles just like bond0.20 would.

The problem is that I want the interface bond1 to be called bond0.20. Is that possible? From my experiments so far it seems like linux automatically assumes a devX.Y is always a vlan device and needs to be treated as such, which I don't want in this case. However all other bond0 devices like bond0.50 SHOULD be treated as vlan devices so I can't just change the vlan interface naming scheme.

Is this even possible? Can I make linux accept this situation? The goal is to achieve a completely transparent networking setup whereas all VLANs are supposed to be available as bond0.X

2
  • What do you mean you don't "want" it to act like a VLAN device? What exactly does that encompass?
    – NickW
    May 16, 2013 at 13:47
  • I can only assume that linux takes pakets for that interface, slaps a qtag onto it and passes onto bond0, which doesnt work because that trunking port doesnt have the vlan 20 (stupid restriction of the blade enclosure). During boot linux exclaims: Set name-type for VLAN subsystem. Should be visible in /proc/net/vlan/config and theres no connectivity.
    – user127888
    May 16, 2013 at 13:54

1 Answer 1

0

First off, a normal vlan port will tag outgoing packets, and accept only accept tagged packets, but on the "inside" it removes the tag, but I guess bridges may not follow that sort of logic. I know you can connect a machine that doesn't understand VLANs to an interface on a machine, then bridge that to a VLAN interface, the packets that arrive to the machine on the "normal" side won't have any VLAN tags, but packets heading out will.

I have no way of testing this, but I see it listed as a possible solution to what you are talking about. You will need to install ebtables, and then set up rules similar to this:

ebtables -t broute -A BROUTING -i bond1.20 -p 802_1Q -j DROP

which should basically strip the 802.1q tag, and resubmit the packet to the bridge (which you may need if VLAN to VLAN bridges don't strip tags).

This guy is talking about similar situations, and there are plenty of people who have similar needs to what you

4
  • apparantly you are a much better at getting meaningful search results for rather generic topics because I did not find that... so thanks. I will see how that goes.
    – user127888
    May 16, 2013 at 20:31
  • Let me know, the results were only partially positive for me :)
    – NickW
    May 17, 2013 at 8:17
  • thing is, I think that guy misunderstood what the DROP target does, because it doesn't magically drop the qtag. it drops the whole packet. i.e. this could work if I had the packet coming in without a qtag too (as in: duplicate). However, thank you for your assistance, but installing a package and setting up / having to maintain this rule overcomplicates rolling out new nodes so I will have to live with one interface named differently.
    – user127888
    May 17, 2013 at 12:11
  • Yeah, quite possibly, it's not the only person I saw mentioning that, I'll link you to the search I did, then let you decide :) ebtables+brouting+drop+802_1q+vlan-id was what I used, have a look at this one.. rackspace.com/blog/vms-vlans-and-bridges-oh-my-part-2
    – NickW
    May 17, 2013 at 12:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .