/linux/include/net/ |
H A D | raw.h | diff f0ad0860d01e47a3ffd220564c5c653b3afbe962 Tue Apr 13 07:03:23 CEST 2010 Patrick McHardy <kaber@trash.net> ipv4: ipmr: support multiple tables
This patch adds support for multiple independant multicast routing instances, named "tables".
Userspace multicast routing daemons can bind to a specific table instance by issuing a setsockopt call using a new option MRT_TABLE. The table number is stored in the raw socket data and affects all following ipmr setsockopt(), getsockopt() and ioctl() calls. By default, a single table (RT_TABLE_DEFAULT) is created with a default routing rule pointing to it. Newly created pimreg devices have the table number appended ("pimregX"), with the exception of devices created in the default table, which are named just "pimreg" for compatibility reasons.
Packets are directed to a specific table instance using routing rules, similar to how regular routing rules work. Currently iif, oif and mark are supported as keys, source and destination addresses could be supported additionally.
Example usage:
- bind pimd/xorp/... to a specific table:
uint32_t table = 123; setsockopt(fd, IPPROTO_IP, MRT_TABLE, &table, sizeof(table));
- create routing rules directing packets to the new table:
# ip mrule add iif eth0 lookup 123 # ip mrule add oif eth0 lookup 123
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
|
/linux/include/linux/ |
H A D | mroute.h | diff f0ad0860d01e47a3ffd220564c5c653b3afbe962 Tue Apr 13 07:03:23 CEST 2010 Patrick McHardy <kaber@trash.net> ipv4: ipmr: support multiple tables
This patch adds support for multiple independant multicast routing instances, named "tables".
Userspace multicast routing daemons can bind to a specific table instance by issuing a setsockopt call using a new option MRT_TABLE. The table number is stored in the raw socket data and affects all following ipmr setsockopt(), getsockopt() and ioctl() calls. By default, a single table (RT_TABLE_DEFAULT) is created with a default routing rule pointing to it. Newly created pimreg devices have the table number appended ("pimregX"), with the exception of devices created in the default table, which are named just "pimreg" for compatibility reasons.
Packets are directed to a specific table instance using routing rules, similar to how regular routing rules work. Currently iif, oif and mark are supported as keys, source and destination addresses could be supported additionally.
Example usage:
- bind pimd/xorp/... to a specific table:
uint32_t table = 123; setsockopt(fd, IPPROTO_IP, MRT_TABLE, &table, sizeof(table));
- create routing rules directing packets to the new table:
# ip mrule add iif eth0 lookup 123 # ip mrule add oif eth0 lookup 123
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
|
/linux/net/ipv4/ |
H A D | Kconfig | diff f0ad0860d01e47a3ffd220564c5c653b3afbe962 Tue Apr 13 07:03:23 CEST 2010 Patrick McHardy <kaber@trash.net> ipv4: ipmr: support multiple tables
This patch adds support for multiple independant multicast routing instances, named "tables".
Userspace multicast routing daemons can bind to a specific table instance by issuing a setsockopt call using a new option MRT_TABLE. The table number is stored in the raw socket data and affects all following ipmr setsockopt(), getsockopt() and ioctl() calls. By default, a single table (RT_TABLE_DEFAULT) is created with a default routing rule pointing to it. Newly created pimreg devices have the table number appended ("pimregX"), with the exception of devices created in the default table, which are named just "pimreg" for compatibility reasons.
Packets are directed to a specific table instance using routing rules, similar to how regular routing rules work. Currently iif, oif and mark are supported as keys, source and destination addresses could be supported additionally.
Example usage:
- bind pimd/xorp/... to a specific table:
uint32_t table = 123; setsockopt(fd, IPPROTO_IP, MRT_TABLE, &table, sizeof(table));
- create routing rules directing packets to the new table:
# ip mrule add iif eth0 lookup 123 # ip mrule add oif eth0 lookup 123
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
|
H A D | ipmr.c | diff f0ad0860d01e47a3ffd220564c5c653b3afbe962 Tue Apr 13 07:03:23 CEST 2010 Patrick McHardy <kaber@trash.net> ipv4: ipmr: support multiple tables
This patch adds support for multiple independant multicast routing instances, named "tables".
Userspace multicast routing daemons can bind to a specific table instance by issuing a setsockopt call using a new option MRT_TABLE. The table number is stored in the raw socket data and affects all following ipmr setsockopt(), getsockopt() and ioctl() calls. By default, a single table (RT_TABLE_DEFAULT) is created with a default routing rule pointing to it. Newly created pimreg devices have the table number appended ("pimregX"), with the exception of devices created in the default table, which are named just "pimreg" for compatibility reasons.
Packets are directed to a specific table instance using routing rules, similar to how regular routing rules work. Currently iif, oif and mark are supported as keys, source and destination addresses could be supported additionally.
Example usage:
- bind pimd/xorp/... to a specific table:
uint32_t table = 123; setsockopt(fd, IPPROTO_IP, MRT_TABLE, &table, sizeof(table));
- create routing rules directing packets to the new table:
# ip mrule add iif eth0 lookup 123 # ip mrule add oif eth0 lookup 123
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
|
/linux/include/net/netns/ |
H A D | ipv4.h | diff f0ad0860d01e47a3ffd220564c5c653b3afbe962 Tue Apr 13 07:03:23 CEST 2010 Patrick McHardy <kaber@trash.net> ipv4: ipmr: support multiple tables
This patch adds support for multiple independant multicast routing instances, named "tables".
Userspace multicast routing daemons can bind to a specific table instance by issuing a setsockopt call using a new option MRT_TABLE. The table number is stored in the raw socket data and affects all following ipmr setsockopt(), getsockopt() and ioctl() calls. By default, a single table (RT_TABLE_DEFAULT) is created with a default routing rule pointing to it. Newly created pimreg devices have the table number appended ("pimregX"), with the exception of devices created in the default table, which are named just "pimreg" for compatibility reasons.
Packets are directed to a specific table instance using routing rules, similar to how regular routing rules work. Currently iif, oif and mark are supported as keys, source and destination addresses could be supported additionally.
Example usage:
- bind pimd/xorp/... to a specific table:
uint32_t table = 123; setsockopt(fd, IPPROTO_IP, MRT_TABLE, &table, sizeof(table));
- create routing rules directing packets to the new table:
# ip mrule add iif eth0 lookup 123 # ip mrule add oif eth0 lookup 123
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
|