This article explains how to create a custom routing table.
As with any other device connected to the Internet, the Wattsense product comes with its routing table. The routing table will help identify where to send the data to a recipient based on its IP address.
Our product can connect to the Internet with 2 different ways :
- Through one of the two Ethernet interfaces
- Through its GSM modem
The connection with the GSM modem has to be permanent, in order to allow direct communication between the Wattsense servers and your device.
|
For example:
It is necessary to send a new configuration to the device or to benefit from a new firmware update.
|
Default Route
A default routing is configured for this in your device to redirect any IP traffic to the Wattsense server.
Default routing table (wwan0 represents the GSM modem)
If an IP network is added, the default routing is updated to reflect the new connection.
eth2 interface configuration here for a MQTT gateway
Default routing table updated to reflect the eth2 interface configuration
Custom Route
In some specific cases, you will need to edit the routing table of the device to specify your own route. The case we know the most of is the following:
In this example, we have two sub-networks in the building: Local Network and Extended Network. If data should transit between Local Network, where the Wattsense device is, to Extended Network thanks to the router, then the routing table should be edited in the configuration of the device. Otherwise, the data automatically will go through the GSM interface and will never reach the Extended Network.
Case study:
Without manual route:
The Box can connect with D1 and D2 as they are in the same network, when it comes to the local network, all the traffic will be routed using ethernet.
If you try to connect to D3 and D4 (Extended Network) , the box will check if they are accessible in the Local Network, as it is not, it won't work and all the traffic would be routed in the Cloud (using GSM).
With correct manual route:
You'll be able to connect to D1/D2/D3 and D4 as the traffic to the Extended Network will be correctly accessible/routed.
Addition of the new route
In case you need help or any further information concerning the routing table configuration, feel free to contact us here.