networkd: dhcp - use same metric for all DHCP-related routes

This commit is contained in:
Tom Gundersen 2014-06-29 23:47:13 +02:00
parent 6afeb1cfe4
commit 3e53303ea6
2 changed files with 3 additions and 0 deletions

1
TODO
View File

@ -615,6 +615,7 @@ Features:
- add veth netdev support (c.f. http://shorewall.net/bridge-Shorewall-perl.html#veth) - add veth netdev support (c.f. http://shorewall.net/bridge-Shorewall-perl.html#veth)
- add tun/tap netdev support - add tun/tap netdev support
- add more attribute support for SIT tunnel - add more attribute support for SIT tunnel
- make metric of routes configurable
* networkd-wait-online: * networkd-wait-online:
- make operstates to wait for configurable? - make operstates to wait for configurable?

View File

@ -546,6 +546,7 @@ static int link_enter_set_routes(Link *link) {
route_gw->dst_addr.in = gateway; route_gw->dst_addr.in = gateway;
route_gw->dst_prefixlen = 32; route_gw->dst_prefixlen = 32;
route_gw->scope = RT_SCOPE_LINK; route_gw->scope = RT_SCOPE_LINK;
route_gw->metrics = DHCP_STATIC_ROUTE_METRIC;
r = route_configure(route_gw, link, &route_handler); r = route_configure(route_gw, link, &route_handler);
if (r < 0) { if (r < 0) {
@ -559,6 +560,7 @@ static int link_enter_set_routes(Link *link) {
route->family = AF_INET; route->family = AF_INET;
route->in_addr.in = gateway; route->in_addr.in = gateway;
route->metrics = DHCP_STATIC_ROUTE_METRIC;
r = route_configure(route, link, &route_handler); r = route_configure(route, link, &route_handler);
if (r < 0) { if (r < 0) {