How to set network group base routing

Hi, ALL
I have a problems as follow show :

  1. I have 2 WAN(One is adsl, another one has static ip)
  2. ADSL for default routing
  3. Static IP Wan that i want an ip ranges as a firwall group (like google ip ranges) to set routing via static IP)

I’d try PBR but i failed , Anyone who know it, please contact.
EdgeOS has command:
set firewall modify M rule 20 destination group network-group CMNET
set firewall modify M rule 20 action modify
set firewall modify M rule 20 modify table 2

But how about vyos?

Hello!
This is trivial task. What you have already configured?

The difference is EdgeOS puts this configuration on the firewall, and VyOS (more sanely in my opinion), puts this information its own section

This is my config that accomplishes two things:

  • Makes it so I can still access the hosts from my local network.
  • Routes all traffic from those hosts to my VPN
    # show policy route
     route PIA {
         rule 9 {
             destination {
                 group {
                     network-group PRIVATE-NETWORKS
                 }
             }
             set {
                 table main
             }
             source {
                 group {
                     address-group PIA
                 }
             }
         }
         rule 10 {
             set {
                 table 22
             }
             source {
                 group {
                     address-group PIA
                 }
             }
         }
     }

Okay,That’s works. Thanks a lot.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.