summaryrefslogtreecommitdiffstats
path: root/ospfd/ospf_asbr.h
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2015-05-20 03:03:42 +0200
committerDonald Sharp <sharpd@cumulusnetworks.com>2015-05-20 03:03:42 +0200
commit7c8ff89e9346227f0e721f7686d4c4d58f9c9135 (patch)
tree7a5f73baf68e31220396e2391cdd216cdf981d51 /ospfd/ospf_asbr.h
parentinitd: initd-mi.patch (diff)
downloadfrr-7c8ff89e9346227f0e721f7686d4c4d58f9c9135.tar.xz
frr-7c8ff89e9346227f0e721f7686d4c4d58f9c9135.zip
Multi-Instance OSPF Summary
——————————————------------- - etc/init.d/quagga is modified to support creating separate ospf daemon process for each instance. Each individual instance is monitored by watchquagga just like any protocol daemons.(requires initd-mi.patch). - Vtysh is modified to able to connect to multiple daemons of the same protocol (supported for OSPF only for now). - ospfd is modified to remember the Instance-ID that its invoked with. For the entire life of the process it caters to any command request that matches that instance-ID (unless its a non instance specific command). Routes/messages to zebra are tagged with instance-ID. - zebra route/redistribute mechanisms are modified to work with [protocol type + instance-id] - bgpd now has ability to have multiple instance specific redistribution for a protocol (OSPF only supported/tested for now). - zlog ability to display instance-id besides the protocol/daemon name. - Changes in other daemons are to because of the needed integration with some of the modified APIs/routines. (Didn’t prefer replicating too many separate instance specific APIs.) - config/show/debug commands are modified to take instance-id argument as appropriate. Guidelines to start using multi-instance ospf --------------------------------------------- The patch is backward compatible, i.e for any previous way of single ospf deamon(router ospf <cr>) will continue to work as is, including all the show commands etc. To enable multiple instances, do the following: 1. service quagga stop 2. Modify /etc/quagga/daemons to add instance-ids of each desired instance in the following format: ospfd=“yes" ospfd_instances="1,2,3" assuming you want to enable 3 instances with those instance ids. 3. Create corresponding ospfd config files as ospfd-1.conf, ospfd-2.conf and ospfd-3.conf. 4. service quagga start/restart 5. Verify that the deamons are started as expected. You should see ospfd started with -n <instance-id> option. ps –ef | grep quagga With that /var/run/quagga/ should have ospfd-<instance-id>.pid and ospfd-<instance-id>/vty to each instance. 6. vtysh to work with instances as you would with any other deamons. 7. Overall most quagga semantics are the same working with the instance deamon, like it is for any other daemon. NOTE: To safeguard against errors leading to too many processes getting invoked, a hard limit on number of instance-ids is in place, currently its 5. Allowed instance-id range is <1-65535> Once daemons are up, show running from vtysh should show the instance-id of each daemon as 'router ospf <instance-id>’ (without needing explicit configuration) Instance-id can not be changed via vtysh, other router ospf configuration is allowed as before. Signed-off-by: Vipin Kumar <vipin@cumulusnetworks.com> Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com> Reviewed-by: Dinesh G Dutt <ddutt@cumulusnetworks.com>
Diffstat (limited to 'ospfd/ospf_asbr.h')
-rw-r--r--ospfd/ospf_asbr.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/ospfd/ospf_asbr.h b/ospfd/ospf_asbr.h
index bb773c979..ade671013 100644
--- a/ospfd/ospf_asbr.h
+++ b/ospfd/ospf_asbr.h
@@ -35,6 +35,8 @@ struct external_info
/* Type of source protocol. */
u_char type;
+ u_short instance;
+
/* Prefix. */
struct prefix_ipv4 p;
@@ -55,23 +57,23 @@ struct external_info
#define OSPF_ASBR_CHECK_DELAY 30
extern void ospf_external_route_remove (struct ospf *, struct prefix_ipv4 *);
-extern struct external_info *ospf_external_info_new (u_char);
+extern struct external_info *ospf_external_info_new (u_char, u_short);
extern void ospf_reset_route_map_set_values (struct route_map_set_values *);
extern int ospf_route_map_set_compare (struct route_map_set_values *,
struct route_map_set_values *);
-extern struct external_info *ospf_external_info_add (u_char,
+extern struct external_info *ospf_external_info_add (u_char, u_short,
struct prefix_ipv4,
unsigned int,
struct in_addr,
u_short);
-extern void ospf_external_info_delete (u_char, struct prefix_ipv4);
-extern struct external_info *ospf_external_info_lookup (u_char,
+extern void ospf_external_info_delete (u_char, u_short, struct prefix_ipv4);
+extern struct external_info *ospf_external_info_lookup (u_char, u_short,
struct prefix_ipv4 *);
extern struct ospf_route *ospf_external_route_lookup (struct ospf *,
struct prefix_ipv4 *);
extern void ospf_asbr_status_update (struct ospf *, u_char);
-extern void ospf_redistribute_withdraw (struct ospf *, u_char);
+extern void ospf_redistribute_withdraw (struct ospf *, u_char, u_short);
extern void ospf_asbr_check (void);
extern void ospf_schedule_asbr_check (void);
extern void ospf_asbr_route_install_lsa (struct ospf_lsa *);