summaryrefslogtreecommitdiffstats
path: root/isisd (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
| * | isisd: Add log-pdu-drops log functionalityIsabella de Leon2023-04-044-17/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If log-pdu-drops is configured, create an INFO log that displays the PDU type and drop counts when a PDU drop is detected. Example logs: 2023/03/30 23:54:59.749 ISIS: [VAS9N-1JNNR] PDU drop detected of type: P2P IIH. 1 Total Drops; 0 L1 IIH drops; 0 L2 IIH drops; 1 P2P IIH drops; 0 L1 LSP drops; 0 L2 LSP drops; 0 FS LSP drops; 0 L1 CSNP drops; 0 L2 CSNP drops; 0 L1 PSNP drops; 0 L2 PSNP drops. 2023/03/30 23:54:59.848 ISIS: [VAS9N-1JNNR] PDU drop detected of type: P2P IIH. 2 Total Drops; 0 L1 IIH drops; 0 L2 IIH drops; 2 P2P IIH drops; 0 L1 LSP drops; 0 L2 LSP drops; 0 FS LSP drops; 0 L1 CSNP drops; 0 L2 CSNP drops; 0 L1 PSNP drops; 0 L2 PSNP drops. Code changes: Add a new PDU counter function that increments the drop counter and runs the logging functionality if log-pdu-drops is configured. Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
| * | isisd: Add log-pdu-drops CLI/YANG supportIsabella de Leon2023-04-045-0/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New config functionality: r1# conf r1(config)# router isis 1 r1(config-router)# log- log-adjacency-changes Log changes in adjacency state log-pdu-drops Log any dropped PDUs r1(config-router)# log-pdu-drops r1(config-router)# end Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
* | | Merge pull request #12698 from Orange-OpenSource/isisdRuss White2023-04-1124-449/+329
|\ \ \ | | | | | | | | Isisd/Lib: Add new printfrr format facility for Intermediate System ID
| * | | isisd: Update to the new printfrr ISO formatOlivier Dugeon2023-03-2124-449/+329
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This path replaces isisd_format_id, sysid_print, snpa_print, rawlspid_print and isonet_print functions by the new printfrr ISO System ID & Network Address format facilities. It also updates the isisd code to the new iso_address structure defined in lib/iso.h Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
* | | | *: Use a `struct prefix *p` instead of a `struct prefix` in functionsDonald Sharp2023-04-071-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When passing a prefix into a function let's pass by address instead of pass by value. Let's save our stack space. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | | | isisd: consider link local ipv4 addresses as validPhilippe Guibert2023-04-041-2/+1
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is not possible to create an adjacency by using interface addresses within the `169.254.0.0/24` pool. When forging the IIH messages, the interface addresses from that pool are not appended: > Neither IPv4 nor IPv6 considered usable. Ignoring IIH Using this network pool is possible on other IS-IS implementations. Let us authorize to use such network addresses. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
* | | isisd, zebra: Use array_size instead of ARRAY_SIZEDonald Sharp2023-03-311-47/+42
| | | | | | | | | | | | | | | | | | Use the FRR provided array_size. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | | isisd: Correction of subnets creation in the TEDOlivier Dugeon2023-03-301-1/+14
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Subnets may be incorrectly created in the IS-IS Traffic Engineering Database (TED). Indeed, to be usable, the subnets advertised by IS-IS peers must be adjusted to avoid misinterpretation. For example, consider R1 which is connected to R2 with IP addresses 10.0.0.1/24 (R1) and 10.0.0.2/24 (R2). R1 and R2 will advertize the prefix 10.0.0.0/24. By leaving the subnet with the prefix 10.0.0.0/24 in the TED, it is not possible to determine whether 10.0.0.1 is attached to R1 or R2 or whether 10.0.0.3 exists. So to avoid this, the subnet prefixes are adjusted with the IP addresses of the local interface. But IS-IS can start to advertise the subnet when not all adjacencies are up, especially when IPv4 and IPv6 are configured on the same interface. This results in an uncorrected prefix, e.g. 10.0.0.0/24, remaining in the TED when it should be removed. This problem affects some isis-related tests such as the CSPF test. This patch fixes this bug by removing the uncorrected prefix before adding the the corrected version. Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
* | isisd: Add PDU drop counter to "show isis summary"Isabella de Leon2023-03-293-4/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adding a new drop counters section to "show isis summary". New output: Drop counters per PDU type: P2P IIH: <count> L2 LSP: <count> L2 CSNP: <count> L2 PSNP: <count> ... Before: r1# show isis summary vrf : default Process Id : 972 System Id : 0000.0000.0001 Up time : 00:00:48 ago Number of areas : 1 Area TE: Net: 49.0000.0000.0000.0001.00 TX counters per PDU type: P2P IIH: 36 L2 LSP: 8 L2 CSNP: 12 L2 PSNP: 11 RX counters per PDU type: P2P IIH: 37 L2 LSP: 17 L2 CSNP: 12 L2 PSNP: 6 Advertise high metrics: Disabled ... After: r1# show isis summary vrf : default Process Id : 972 System Id : 0000.0000.0001 Up time : 00:00:19 ago Number of areas : 1 Area TE: Net: 49.0000.0000.0000.0001.00 TX counters per PDU type: P2P IIH: 16 L2 LSP: 2 L2 CSNP: 4 L2 PSNP: 6 LSP RXMT: 0 RX counters per PDU type: P2P IIH: 16 L2 LSP: 5 L2 CSNP: 4 L2 PSNP: 2 Drop counters per PDU type: P2P IIH: 2 Advertise high metrics: Disabled ... Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
* | *: Convert event.h to frrevent.hDonald Sharp2023-03-2416-16/+16
| | | | | | | | | | | | | | We should probably prevent any type of namespace collision with something else. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert `struct event_master` to `struct event_loop`Donald Sharp2023-03-248-11/+11
| | | | | | | | | | | | Let's find a better name for it. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert THREAD_XXX macros to EVENT_XXX macrosDonald Sharp2023-03-2415-83/+83
| | | | | | | | Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert struct thread_master to struct event_master and it's ilkDonald Sharp2023-03-248-11/+11
| | | | | | | | | | | | | | Convert the `struct thread_master` to `struct event_master` across the code base. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert a bunch of thread_XX to event_XXDonald Sharp2023-03-242-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | Convert these functions: thread_getrusage thread_cmd_init thread_consumed_time thread_timer_to_hhmmss thread_is_scheduled thread_ignore_late_timer Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert thread_timer_remain_XXX to event_timer_remain_XXXDonald Sharp2023-03-244-6/+6
| | | | | | | | Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert thread_cancelXXX to event_cancelXXXDonald Sharp2023-03-242-2/+2
| | | | | | | | | | | | Modify the code base so that thread_cancel becomes event_cancel Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Convert thread_add_XXX functions to event_add_XXXDonald Sharp2023-03-2415-141/+131
| | | | | | | | Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Rename `struct thread` to `struct event`Donald Sharp2023-03-2422-63/+62
| | | | | | | | | | | | | | | | | | Effectively a massive search and replace of `struct thread` to `struct event`. Using the term `thread` gives people the thought that this event system is a pthread when it is not Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Rename thread.[ch] to event.[ch]Donald Sharp2023-03-2416-16/+16
| | | | | | | | | | | | | | | | | | | | | | This is a first in a series of commits, whose goal is to rename the thread system in FRR to an event system. There is a continual problem where people are confusing `struct thread` with a true pthread. In reality, our entire thread.c is an event system. In this commit rename the thread.[ch] files to event.[ch]. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* | *: Add a hash_clean_and_free() functionDonald Sharp2023-03-212-9/+3
|/ | | | | | | | | | Add a hash_clean_and_free() function as well as convert the code to use it. This function also takes a double pointer to the hash to set it NULL. Also it cleanly does nothing if the pointer is NULL( as a bunch of code tested for ). Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* Merge pull request #12688 from dorDiogo/isis_hello_padding_sometimesRuss White2023-03-208-27/+79
|\ | | | | isisd: Add support for IS-IS hello padding during-adjacency-formation
| * isisd,tests,doc: Rename hello padding sometimes to hello padding ↵Diogo Oliveira2023-02-286-10/+12
| | | | | | | | | | | | during-adjacency-formation Signed-off-by: Diogo Oliveira <14191454+dorDiogo@users.noreply.github.com>
| * isisd: Add support for isis hello padding sometimesDiogo Oliveira2023-02-288-27/+77
| | | | | | | | | | | | New configuration to pad ISIS hello packets during adjacency formation only. Signed-off-by: Diogo Oliveira <14191454+dorDiogo@users.noreply.github.com>
* | isisd: pfpacket BPF filter with IS-IS over tunnel supportJosef Miegl2023-03-121-8/+19
| | | | | | | | Signed-off-by: Josef Miegl <josef@miegl.cz>
* | isisd: Add advertise high metrics base functionalityIsabella de Leon2023-02-282-1/+51
| | | | | | | | | | | | Implement advertise-high-metrics set function - when advertise-high-metrics is configured, iterate through each isis interface and update each metric to its high metric value. When advertise-high-metrics is disabled, revert each interface's metric to its originally configured value. Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
* | isisd: Add advertise-high-metrics CLI/YANG support, modify show outputIsabella de Leon2023-02-286-0/+67
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New config and show functionality: r1# conf r1(config)# router isis 1 r1(config-router)# advertise-high-metrics Advertise high metric value on all interfaces area-password Configure the authentication password for an area ... r1(config-router)# advertise-high-metrics r1(config-router)# end r1# show isis summary ... Area 1: Net: 49.0001.1720.1700.0002.00 TX counters per PDU type: L2 IIH: 1 P2P IIH: 36 LSP RXMT: 0 RX counters per PDU type: Advertise high metrics: Enabled Level-2: ... r1# conf r1(config)# router isis 1 r1(config-router)# no advertise-high-metrics r1(config-router)# end r1# show isis summary ... Area 1: Net: 49.0001.1720.1700.0002.00 TX counters per PDU type: L2 IIH: 1 P2P IIH: 45 LSP RXMT: 0 RX counters per PDU type: Advertise high metrics: Disabled Level-2: ... r1# Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
* Merge pull request #12840 from dorDiogo/isis_advertise_passive_onlyRuss White2023-02-286-0/+64
|\ | | | | isisd: Add support for IS-IS advertise-passive-only
| * isisd,doc: Add support for isis advertise-passive-onlyDiogo Oliveira2023-02-226-0/+64
| | | | | | | | Signed-off-by: Diogo Oliveira <14191454+dorDiogo@users.noreply.github.com>
* | Merge pull request #12819 from isabelladeleon12/isis_load_config_before_lsp_genRuss White2023-02-284-0/+56
|\ \ | |/ |/| isisd: Delay lsp generation to after config processing is complete
| * isisd: Fix isisd to generate lsps after config processing is completeIsabella de Leon2023-02-214-0/+56
| | | | | | | | | | | | | | | | | | | | Before: isisd generates its initial lsp before fully processing the written config. Ex: lsp_generate() is called in isis_instance_area_address_create(), before other configs that may affect the lsp are loaded in, like set-overload-bit. After: isisd generates its initial lsp as soon as the config is fully processed. This was done by utilizing the initialization config callbacks, similar to bgp's implementation. Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
* | Merge pull request #12780 from opensourcerouting/spdx-license-idDonald Sharp2023-02-1772-1018/+72
|\ \ | |/ |/| *: convert to SPDX License identifiers
| * *: auto-convert to SPDX License IDsDavid Lamparter2023-02-0972-1018/+72
| | | | | | | | | | | | Done with a combination of regex'ing and banging my head against a wall. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* | Merge pull request #12494 from louis-6wind/ext_admin_groupOlivier Dugeon2023-02-154-1/+90
|\ \ | | | | | | lib,zebra,isisd: add support for extended admin group RFC7308
| * | lib,isisd: add extended admin-group info into the tedLouis Scalbert2023-02-101-0/+5
| | | | | | | | | | | | | | | | | | Add extended admin-group info into the ted. Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
| * | isisd: add extended admin-groupLouis Scalbert2023-02-103-1/+79
| | | | | | | | | | | | | | | | | | | | | Add to the Extended IS Reachability TLV the support of Extended Administrative-Groups (RFC7308) Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
| * | isisd: add affinity-map supportLouis Scalbert2023-02-091-0/+6
| | | | | | | | | | | | | | | | | | Add the support of the affinity-map command to isisd. Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
* | | lib,zebra,bgpd,staticd: use label code to store VNI infoStephen Worley2023-02-141-2/+3
|/ / | | | | | | | | | | | | | | | | | | | | | | | | Use the already existing mpls label code to store VNI info for vxlan. VNI's are defined as labels just like mpls, we should be using the same code for both. This patch is the first part of that. Next we will need to abstract the label code to not be so mpls specific. Currently in this, we are just treating VXLAN as a label type and storing it that way. Signed-off-by: Stephen Worley <sworley@nvidia.com>
* | Merge pull request #12730 from louis-6wind/fix-ext-te-metricsOlivier Dugeon2023-02-093-3/+3
|\ \ | |/ |/| Fix for Extended TE metrics
| * isisd: use the te anormal macroLouis Scalbert2023-02-021-1/+1
| | | | | | | | | | | | Use the te anormal macro Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
| * isisd: fix te link delay displayLouis Scalbert2023-02-022-2/+2
| | | | | | | | | | | | | | | | Apply the TE_EXT_MASK mask to display a 24 bits instead of a wrong 32 bits value that includes unrelated bits. Fixes: 1b3f47d04c ("isisd: Update TLVs processing for TE, RI & SR") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
* | isisd: Add missing enum's to switch statementDonald Sharp2023-01-315-12/+29
|/ | | | Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* *: fix non-const northbound XPath format stringsDavid Lamparter2023-01-271-2/+2
| | | | | | | Passing a pre-formatted buffer in these places needs a `"%s"` in front so it doesn't get formatted twice. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* Merge pull request #12682 from opensourcerouting/time-csRuss White2023-01-241-2/+4
|\ | | | | *: fix time truncation in many places
| * isisd: fix time truncation on displayRafael Zalamena2023-01-231-2/+4
| | | | | | | | | | | | | | | | | | Use a larger storage to keep the `time_t` that is platform agnostic and use the appropriated printing primitive. Found by Coverity Scan (CID 1519793) Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
* | isisd: changed to output the LAN-adjacency-sid in yang formatkanaya5162023-01-043-11/+180
| | | | | | | | Signed-off-by: kanaya516 <abcs516tk1@gmail.com>
* | isisd: changed to output the adjacency-sid in yang formatkanaya5162023-01-043-0/+143
|/ | | | Signed-off-by: kanaya516 <abcs516tk1@gmail.com>
* isisd: Fix sadj memory leakDonald Sharp2022-12-091-0/+2
| | | | | | In some cases the sadj was directly dropped. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* isisd: fix area NULL pointer in isis_route_updateLouis Scalbert2022-11-171-6/+7
| | | | | | | Fix the case area is NULL. Fixes: acc0029779 ("isisd: fix potential access to NULL pointer in isis_route_update") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
* Merge pull request #11594 from louis-6wind/lfa-netlinkPushpasis Sarkar2022-11-0811-31/+229
|\ | | | | isisd: apply fast-reroute as soon an interface or an adjacency falls down
| * isisd: fix potential access to NULL pointer in isis_route_updateLouis Scalbert2022-10-241-4/+6
| | | | | | | | | | | | | | Fix potential access to NULL pointer in isis_route_update even if it is not related with the fast-reroute implementation. Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>