Hats Network | LogoHats Network
BGP Communities

Internal BGP Communities

Internal BGP communities for AS203314 indicating route origin types, PoP locations, and geographic regions.

AS203314 attaches internal communities to describe how and where routes entered or crossed the network. Match these tags when selecting or filtering routes received from us.

Community Format: 203314:XXX:YY where XXX is the category and YY is the specific value.

Route Origin

The following tags identify the relationship through which a route was learned:

CommunityDescriptionUnique
203314:110:10Route learned from UpstreamYes
203314:110:20Route learned from DownstreamYes
203314:110:30Route learned from PeeringYes
203314:110:110Route originated within Hats NetworkYes

Unique means this route is only announced via this method-if you see 203314:110:30, the route is exclusively available via peering.

PoP-Based Communities

PoP tags distinguish the entry point from a transit location:

Routes learned at a specific PoP (entry point):

CommunityDescriptionUnique
203314:120:XXXRoute learned at PoP XXXYes

Example: 203314:120:101 means the route was learned at Hong Kong (HKG1).

Region-Based Communities

Region tags distinguish the learning region from a region traversed:

Routes learned within a specific region:

CommunityDescriptionUnique
203314:130:XXRoute learned in Region XXYes

Example: 203314:130:100 means the route was learned in Asia (West).

Usage Examples

Identify Route Source

Determine if a route comes from peering, upstream, or our customers:

# These large communities are attached by AS203314 on routes you receive.
# You typically match them in your import policy:
filter import_prefer_peering_v4 {
  if (203314, 110, 30) ~ bgp_large_community then bgp_local_pref = 200; # prefer peering-learned routes
  if (203314, 110, 10) ~ bgp_large_community then bgp_local_pref = 80; # de-prioritize upstream-learned routes
  accept;
}

Identify Entry Location

Determine where a route entered our network:

filter import_prefer_asia_pops_v4 {
  if (203314, 120, 101) ~ bgp_large_community then bgp_local_pref = 200; # entered at HKG1 (Hong Kong)
  if (203314, 120, 131) ~ bgp_large_community then bgp_local_pref = 180; # entered at TYO2 (Tokyo)
  accept;
}

Filter by Region

Accept routes only from specific regions:

# Only accept routes learned in Asia West
filter import_only_asia_west_v4 {
  if (203314, 130, 100) ~ bgp_large_community then accept;
  reject;
}

# Reject routes that passed through Europe (both West=200 and East=250)
filter import_reject_europe_transit_v4 {
  if (203314, 135, 200) ~ bgp_large_community then reject;
  if (203314, 135, 250) ~ bgp_large_community then reject;
  accept;
}

Policy Examples (JunOS / BIRD2)

Internal tags are BGP Large Communities. Import policies can match them to set local preference or filter received routes.

Prefer routes learned in Asia West (203314:130:100)

set policy-options community HATS-REGION-ASIA-W members large:203314:130:100

set policy-options policy-statement IMPORT-FROM-HATS term ASIA-W from community HATS-REGION-ASIA-W
set policy-options policy-statement IMPORT-FROM-HATS term ASIA-W then local-preference 200
set policy-options policy-statement IMPORT-FROM-HATS term ASIA-W then accept

Reject routes learned from Upstream (203314:110:10)

set policy-options community HATS-ORIGIN-UPSTREAM members large:203314:110:10

set policy-options policy-statement IMPORT-FROM-HATS term NO-UPSTREAM from community HATS-ORIGIN-UPSTREAM
set policy-options policy-statement IMPORT-FROM-HATS term NO-UPSTREAM then reject

Tip: Internal communities are automatically attached to routes we announce to you. Use them to make informed routing decisions based on route origin and location.

On this page