Jump to content

Static Routing with Teltonika Devices Configuration: Difference between revisions

From Teltonika Networks Wiki
No edit summary
No edit summary
Line 88: Line 88:
     <tr>
     <tr>
     <td>
     <td>
    Test
# Enable the rule
    </td>
# Add the name of your rule
# Select '''ICMP protocol''' (Or any other protocol suited to your use case)
# Select WAN as your Source Zone
# Enter your Source IP 192.168.2.1 (RUT1 WAN IP)
# Select WAN as your Destination Zone
# Enter your Destination Address 192.168.10.0/24 (RUT3 LAN Network)
# Select "Accept" as the action </td>
     <td>
     <td>
[[File:R2 Firewall rule 1.png|border]]
[[File:R2 Firewall rule 1.png|border]]
</td>
</td>
     </tr></table>
     </tr></table>

Revision as of 10:24, 17 January 2025

Introduction

Static routing is a method of configuring routing paths on a network by specifying fixed routes between networking devices. Static routing is simple and does not require any overhead or specific protocols and it offers more predictable approach to routing. Static routing is best suited for small, stable networks or specific routes within larger setups. however, lacks the ability to adapt to network changes.

Configuration overview and prerequisites:


Before we begin, let's overview the configuration that we are attempting to achieve and the prerequisites that make it possible.

  • 3 RUTOS devices
  • At least one end device to (PC, laptop, Smartphone or tablet) to configure the routers

If you're having trouble finding this page or some of the parameters described here on your device's WebUI, you should turn on "Advanced WebUI" mode. You can do that by clicking the "Advanced" button, located at the top of the WebUI.

Configuration topology

<< Topology to be inserted here>>

RUT1 – This device will be connected RUT2 via a point-to-point WAN connection. The WAN IP on RUT is a static private 192.168.1.1/30.

RUT2 – This device will be connected to RUT1 via a point-to-point WAN connection and RUT3 via WAN port (A LAN port is configured as WAN port in this configuration example), The WAN Port has a private Static IP 192.168.1.2/30 and the WAN2 (LAN as WAN interface) has a public IP of 192.168.3.1/30

RUT3 – This router is connected to RUT2 via a point-to-point WAN connection. The WAN IP on this device is a private static IP 192.168.3.2/30

RUT1 Configuration

The first step is to configure static Routing and firewall rules on RUT 1, to achieve this, follow these steps:

  • Navigate to Network → Routing → Static Routes and click on “Add
  • Add the below IPv4 Routes:
  1. Route: 172.16.1.0/24 via 192.168.2.2
  2. Route:  192.168.3.0/30 via 192.168.2.2
  3. Route 192.168.10.0/24 via 192.168.2.2

Leave all the parameters as default and click on "Save and Apply"

Firewall Configuration:


After configuring the static routes on RUT1, we need to add traffic rules on RUT1's firewall.

Navigate to Network → Firewall → Traffic Rules and configure the following:

  1. Select traffic rule type and choose “Add a new forward rule
  2. Input a name for your new rule, e.g. “Allow_Pings_From_R2
  3. Select “WAN” as the Source zone
  4. Select “LAN” as the destination zone
  5. Click on the “Add” button

             



In the Traffic rule page, do the following (and leave the rest as defaults, unless your specific configuration requires specific changes):

  1. Enable the rule
  2. Select ICMP protocol (Or any other protocol suited to your use case)
  3. Input your Source address (RUT2 WAN)
  4. Input the Destination Address (RUT 1 LAN)
  5. Select “Accept” as the action

Leave all the other parameters as default and click on "Save and Apply"

RUT2 Configuration

The next step is to configure static Routing and firewall rules on RUT 2, to achieve this, follow these steps:

  • First we need to configure an additional LAN port to function as a WAN port, this can be achieved by following the guideline outlined on here
  • Once the additional LAN port has been configured, we need to procced and add the below routes on RUT2
  • Navigate to Network → Routing → Static Routes and click on “Add

Route 10.0.0.0/24 via 192.168.2.1

Route 192.168.10.0/24 via 192.168.3.1

Firewall Configuration


After configuring the static routes on RUT2, we need to add traffic rules on RUT2.

Navigate to Network → Firewall → Traffic Rules and configure the following traffic rules

  1. Enable the rule
  2. Add the name of your rule
  3. Select ICMP protocol (Or any other protocol suited to your use case)
  4. Select WAN as your Source Zone
  5. Enter your Source IP 192.168.2.1 (RUT1 WAN IP)
  6. Select WAN as your Destination Zone
  7. Enter your Destination Address 192.168.10.0/24 (RUT3 LAN Network)
  8. Select "Accept" as the action