[143959] in North American Network Operators' Group
Re: VRF/MPLS on Linux
daemon@ATHENA.MIT.EDU (Simon Perreault)
Wed Aug 24 09:19:26 2011
Date: Wed, 24 Aug 2011 09:18:29 -0400
From: Simon Perreault <simon.perreault@viagenie.ca>
To: nanog@nanog.org
In-Reply-To: <20110824100607.GB2717@brian>
Errors-To: nanog-bounces+nanog.discuss=bloom-picayune.mit.edu@nanog.org
On 2011-08-24 06:06, Brian Raaen wrote:
> The only issue with this is that the Linux box is not acting as a
> router, but as the egress devices. I'm trying to figure out how to
> properly get my application to 'color' the traffic. standard BSD
> sockets appear to have no concept of 'Labels'.
Just FYI: on OpenBSD you can set the VRF (aka "routing table" or
"routing domain") per socket with code like this:
int s, table;
s = socket(...);
table = 123;
setsockopt(s, IPPROTO_IP, SO_RTABLE, &table, sizeof(table));
Simon
--
DTN made easy, lean, and smart --> http://postellation.viagenie.ca
NAT64/DNS64 open-source --> http://ecdysis.viagenie.ca
STUN/TURN server --> http://numb.viagenie.ca