Separating Mobile Data Traffic: Using First SIM Card For LAN Traffic and Second SIM Card For WLAN Traffic: Difference between revisions

From Teltonika Networks Wiki
No edit summary
No edit summary
 
Line 1: Line 1:
<p style="color:red">The information in this page is updated in accordance with firmware version '''[https://wiki.teltonika-networks.com/view/FW_%26_SDK_Downloads 00.07.10]'''
==Introduction==
==Introduction==
This article provides a guide on how to separate mobile data traffic by using first SIM card for LAN traffic and second SIM card for WLAN traffic. These configurations are specifically made for RUTX12.
This article provides a guide on how to separate mobile data traffic by using first SIM card for LAN traffic and second SIM card for WLAN traffic. These configurations are specifically made for RUTX12.


----
----
* First you want to make sure that you have '''ADVANCED mode''' enabled. This will allow you to choose from a larger variety of settings.
If you're having trouble finding any 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 which is located at the top-right corner of the WebUI.
[[File:Networking rutx manual webui basic advanced mode v1.gif|border|class=tlt-border]]
[[File:Networking rutos manual webui basic advanced mode 75.gif|border|class=tlt-border|1004x1004px]]
----
----
==Configuring VLANs==
* Go to '''Network''' → '''VLAN'''
* Go to '''VLAN''' → '''Port Based'''
[[File:Port VLAN.png]]


* Click '''Add'''
==Creating A LAN Interface For WLAN==
* Leave VLAN ID as it is, for now, no need to change anything here


==Creating A Second LAN Interface==
* Go to '''Network''' → '''Wireless''' → '''SSIDs'''
* Press the '''Edit''' button next to the WLAN whose traffic you want to route through a different SIM card.
* In the opened tab, next to '''Network''' from the dropdown meniu press '''Add new''' and enter the desired LAN name.


* Go to '''Network''' → '''Interfaces'''
[[File:AddNewInterfaceV1.png|border|class=tlt-border|]]
* Under '''Add New Instance''' enter the name for your new LAN interface (we are going to use "lan2" for this example) and click '''Add'''


* In the newly opened tab:
# Write the '''desired IPv4 address'''.
# Enable '''DHCP'''.
# Press '''Save & Apply'''.


[[File:Add int.png]]


* Under the '''General Settings''' tab, set '''Protocol''' to '''Static''', and enter desired IPv4 parameters for your VLAN
[[File:LanConfigForWLANV1.png|border|class=tlt-border|]]


==Configuring Policy Based Routing==


[[File:Interfaces lan2.png]]
* Go to '''Network''' → '''Routing''' → '''Policy Based Routing'''
 
* Click on '''Setup DHCP Server''' to enable DHCP for your VLAN
* Go to '''Physical Settings''' and click on '''Interface''', select your VLAN interface ('''N.B.''' if your '''VLAN ID is 3''', the name for your physical interface will be '''eth0.3''' and so on)
 
 
[[File:Phy eth3.png]]
 
==Configuring Advanced Static Routes==
 
* Go to '''Network''' → '''Routing''' → '''Advanced Static Routes'''
* Under the "Add New Instance" tab, enter the ID and name for your new Routing Table, for our use, we will need 2 Routing Tables
* Under the "Add New Instance" tab, enter the ID and name for your new Routing Table, for our use, we will need 2 Routing Tables
* Create a routing table with these parameters: '''ID''': 100, '''Name''': first
* Create a routing table with these parameters: '''ID''': 100, '''Name''': first
* Click '''Add'''


 
[[File:FirstRoutingTableV1.png|border|1100px|class=tlt-border|]]
[[File:Static route1.png]]
----
 
* Click '''Add'''
* In the configuration window, under the '''Static IPV4 Routes''' tab, click '''Add'''
* In the configuration window, under the '''Static IPV4 Routes''' tab, click '''Add'''
* Enter these parameters: '''Interface''': mob1s1a1, '''Target''': 0.0.0.0, '''Netmask''': 0.0.0.0
* Enter these parameters: '''Interface''': mob1s1a1, '''Target''': 0.0.0.0, '''Netmask''': 0.0.0.0
* Leave the rest of the parameters on their default values and click '''Save & Apply'''


