SRX

last person joined: 4 days ago 

Ask questions and share experiences about the SRX Series, vSRX, and cSRX.
  • 1.  How to configure an OSPF export policy for static routes

     
    Posted 10-04-2018 05:57

    Assuming an export policy is what I need, I'd like some assistance in configuring an OSPF export policy to inject/advertise some static routes in our network. I have been looking at the article below for assistance, but I'm not sure how to take it and apply my requirements. We have multiple 192.168.x.x subnets that use OSPF, but these subnets need to know about systems on a 10.250.x.x network that we do not manage. The aforementioned 10.250.x.x subnets are connected to our network via a router (not under our control) on one of the 192.168.x.x subnets with an IP address on the subnet e.g. 192.168.1.253. How should I go about configuring OSPF to advertise the 10.250.x.x subnets to the 192.168.x.x network?

     

    https://www.juniper.net/documentation/en_US/junos/topics/example/ospf-routing-policy-redistributing-static-routes-into-ospf-configuring.html



  • 2.  RE: How to configure an OSPF export policy for static routes

     
    Posted 10-04-2018 09:11

    I advertise the statics into IS-IS this way:

     

    [edit policy-options]

    set policy-statement export-statics term 1 from protocol static 

    set policy-statement export-statics term 1 then accept

     

    [edit]

    set protocols isis export export-statics

     

    I guess replace the "protocols isis" with "protocols ospf"

     

    This gives you a basic config for exporting statics anyway.... 



  • 3.  RE: How to configure an OSPF export policy for static routes

     
    Posted 10-05-2018 02:13

    So how and where do I specify that in order to get to 10.250.x.x route via IP address 192.168.1.253?



  • 4.  RE: How to configure an OSPF export policy for static routes

     
    Posted 10-05-2018 07:16

    Can I make an assumption that you have a static route in place that states something along the lines of:

     

    set routing-options static route 10.250.x.x/x next-hop 192.168.x.x    ????

     

    Then you need to inject that static route into your OSPF network  ????

     

    set policy-options policy- statement ospf-static term 1 from protocol static

    set policy-options policy-statement ospf-static term 1  ----  Keep going with whatever options you want here

    set policy-options policy-statement ospf-static term 1 then accept

     

    set protocols ospf !!!!!! export ospf-static    ----   I have not configured this on OSPF so not too sure about area IDs etc hence the !!!!!

     

    This will inject your static routes, taking into account your options in the policy-statement, into OSPF.

     

    Important point to remember is that these statements, when applied, are read in chronological order, so be careful with any added terms with just "accept" in them.



  • 5.  RE: How to configure an OSPF export policy for static routes

     
    Posted 11-01-2018 02:37

    Thank you adgwytc!

     

    For anyone interested, I defined the static route, referenced the export policy under protocols OSPF, then defined the policy as follows:

     

    policy-options {
        policy-statement to-ospf {
            term other-network {
                from {
                    protocol static;
                    route-filter 10.250.0.0/16 exact;
                }
                then accept;
            }
        }
    }