Hi Ehsan! Here is what I do: - I know which service providers I use (where I colocate my servers and order VMs) - Hence, I know which transit providers these service providers use (either by asking them, checking looking glasses, or RIS) - I also know my routing policy: ie which AS path length I want to have at Tier1 providers and at IX peerings. - Then I created a whitelist which contains the good AS paths, ie: Our Anycast announcement for a certain prefix in Vienna uses source AS 1921, hosted behind AS30971, which uses a local transit provider AS1764, which uses Tier1 AS2914 ..... and some prepend. This will lead to the AS path: 2914 1764 30971 1921 1921. - Once an hour I download all routes from RIPE RIS and match my whitelist. Every AS path identical or longer tothe whiteliste paths is allowed, ie the match is: .*2914 1764 30971 1921 1921 (and so on) So, when routes change, for example AS1764 suddenly announces to Cogent, I will get alarmed, and then I have to decide to whitelist the new path, or take countermeasure to avoid that route (eg using BGP communities). Not very sexy, but works great, especially for detecting changes in Tier1 routing, or incorrect prepends regards Klaus
-----Ursprüngliche Nachricht----- Von: routing-wg <routing-wg-bounces@ripe.net> Im Auftrag von Ehsan Ghazizadeh Gesendet: Sonntag, 19. März 2023 17:53 An: Vainius Dangovas <Vainius.Dangovas@smn.lt> Cc: routing-wg <routing-wg@ripe.net> Betreff: Re: [routing-wg] BGP Best Path data from different RIS
Yeah exactly, ripe stat returns all paths to that specific prefix not the best path, (its multipath in bgp perspective). I need to know which as-path is being chosen from different location of Europe and America to my asn, it's for tshoot purposes. We are a cloud provider and sometimes bgp changes cause performance issues (it can happen only to some of prefixes and can't be easily discovered by our monitoring system), I want to be informed about bgp path changes before customers sense its affect. I currently have bgpalerter.
On Sun, Mar 19, 2023, 7:01 PM Vainius Dangovas <Vainius.Dangovas@smn.lt <mailto:Vainius.Dangovas@smn.lt> > wrote:
Hi, Ehsan,
Have You tried RIPEstat?
I guess this data would be useful for Your use: https://stat.ripe.net/data/looking-glass/data.json?resource=1.1.1.0/24 <https://stat.ripe.net/data/looking-glass/data.json?resource=1.1.1.0/24>
As I understand RRCs get updates only about the best path (from the RRC peer’s point of view) about the prefix in question.
This call is also used in https://stat.ripe.net/app/launchpad/
Pagarbiai / Best regards,
Vainius Dangovas
Mobile: +370 680 80876
vainius.dangovas@smn.lt <mailto:vainius.dangovas@smn.lt>
From: routing-wg <routing-wg-bounces@ripe.net <mailto:routing- wg-bounces@ripe.net> > on behalf of Ehsan Ghazizadeh <ehsan.ccsp@gmail.com <mailto:ehsan.ccsp@gmail.com> > Date: 2023 March 19, Sunday 09:20 To: routing-wg <routing-wg@ripe.net <mailto:routing-wg@ripe.net>
Subject: [routing-wg] BGP Best Path data from different RIS
Hi everyone
I'm trying to write a python script to fetch bgp best path data for my prefixes from different locations. Apparently ripe stat only returns the full routing table not the best path, also connecting via telnet to routeviews routers and parsing bgp commands output is not an ideal method, so I was wondering is there any other method to achieve this (preferably using api)?
Šiame laiške ir bet kokiuose jo prieduose pateikiama informacija yra konfidenciali ir skirta tik tam asmeniui, kuriam ji adresuota. Jei Jūs nesate adresatas, Jūs neturite teisės gautos informacijos bet kokiu būdu naudoti. Jei Jūs per klaidą gavote šį laišką, prašome nedelsiant pranešti jo siuntėjui bei iškart ištrinti šį laišką ir bet kokius jos priedus iš Jūsų sistemų. Informaciją apie asmens duomenų tvarkymą galite perskaityti https://www.smn.lt/duomenu- apsauga-2/. || The information contained in this e-mail and its attachments is confidential and intended only for a person to whom it is addressed. If you are not the intended addressee you may not use this information in any way. If you have received this e-mail in error, please notify the sender and delete all copies of the e-mail and its attachments form your systems immediately. Information about processing of personal data can be found at https://www.smn.lt/duomenu-apsauga-2/.