[[File:FirstRoutingTableP2V1.png|border|1100px|class=tlt-border|]]


[[File:Routes 1.png]]
----
 
* Leave the rest of the parameters on their default values and click '''Save & Apply'''
* Create a second routing table with these parameters: '''ID''': 200, '''Name''': second
* Create a second routing table with these parameters: '''ID''': 200, '''Name''': second
* Click '''Add'''


 
[[File:SecondRoutingTableV1.png|border|1100px|class=tlt-border|]]
[[File:Static route2.png]]
----
 
* Click '''Add'''
* In the configuration window, under the '''Static IPV4 Routes''' tab, click '''Add'''
* In the configuration window, under the '''Static IPV4 Routes''' tab, click '''Add'''
* Enter these parameters: '''Interface''': mob2s1a1, '''Target''': 0.0.0.0, '''Netmask''': 0.0.0.0
* Enter these parameters: '''Interface''': mob2s1a1, '''Target''': 0.0.0.0, '''Netmask''': 0.0.0.0
[[File:Routes 2.png]]
* Leave the rest of the parameters on their default values and click '''Save & Apply'''
* Leave the rest of the parameters on their default values and click '''Save & Apply'''
* Go to '''Network''' → '''Routing''' → '''Advanced Static Routes''' → '''Routing Rules For IPV4'''
[[File:SecondRoutingTableP2V1.png|border|1100px|class=tlt-border|]]
 
 
[[File:Networking rutos manual routing advanced static routes routing rules for ipv4 v1 begin to edit.gif]]


----
* Go to '''Network''' → '''Routing''' → '''Policy Based Routing''' → '''Routing Rules For IPV4''' and press '''ADD''' button.
* Create 2 new rules with these parameters:
* Create 2 new rules with these parameters:
First Rule: '''Priority:''' 1, '''Incoming interface:''' lan, '''Lookup table:''' 100
*First Rule:  
#'''Priority:''' 1  
#'''Incoming interface:''' lan  
#'''Lookup table:''' 100




[[File:Rules 1.png]]
[[File:FirstRoutingRulesV1.png|border|class=tlt-border|]]
 
----
Second Rule: '''Priority:''' 1, '''Incoming interface:''' lan2, '''Lookup table:''' 200
*Second Rule:  
#'''Priority:''' 1  
#'''Incoming interface:''' lan2  
#'''Lookup table:''' 200




[[File:Rules 2.png]]
[[File:SecondRoutingRulesV1.png|border|class=tlt-border|]]


==Separating Traffic Via Ethernet Ports==
==Separating Traffic Via Ethernet Ports==


* Go to '''Network''' → '''VLAN'''
This example could also be applied when there is a need to split ethernet ports traffic via different SIM cards.
* Set '''Untagged''' on any LAN port you want next to VLAN ID: 3 (remove '''Untagged''' on a port next to VLAN ID: 1 accordingly)
----
 
===Configuring VLANs===
 
To start with we will need to create new VLAN.
[[File:Vlan end.png]]
* Go to '''Network''' → '''VLAN''''''Port Based''' and press '''ADD''' button.
 
* Once new VLAN appears, '''untag''' desired ports from '''VLAN 1''' and '''tag''' them on '''VLAN 3'''. In this example ports 3 and 4 will be used in VLAN 3.
==Separating Traffic With WLAN Interface==
 
* Go to '''Network''' '''Wireless'''
* Select your desired access point and click '''Edit'''
 
 
[[File:Wifi ap edit.png]]
 
* Click on '''Network''' and select a LAN interface which is used by VLAN ('''lan2''' in this example)


