Skip to main content

Juniper Point-to-Point Guide

Note: This guide is even further in-depth than the Point-to-Point configuration guide. This is only intended for a technical audience who is looking to create an NYCMesh P2P, when one or both sides of the link is routed by a Juniper router.

Overview

To create a mesh-specific OSPF P2P link on the Juniper, there are 4 configuration changes you will need to make

  1. Create an irb interface - creating an irb interface is the Juniper equivalent of creating a MikroTik VLAN interface, or a Brocade virtual interface (ve). It's an interface with an IP address, that is assigned to a certain VLAN. The only difference is that this VLAN is not limited to a port, and can be sent out any port. This is where you will assign your /30 P2P IP address.

  2. Create a VLAN - the VLAN and the irb interface are be linked together, and the VLAN is assigned to the switch port that the P2P traffic will come from. This will either be a switchport that the antenna is directly connected to, or a switchport that goes to another switch, which is connected to the antenna.

  3. Configure OSPF on the irb - this is where you configure the OSPF cost of your P2P.

  4. Add the VLAN to a switchport - this is where you assign the VLAN to the port where P2P traffic will be coming from on the Juniper

Prerequisites

  • Subnet allocated using the IP Ranges spreadsheet
  • P2P already configured on the MikroTik side of the link (follow this guide)
  • OSPF cost known

Choosing a VLAN ID

In order to create a P2P, we need to choose an unused VLAN on the Juniper. 

  1. Log into the Juniper with ssh root@ip_address
  2. Enter cli at the initial prompt to enter the switch configuration
  3. Enter show vlans and press enter. This will display a list of all the VLANs on the Juniper. Note down a tag that is unused (this can be anything between 1 and 4094, but you should keep it close to other existing VLANs)

Configuring the Juniper

  1. At the main Juniper CLI prompt (where you should be after entering show vlans above), enter configure to start configuring the router.
  2. First, we'll create the irb. Enter the following commands, replacing <P2P_NAME> with the name of your P2P link, and <IP_ADDRESS> with the IP address of the Juniper side of the link.
    1. set interfaces irb unit <VLAN_TAG> description <P2P NAME>
    2. set interfaces irb unit <VLAN_TAG> family inet address <IP_ADDRESS>/30
  3. Next, create a VLAN and link it to your irb interface, replacing variables as needed.
    1. set vlans <P2P_NAME> vlan-id <VLAN_TAG>
    2. set vlans <P2P_NAME> l3-interface irb.<VLAN_TAG>
  4. Next, configure OSPF on the interface. Note the PTMP setting, meaning the OSPF configuration is Point to Multi Point and not Point to Point, NBMA (Non-Broadcast Multiple Access), or Broadcast (more info on the different types here)
    1. set protocols ospf area 0.0.0.0 interface irb.<VLAN_TAG> interface-type p2mp
    2. set protocols ospf area 0.0.0.0 interface irb.<VLAN_TAG> metric <OSPF_COST>
  5. (Optional: if the MikroTik side of the link is using Bidirectional Forwarding Detection (aka BFD, a faster way of detecting when a link is down than the built-in OSPF method), configure that here. If you don't know, disregard these steps)
    1. set protocols ospf area 0.0.0.0 interface irb.<VLAN_TAG> bfd-liveness-detection minimum-interval 200
    2. set protocols ospf area 0.0.0.0 interface irb.<VLAN_TAG> bfd-liveness-detection multiplier 5
    3. set protocols ospf area 0.0.0.0 interface irb.<VLAN_TAG> bfd-liveness-detection full-neighbors-only
  6. Now add the VLAN to the switchport where the P2P is coming from (usually a switch)
    1. To figure out what interface goes to which switch, enter the command run show interfaces description. This will list all of the ports and their descriptions. Note the interface name (example xe-0/0/4) that the switch or antenna is connected to. Note: if the switch is connected to a bond (known as ae interfaces in Juniper) be sure to add the vlan to that port.
    2. Add the vlan with set interfaces <INTERFACE> unit 0 family ethernet-switching vlan members <P2P_NAME>
  7. Type commit to save your configuration. Once the commit succeeds, type exit to leave configuration mode.
  8. If there are upstream switches that your P2P VLAN needs to be added to, add them normally according to the guide listed in prerequisites.
  9. To confirm OSPF comes up on the Juniper, enter show ospf neighbor, and the router will give you a list of neighbors, and their connected interfaces.