ret = bgp_get(&bgp, &as, name, inst_type);
switch (ret) {
- case BGP_ERR_MULTIPLE_INSTANCE_NOT_SET:
- vty_out(vty,
- "Please specify 'bgp multiple-instance' first\n");
- return CMD_WARNING_CONFIG_FAILED;
case BGP_ERR_AS_MISMATCH:
vty_out(vty, "BGP is already running; AS is %u\n", as);
return CMD_WARNING_CONFIG_FAILED;
{
int ret;
struct peer *peer;
- struct route_map *route_map;
+ struct route_map *route_map = NULL;
peer = peer_and_group_lookup_vty(vty, peer_str);
if (!peer)
return CMD_WARNING_CONFIG_FAILED;
if (set) {
- route_map = route_map_lookup_warn_noexist(vty, rmap);
+ if (rmap)
+ route_map = route_map_lookup_warn_noexist(vty, rmap);
ret = peer_default_originate_set(peer, afi, safi,
rmap, route_map);
} else
count * sizeof(struct peer_group)));
/* Other */
- if ((count = mtype_stats_alloc(MTYPE_HASH)))
- vty_out(vty, "%ld hash tables, using %s of memory\n", count,
- mtype_memstr(memstrbuf, sizeof(memstrbuf),
- count * sizeof(struct hash)));
- if ((count = mtype_stats_alloc(MTYPE_HASH_BACKET)))
- vty_out(vty, "%ld hash buckets, using %s of memory\n", count,
- mtype_memstr(memstrbuf, sizeof(memstrbuf),
- count * sizeof(struct hash_bucket)));
if ((count = mtype_stats_alloc(MTYPE_BGP_REGEXP)))
vty_out(vty, "%ld compiled regexes, using %s of memory\n",
count, mtype_memstr(memstrbuf, sizeof(memstrbuf),
DEFUN (no_bgp_redistribute_ipv4_ospf,
no_bgp_redistribute_ipv4_ospf_cmd,
- "no redistribute <ospf|table> (1-65535) [metric (0-4294967295)] [route-map WORD]",
+ "no redistribute <ospf|table> (1-65535) [{metric (0-4294967295)|route-map WORD}]",
NO_STR
"Redistribute information from another routing protocol\n"
"Open Shortest Path First (OSPFv2)\n"
ALIAS_HIDDEN(
no_bgp_redistribute_ipv4_ospf, no_bgp_redistribute_ipv4_ospf_hidden_cmd,
- "no redistribute <ospf|table> (1-65535) [metric (0-4294967295)] [route-map WORD]",
+ "no redistribute <ospf|table> (1-65535) [{metric (0-4294967295)|route-map WORD}]",
NO_STR
"Redistribute information from another routing protocol\n"
"Open Shortest Path First (OSPFv2)\n"
DEFUN (no_bgp_redistribute_ipv4,
no_bgp_redistribute_ipv4_cmd,
- "no redistribute " FRR_IP_REDIST_STR_BGPD " [metric (0-4294967295)] [route-map WORD]",
+ "no redistribute " FRR_IP_REDIST_STR_BGPD " [{metric (0-4294967295)|route-map WORD}]",
NO_STR
"Redistribute information from another routing protocol\n"
FRR_IP_REDIST_HELP_STR_BGPD
ALIAS_HIDDEN(
no_bgp_redistribute_ipv4, no_bgp_redistribute_ipv4_hidden_cmd,
"no redistribute " FRR_IP_REDIST_STR_BGPD
- " [metric (0-4294967295)] [route-map WORD]",
+ " [{metric (0-4294967295)|route-map WORD}]",
NO_STR
"Redistribute information from another routing protocol\n" FRR_IP_REDIST_HELP_STR_BGPD
"Metric for redistributed routes\n"
DEFUN (no_bgp_redistribute_ipv6,
no_bgp_redistribute_ipv6_cmd,
- "no redistribute " FRR_IP6_REDIST_STR_BGPD " [metric (0-4294967295)] [route-map WORD]",
+ "no redistribute " FRR_IP6_REDIST_STR_BGPD " [{metric (0-4294967295)|route-map WORD}]",
NO_STR
"Redistribute information from another routing protocol\n"
FRR_IP6_REDIST_HELP_STR_BGPD