[[File:VLANForTrafficSplitV1.png|border|1100px|class=tlt-border|]]
----
===Configuring LAN===
*Navigate to '''Network'''→'''LAN''' and press '''Edit''' button next to the previously created LAN.
* In '''Physical Settings''' select new VLAN. In this example '''eth0.3''' after that press '''Save & Apply'''.


[[File:Wifi vlan.png]]
[[File:LanSettingsForVLANV1.png|border|class=tlt-border|]]


* Click '''Save & Apply'''
===Testing the configuration===
To test the configuration simply connect to one of the ports that are in LAN and check the IP address, then connect to the port that is in different LAN and check again the IP address. For this test icanhazip.com website will be used.
* End device connected to first LAN:
[[File:TrafficSplitLANTestV1.png|border|class=tlt-border|]]
* End device connected to second LAN:
[[File:TrafficSplitNewLANTestV1.png|border|class=tlt-border|]]
[[Category: Router control and monitoring]]
[[Category: Router control and monitoring]]

Latest revision as of 08:46, 15 October 2024

Main Page > General Information > Configuration Examples > Router control and monitoring > Separating Mobile Data Traffic: Using First SIM Card For LAN Traffic and Second SIM Card For WLAN Traffic

The information in this page is updated in accordance with firmware version 00.07.10

Introduction

This article provides a guide on how to separate mobile data traffic by using first SIM card for LAN traffic and second SIM card for WLAN traffic. These configurations are specifically made for RUTX12.


If you're having trouble finding any 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 which is located at the top-right corner of the WebUI.


Creating A LAN Interface For WLAN

  • Go to NetworkWirelessSSIDs
  • Press the Edit button next to the WLAN whose traffic you want to route through a different SIM card.
  • In the opened tab, next to Network from the dropdown meniu press Add new and enter the desired LAN name.

  • In the newly opened tab:
  1. Write the desired IPv4 address.
  2. Enable DHCP.
  3. Press Save & Apply.


Configuring Policy Based Routing

  • Go to NetworkRoutingPolicy Based Routing
  • Under the "Add New Instance" tab, enter the ID and name for your new Routing Table, for our use, we will need 2 Routing Tables
  • Create a routing table with these parameters: ID: 100, Name: first
  • Click Add


  • In the configuration window, under the Static IPV4 Routes tab, click Add
  • Enter these parameters: Interface: mob1s1a1, Target: 0.0.0.0, Netmask: 0.0.0.0
  • Leave the rest of the parameters on their default values and click Save & Apply


  • Create a second routing table with these parameters: ID: 200, Name: second
  • Click Add


  • In the configuration window, under the Static IPV4 Routes tab, click Add
  • Enter these parameters: Interface: mob2s1a1, Target: 0.0.0.0, Netmask: 0.0.0.0
  • Leave the rest of the parameters on their default values and click Save & Apply


  • Go to NetworkRoutingPolicy Based RoutingRouting Rules For IPV4 and press ADD button.
  • Create 2 new rules with these parameters:
  • First Rule:
  1. Priority: 1
  2. Incoming interface: lan
  3. Lookup table: 100



  • Second Rule:
  1. Priority: 1
  2. Incoming interface: lan2
  3. Lookup table: 200


Separating Traffic Via Ethernet Ports

This example could also be applied when there is a need to split ethernet ports traffic via different SIM cards.


Configuring VLANs

To start with we will need to create new VLAN.

  • Go to NetworkVLANPort Based and press ADD button.
  • Once new VLAN appears, untag desired ports from VLAN 1 and tag them on VLAN 3. In this example ports 3 and 4 will be used in VLAN 3.


Configuring LAN

  • Navigate to NetworkLAN and press Edit button next to the previously created LAN.
  • In Physical Settings select new VLAN. In this example eth0.3 after that press Save & Apply.

Testing the configuration

To test the configuration simply connect to one of the ports that are in LAN and check the IP address, then connect to the port that is in different LAN and check again the IP address. For this test icanhazip.com website will be used.

  • End device connected to first LAN:

  • End device connected to second LAN: