| Commit message (Collapse) | Author | Age | Files | Lines |
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
the vty_*prepend* family can be used to reduce the amount of output
produced by "show running-config" and "write ...". it buffers output in
struct vty->prepend (1024 bytes) and outputs it when vty_out is called.
if vty_out isn't called, it can be removed with vty_unprepend later.
applied on zebra and ospfd to get rid of empty interface blocks.
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | | |
No, at second thought I don't want it in the list twice...
This reverts commit 43f93a5b3a491052b8206e6d94dd3c986aa9f45b.
|
|\ \ \
| | |/
| |/| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
FLAG_BLACKHOLE is used for different things in different places. remove
it from the zclient API, instead indicate blackhole routes by
ZAPI_MESSAGE_BLACKHOLE, which is converted to the proper zapi indication
by zapi_ipv4_route()
|
|\ \ \
| | | |
| | | |
| | | |
| | | | |
Conflicts:
lib/thread.c
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* The ospf_ase_calculate_timer can take a long time to run, as it scales
O(# of AS-External LSAs), in domains with lots of external routes.
Fix this by using a work-queue for the per-LSA processing, thus splitting
it up a bit.
* ospf_ase.h: (ospf_ase_calculate_route, ospf_ase_calculate_schedule) no
need for these to be exported.
* ospf_spf.c: (ospf_spf_calculate_timer) ospf_ase_calculate_schedule is gone.
* ospfd.h: (struct ospf) add a work-queue for the AS-External route
calculation.
* ospf_ase.c: (ospf_ase_calc_completion) completion func, for when
ase-calculation is done. Also have to take care to see if the timer
needs to be rescheduled, which is the case if ospf->ase_calc is set again
but there is no timer scheduled.
(ospf_ase_calc_process) workqueue processing function, calls to the
existing ospf_ase_calculate_route.
(ospf_ase_calculate_timer) add to work-queue, instead of calling
ospf_ase_calculate_route directly.
(ospf_ase_calculate_timer_add) do the job of ospf_ase_calculate_schedule
which can be removed. Set flag so we can tell if a timer schedule comes
in while the previous timer is running.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* It's possible for the packet output buffer to be filled up with a long
series of non-Hello packets in between Hellos packets, such that the
router's neighbours don't receive the Hello packet in time, even though
the hello-timer ran at about the right time. Fix this by prioritising
Hello packets, letting them skip the queue and go ahead of any packets
already on the queue.
This problem can occur when there are lots of LSAs and slow links.
* ospf_packet.h: (ospf_hello_send_sub) not used outside of ospf_packet.c
* ospf_packet.c: (ospf_fifo_push_head) add packet to head of fifo (so its
no longer really a fifo, but hey)
(ospf_packet_add_top) add packet to top of the packet output queue.
(ospf_hello_send_sub) Put Hello's at the top of the packet output queue.
make it take in_addr_t parameter, so that this
ospf_hello_send can re-use this code too.
(ospf_hello_send) consolidate code by using ospf_hello_send_sub
(ospf_poll_send,ospf_hello_reply_timer) adjust for ospf_hello_send_sub.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* The hello protocol monitors connectivity in 2 different ways:
a) local -> remote
b) remote -> local
Connectivity is required in both directions (2-way) for adjacencies to
form.
The first requires a round-trip to detect, and is done by advertising
which other hosts a router knows about in its hello messages. This allows
a host to detect which other routers are and are not receiving its
message. If a remote neighbour delists the local router, then the local
router raises a "1-Way Received" event.
The latter is straight-forward, and is detected by setting a timer for the
neighbour. If another Hello packet is not received within this time then
the neighbour is dead, and a separate "Inactive" event is raised.
These are 2 different and relatively independent measures.
Knowing that we can optimise the 2nd, remote->local measure and reset
the timer when /any/ packet arrives from that neighbour. For any packet
is as good as a Hello packet. This can help in marginal situations, where
the number of protocol messages that must be sent sometimes can exceed
the capacity of the network to transmit the messages within the configured
dead-time. I.e. an OSPF network with lots of LSAs, slow links and/or
slow hosts (e.g. O(10k) LSAs, O(100kbit) links, embedded CPUs, and O(10s)
dead-times).
This optimisation allows an OSPF network to run closer to this margin,
and/or allows networks to perhaps better cope with rare periods of
exceptional load, where otherwise they would not.
It's fully compatible with plain OSPF implementations and doesn't
prejudice dead-neighbour detection.
* ospf_nsm.h: Rename HelloReceived event to PacketReceived.
* ospf_nsm.c: (nsm_hello_received) -> nsm_packet_received
* ospf_packet.c: Schedule PacketReceived whenever a valid message is
received.
|
| | | | |
|
|\ \ \ \ |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
OSPF compiler warnings:
* remove dead code
* avoid casting int to pointer (instead use unsigned long)
(changes to ospf_ase.c removed by David Lamparter)
Cc: David Lamparter <equinox@diac24.net>
|
|\ \ \ \ \
| | |/ / /
| |/| / /
| |_|/ /
|/| | | |
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
ospfd/ospfd.c
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Maintain router LSA positions in OSPF interface.
Find the OSPF interface in nexthop_calculation using
the position in the router LSA.
This has the following advantages:
- Multiple numbered PtP interfaces with the same IP address
between the same two routers.
- Use Unnumbered PtP on just one end of the link.
- Faster OI lookup for the OSPF interface and only
done once for PtoP links.
*ospf_interface.h: (struct ospf_interface) Add storage for
storing router LSA position.
*ospf_interface.c: (ospf_if_lookup_by_lsa_pos)
lookup OSPF I/F in an area using LSA position.
(ospf_lsa_pos_set) assign LSA position to OSPF
interface.
*ospf_lsa.c: (router_lsa_link_set) Call ospf_lsa_pos_set() to record
LSA position.
*ospf_spf.c: (ospf_spf_next) Count and pass along lsa position.
(ospf_nexthop_calculation) Add lsa position argument.
call ospf_if_lookup_by_lsa_pos() for OSFP interface handle.
Clean up and remove all calls ospf_if_is_configured() the
rest. Adjust a few debug logs.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Add support for real unnumbered PtP interfaces in
ospf_nexthop_calculation().
Add ospf_if_lookup_by_ifindex() to support Unnumbered
PtP links. This version does not support:
- Multiple numbered PtP interfaces with the same IP address
between the same two routers.
- Unnumbered PtP on just one end of the link.
* ospfd/ospf_interface.c: Add ospf_if_lookup_by_ifindex().
* ospfd/ospf_interface.h: ditto.
* ospfd/ospf_spf.c: ospf_nexthop_calculation (), call
ospf_if_lookup_by_ifindex() for Unnumbered
PtP links.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
On Fri, 31 Jul 2009, Joakim Tjernlund wrote:
> How can I do that? ASE is screwing with the P2P route and needs
> some fixing. Perhaps you are suggesting to remove the check in ase
> all togher(delete the whole for loop) and place it somewhere else?
> I haven't looked at that possiblity and I am not convinced that it
> is a good idea either.
Well, what I'm curious about is how you don't see a similar issue
with non-AS-external routes? Indeed, I wonder why we can't just apply
your check much earlier - as/when we add routes to the intra-area
routing table - and just get rid of that complete_direct_routes thing
altogether.
> ASE is forcing a nexthop.s_addr when it should not.
So would this perhaps fix it too (and if so, possibly fix similar
issues with other kinds of routes too)?:
REPLACES "External routes over PtoP must be directly connected."
by Joakim Tjernlund
As all locally routes over PtoP interfaces are interface routes,
one must also make sure that external routes over PtoP interfaces
are directly connected.
Cc: David Lamparter <equinox@diac24.net>
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Freeing the area resets all LSAs seq number. Wait
until the area has no more configured interfaces before freeing
it. PPP intefaces are usally deleted when they go down and created
again when the come up. Avoid freeing the area and resetting
the seq number due to number of active interfaces drops to
zero temporairly.
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Use with interface command:
interface ppp0
ip ospf area 0.0.0.0
This will enable OSPF on ppp0 with area 0.0.0.0
Remove with "no ip ospf area"
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
According to Acee Lindem, chairing the OSPF WG on IETF,
one should not transmit Option 1 as described in 12.4.1.1.
The text is unfortunately a bit unclear but the intention
of the spec was not to emit Option 1 (nor Option 2)
Changed to use CHECK_FLAG by David Lamparter.
Cc: David Lamparter <equinox@diac24.net>
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
In lsa_link_ptop_set() and add ifindex to LSA if set.
Changed to use CHECK_FLAG by David Lamparter.
Cc: David Lamparter <equinox@diac24.net>
|
| | |/ /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Use interface <ifname>
"unnumbered" command to set unnumbered mode.
"no unnumbered" will clear it.
Changed to use *_FLAG macros by David Lamparter.
Cc: David Lamparter <equinox@diac24.net>
|
| |\ \ \
| | | |/
| | |/| |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
According to RFC 2328, section 10.5 PointToPoint neighbors
should be identified by router ID instead of source IP address.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
ospf_snmp.c uses ospf_neighbor->address and still has the route_nodes
list code. fix it up to match current code.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
address is the same as src so it is redundant.
This will save both memory and CPU when processing Hellos.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
ospf_opaque.c needs to be updated for moving from route_node to a
regular list.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
It is wasteful to use route nodes for something
as simple as a neighbor list.
Replace with a list.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
ospf_nbr_lookup_by_addr() included routerID while searching.
That is not the intention of this function so change it
to only search for IP addresses.
|
| | |/
| | |
| | |
| | |
| | | |
The 2 last bullets in RFC 2328, section 10.5 are mutually
exclusive, make is so.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Add static host routes into router LSA.
See RFC 2328 chapter 12.4 and Appendix C.7
Syntax:
router ospf
ip ospf host A.B.C.D area (A.B.C.D|<0-4294967295>|all) cost <0-65535>
no ip ospf host A.B.C.D area (A.B.C.D|<0-4294967295>|all)
* ospfd/ospf_route.h: Add struct ospf_host_route
* ospfd/ospf_lsa.c: (router_lsa_link_set) Add host routes to Router LSA.
* ospfd/ospf_vtc.c: Impl. ip_ospf_host_cmd and no_ip_ospf_host_cmd.
(ospf_config_write) Write out host routes to config.
* ospfd/ospf_ospfd.c: (ospf_new) Allocate new host route list.
(ospf_finish_filnal) Free host list.
(ospf_area_check_free) Check if any host routes in
area before freeing.
* ospfd/ospf_ospfd.h: Add a host list to struct ospf.
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This looks fishy in ospf_make_md5_digest()
if (list_isempty (OSPF_IF_PARAM (oi, auth_crypt)))
auth_key = (const u_int8_t *) "";
...
MD5Update(&ctx, auth_key, OSPF_AUTH_MD5_SIZE);
auth_key points to a "" string of len 1 which is a lot
smaller that OSPF_AUTH_MD5_SIZE. Is this intentional to
get some random data or just a plain bug?
Anyone using MD5 should have a closer look and decide
what to do.
|
| |
| |
| |
| |
| |
| | |
this uses the path_state helper for determining the path of quagga's
zserv.api socket. this allows for running multiple instances of zebra
each with its own interface.
|
| |
| |
| |
| |
| |
| | |
use the path_state helper functions for determining vty socket paths in
all quagga daemons. this allows for running multiple daemons if a
namespace name is set.
|
|/
|
|
|
|
|
| |
this replaces most occurences of routing protocol lists by preprocessor
defines from route_types.h. the latter is autogenerated from
route_types.txt by a perl script (previously awk). adding a routing
protocol now is mostly a matter of changing route_types.txt and log.c.
|
|
|
|
|
| |
* ospf_packet.c: (ospf_ls_upd) DISCARD_LSA continues, and so should be
after debug messages, not before them.
|
|
|
|
|
|
| |
* ospf_lsdb.c: (lsdb_prefix_set) memset is unneeded, as all fields are
initialised explicitly, and this function can be in the top-3 of a
profile when there are a lot of LSAs.
|
|
|
|
| |
Several bits of text can be local or are unused.
|
| |
|
|
|
|
|
|
|
|
|
| |
This code is only used one place and can be made local.
Gcc is smart enough to inline local functions if it wants to.
The function also has a big chunk of compatiablity code that
is no longer used; since quagga is now in a version control system
the source does not need to be used as a historical reference.
|
|
|
|
|
|
|
|
|
|
|
|
| |
The following syntax forms were not historically supported
by Quagga, although IOS accepted them w/o a problem:
no ip ospf cost <1-65535>
no ospf cost <1-65535>
no ip ospf cost <1-65535> A.B.C.D
no ospf cost <1-65535> A.B.C.D
From now on Quagga also supports these variants.
|
|
|
|
|
| |
* ospf_ism.c (ospf_dr_eligible_routers) should test for priority > 0 instead
of != 0 as ospf_nbr_new () initially sets prio to -1
|
|
|
|
|
|
| |
* ospf_zebra.c: (ospf_distribute_check_connected) check to make filter out
routes matching connected routes was matching against OSPF networks, which
can be far more general than the actual connected interfaces. Fix.
|
|
|
|
|
|
| |
* */*main.c: (main) Current versions of Gcc warn if the return value for
daemon() is not checked. So add a simple test and exit on failure.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Doing redistribute delete with full BGP table was taking
30 minutes, this drops it down to less than a second.
* ospf_lsa.c: (ospf_lsa_maxage) When flushing lots of entries the
performance is terrible because it looks up each LSA entry through
ospf_lsa_maxage_exist before deleting causing O(N^2) performance. Use a
new OSPF_LSA_MAXAGE flag instead of scan - and maintain it.
(ospf_lsa_maxage_exist) removed
(ospf_lsa_maxage_delete) maintain OSPF_LSA_MAXAGE flag
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In some cases ospfd does not recalc the route table. This
happens when ospfd receives an old LSA which will trigger
recalc but the this recalc will fail because all interfaces
isn't up yet. Next LSA that is originated matches the old one
so no recalc will be performed. This problem has been observed
when there are only 2 ppp I/Fs in an area, both go down at the
same time, then they come up again with a few seconds apart.
* ospf_lsa.c: (ospf_{router,network}_lsa_install) avoid a needless scheduling
of SPF.
(ospf_lsa_different) fix bug in LSA comparison that would lead to the
described failure to schedule SPF.
|
|
|
|
|
|
| |
* ospf_packet.c: make this message conditional on 'debug ospf event', as it
be easily triggered with, e.g., multiple subnets sharing same physical
network. E.g, see bug #532.
|