I find AS1221 is both the upstream and the peer of AS13445 from ipinfo.io/AS13445. However, as far as I know, there is no upstream or downstream relationship when talking about peering. Is anything wrong with my understanding?
2 Answers
First: please keep in mind that this is just a representation/interpretation of routing relationships as generated by one specific website based on information they most likely derive from routing tables and public routing databases.
Since there's no clear description on how ipinfo.io decides this, we can only make some guesses. But for example, it could be the case that AS1221 is peering with AS13445 on IXPs (which would make it a peer), and also advertises prefixes received from AS13445 to other networks (which would make AS1221 an upstream).
-
Couldn't agree with you more! I'm new to BGP, so there are still some silly questions about this example, which I didn't get a clear answer with google: 1. More than one relationship(upstream, downstream, peer) is allowed between two ASes. Is it right? 2. Do you know some cases of one IXP also acting as an upstream?– wybCommented Jan 30, 2023 at 12:31
-
1Anything is allowed. You're free to choose what prefixes you exchange on any BGP session. More than one relationship isn't that uncommon. I can't think of a good example for your 2nd question now. Commented Jan 30, 2023 at 12:44
-
Two AS's can peer at more than one point, but not on the same device.– RickyCommented Jan 30, 2023 at 15:28
Upstream and downstream aren't well defined terms in routing, as routing really doesn't have a direction. They are all a matter of perspective. Traffic can flow in any direction. Any prefix can be announced to anyone - they may not accept it.
In the path AS1-AS2-AS3, as seen from AS3, is AS1 up or down from AS2? If AS3 is a Tier-1 ISP (no transit), most people would say everything is downstream of AS3, but that requires you to know they're "tier 1". If AS3 peers with AS1 (and they can), which way is up/down, now? Who's the top of the pyramid? (no one. there never was a "top".)
(If we muddy things with "business logic", downstream are the people who pay me, and upstream are the people I pay. But you can't necessarily get that from a route table.)
-
Indeed, I have also found different definitions of Peering in different sources. I don't even know which one to believe. some examples:
1. The networks interconnect to exchange only traffic that originates or terminates within their networks.
2. If two ASes are neighbors, they are peering.
....– wybCommented Jan 31, 2023 at 3:04 -
Two ASes that form a routing connection ("neighbor") are peers. "neighbor" being a configuration keyword.– RickyCommented Jan 31, 2023 at 8:22
-
So we usually consider peer as BGP peer or neighbor rather than network peering relationship, in opposition to a transit relationship. And we should note the different meanings in different contexts. Is that right?– wybCommented Jan 31, 2023 at 12:27
-
"transit" means you can send them anything (0/0 route). It's common to still get more specific routing information from a transit peer, and you'll still be telling them what networks you have.– RickyCommented Feb 1, 2023 at 0:38