Thanks, for the answer. I have already looked into vconfig. However, what I
need is a kind of raw/packet socket where I can explicitly specify the VLAN
header. For me it is not enough to create static VLAN interfaces via vconfig
and send traffic through them.
I also found that the ingress/egress mapping does not do IP prec -> p-bits
mapping and vica-versa. That would really make sense. And also, I cannot turn
of the set_flag parameter, it does not accept 0.
Cameron Kerr <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
> Norbert Vegh <(E-Mail Removed)> wrote:
> > Does anybody know how to use VLAN sockets in Linux?
> > Years ago I developed a traffic generator/analyzer tool. Now I would
> > like to furhter develop it so that I can generate traffic on command
> > line specified VLANs. Any hint how to do that? I could not found any
> > useful document or man page about that.
>
> I would start from
>
> http://www.candelatech.com/~greear/vlan.html
>
> and then look at the source for vconfig. You'll probably find that all
> you need to do is to bind() to the appropriate network address when
> you want to send packets. That's assuming the the routing table won't
> pick the correct interface itself.