mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-07 23:58:44 +00:00
Merge pull request #9231 from idryzhov/zebra-rmap-set-src
zebra: remove checks for src address existence when using "set src"
This commit is contained in:
commit
11093fc905
@ -908,10 +908,11 @@ IPv6 example for OSPFv3.
|
|||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
For both IPv4 and IPv6, the IP address has to exist at the point the
|
For both IPv4 and IPv6, the IP address has to exist on some interface when
|
||||||
route-map is created. Be wary of race conditions if the interface is
|
the route is getting installed into the system. Otherwise, kernel rejects
|
||||||
not created at startup. On Debian, FRR might start before ifupdown
|
the route. To solve the problem of disappearing IPv6 addresses when the
|
||||||
completes. Consider a reboot test.
|
interface goes down, use ``net.ipv6.conf.all.keep_addr_on_down``
|
||||||
|
:ref:`sysctl option <zebra-sysctl>`.
|
||||||
|
|
||||||
.. clicmd:: zebra route-map delay-timer (0-600)
|
.. clicmd:: zebra route-map delay-timer (0-600)
|
||||||
|
|
||||||
@ -1238,6 +1239,8 @@ For protocols requiring an IPv6 router-id, the following commands are available:
|
|||||||
|
|
||||||
Display the user configured IPv6 router-id.
|
Display the user configured IPv6 router-id.
|
||||||
|
|
||||||
|
.. _zebra-sysctl:
|
||||||
|
|
||||||
Expected sysctl settings
|
Expected sysctl settings
|
||||||
========================
|
========================
|
||||||
|
|
||||||
|
@ -247,9 +247,7 @@ lib_route_map_entry_set_action_rmap_set_action_ipv4_src_address_modify(
|
|||||||
struct nb_cb_modify_args *args)
|
struct nb_cb_modify_args *args)
|
||||||
{
|
{
|
||||||
struct routemap_hook_context *rhc;
|
struct routemap_hook_context *rhc;
|
||||||
struct interface *pif = NULL;
|
|
||||||
const char *source;
|
const char *source;
|
||||||
struct vrf *vrf;
|
|
||||||
struct prefix p;
|
struct prefix p;
|
||||||
int rv;
|
int rv;
|
||||||
|
|
||||||
@ -262,18 +260,6 @@ lib_route_map_entry_set_action_rmap_set_action_ipv4_src_address_modify(
|
|||||||
yang_dnode_get_string(args->dnode, NULL));
|
yang_dnode_get_string(args->dnode, NULL));
|
||||||
return NB_ERR_VALIDATION;
|
return NB_ERR_VALIDATION;
|
||||||
}
|
}
|
||||||
|
|
||||||
RB_FOREACH(vrf, vrf_id_head, &vrfs_by_id) {
|
|
||||||
pif = if_lookup_exact_address(&p.u.prefix4, AF_INET,
|
|
||||||
vrf->vrf_id);
|
|
||||||
if (pif != NULL)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if (pif == NULL) {
|
|
||||||
zlog_warn("%s: is not a local address: %s", __func__,
|
|
||||||
yang_dnode_get_string(args->dnode, NULL));
|
|
||||||
return NB_ERR_VALIDATION;
|
|
||||||
}
|
|
||||||
return NB_OK;
|
return NB_OK;
|
||||||
case NB_EV_PREPARE:
|
case NB_EV_PREPARE:
|
||||||
case NB_EV_ABORT:
|
case NB_EV_ABORT:
|
||||||
@ -325,9 +311,7 @@ lib_route_map_entry_set_action_rmap_set_action_ipv6_src_address_modify(
|
|||||||
struct nb_cb_modify_args *args)
|
struct nb_cb_modify_args *args)
|
||||||
{
|
{
|
||||||
struct routemap_hook_context *rhc;
|
struct routemap_hook_context *rhc;
|
||||||
struct interface *pif = NULL;
|
|
||||||
const char *source;
|
const char *source;
|
||||||
struct vrf *vrf;
|
|
||||||
struct prefix p;
|
struct prefix p;
|
||||||
int rv;
|
int rv;
|
||||||
|
|
||||||
@ -340,18 +324,6 @@ lib_route_map_entry_set_action_rmap_set_action_ipv6_src_address_modify(
|
|||||||
yang_dnode_get_string(args->dnode, NULL));
|
yang_dnode_get_string(args->dnode, NULL));
|
||||||
return NB_ERR_VALIDATION;
|
return NB_ERR_VALIDATION;
|
||||||
}
|
}
|
||||||
|
|
||||||
RB_FOREACH(vrf, vrf_id_head, &vrfs_by_id) {
|
|
||||||
pif = if_lookup_exact_address(&p.u.prefix6, AF_INET6,
|
|
||||||
vrf->vrf_id);
|
|
||||||
if (pif != NULL)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if (pif == NULL) {
|
|
||||||
zlog_warn("%s: is not a local address: %s", __func__,
|
|
||||||
yang_dnode_get_string(args->dnode, NULL));
|
|
||||||
return NB_ERR_VALIDATION;
|
|
||||||
}
|
|
||||||
return NB_OK;
|
return NB_OK;
|
||||||
case NB_EV_PREPARE:
|
case NB_EV_PREPARE:
|
||||||
case NB_EV_ABORT:
|
case NB_EV_ABORT:
|
||||||
|
Loading…
Reference in New Issue
Block a user