SNMP configuration example: Difference between revisions
Appearance
No edit summary |
|||
| (18 intermediate revisions by 4 users not shown) | |||
| Line 18: | Line 18: | ||
===RUT9xx=== | ===RUT9xx=== | ||
To setup SNMP first make sure that SNMP package is installed, more information here [[ | To setup SNMP first make sure that SNMP package is installed, more information here [[RUT956 Packages]] and [[RUT951_Package_Manager|RUT951 Packages]]. | ||
==OID codes== | ==OID codes== | ||
| Line 123: | Line 123: | ||
In this example '''iReasoning MIB browser''' was used '''only for testing purpose'''. | In this example '''iReasoning MIB browser''' was used '''only for testing purpose'''. | ||
[[File:Networking device configrationexample snmp mib browser | [[File:Networking device configrationexample snmp mib browser v2.png]] | ||
===Generating OID code from MIB File=== | ===Generating OID code from MIB File=== | ||
MIB File contains all OID codes. | MIB File contains all OID codes. | ||
Line containing numbers needed for OID code can be identified by this marking "::=". | Line containing numbers needed for OID code can be identified by this marking "::=". | ||
[[File:Networking device configurationexample snmp mib file oid codes v1.png | [[File:Networking device configurationexample snmp mib file oid codes v1.png]] | ||
All that is left, is to add the numbers together. Example from given MIB File: 1.3.6.1.4.1.48690.1.1.0. | All that is left, is to add the numbers together. Example from given MIB File: 1.3.6.1.4.1.48690.1.1.0. | ||
| Line 135: | Line 135: | ||
==SNMP Configuration== | ==SNMP Configuration== | ||
To configure SNMP, first enable SNMP service, leave or change the port, you can leave everything else as it is | To configure SNMP, first enable SNMP service, leave or change the port, you can leave everything else as it is. | ||
[[File: | Press "Download" button to download MIB file. | ||
[[File:SNMP_config_example_7.8_5.png]] | |||
===Testing SNMP with MIB browser=== | ===Testing SNMP with MIB browser=== | ||
Use MIB browser to test if SNMP works. Make sure to use same port and IP address of the router in MIB browser | Use MIB browser to test if SNMP works. Make sure to use same port and IP address of the router in MIB browser. To enter port number in MIB browser press "Advanced" button '''(on the right of IP address field)'''. | ||
[[File:Networking device configurationexample mib browser port v2.png]] | |||
[[File:Networking device configurationexample snmp test example | To upload/load MIB file press "File" in menu bar '''(top left side of the window)''' and press "Load MIBs", '''make sure to select the MIB file you downloaded from the WebUI'''. MIB browser lets you walk through all OID codes, or return a distinct variable value. To walk through all OID codes select "walk" in Operation tab '''(top left of the window)'''. To iterate through OID codes manually, navigate to the desired folder on the left of the MIB browser window and select specific element '''(Double click)'''. The value of the variable will be printed in the '''Result Table'''. | ||
[[File:Networking device configurationexample snmp test example v2.png]] | |||
===Testing SNMP with console command=== | ===Testing SNMP with console command=== | ||
| Line 157: | Line 164: | ||
First enable SNMP Trap, then enter '''Host/IP''', Hots/IP is the SNMP manager, computer to which SNMP agent will send Trap messages. If router is connected to PC via ethernet cable, enter the IP address of the interface the router is connected to. You can use '''ipconfig''' command on windows, '''ifconfig''' on linux to find IP address of the interface to which router is connected. Next choose '''port''', preferably choose port number higher than '''1024''' so SNMP manager could establish connection without root/admin rights. If you choose to leave default port '''162''' make sure to launch SNMP manager with admin/root permissions. | First enable SNMP Trap, then enter '''Host/IP''', Hots/IP is the SNMP manager, computer to which SNMP agent will send Trap messages. If router is connected to PC via ethernet cable, enter the IP address of the interface the router is connected to. You can use '''ipconfig''' command on windows, '''ifconfig''' on linux to find IP address of the interface to which router is connected. Next choose '''port''', preferably choose port number higher than '''1024''' so SNMP manager could establish connection without root/admin rights. If you choose to leave default port '''162''' make sure to launch SNMP manager with admin/root permissions. | ||
[[File: | [[File:SNMP_config_example_7.8_1.png]] | ||
===Trap rules=== | ===Trap rules=== | ||
Trap rules describe on what event SNMP agent should send Trap messages. There are certain rules which can be set up using Teltonika WebUI depending on physical configuration of the device. | Trap rules describe on what event SNMP agent should send Trap messages. There are certain rules which can be set up using Teltonika WebUI depending on physical configuration of the device. | ||
====Events log==== | |||
---- | |||
<table class="nd-mantable"> | <table class="nd-mantable"> | ||
<tr> | <tr> | ||
<th> | <th>Event</th> | ||
<th>Event subtype</th> | |||
<th>Description</th> | |||
</tr> | |||
<tr> | |||
<td><b>Config change</b></td> | |||
<td>All | Specific config change; default: <b>all</b></td> | |||
<td>Informs on changes to the device's configuration.</td> | |||
</tr> | |||
<tr> | |||
<td><b>Reboot</b></td> | |||
<td>All | From Web UI | From ping reboot | From reboot scheduler | From button | From SMS; default: <b>All</b></td> | |||
<td>Informs on if the device was rebooted.</td> | |||
</tr> | |||
<tr> | |||
<td><b>Startup</b></td> | |||
<td>Device startup completed</td> | |||
<td>Informs on when the device is fully booted.</td> | |||
</tr> | |||
<tr> | |||
<td><b>GPS</b></td> | |||
<td>All | Entered geofence | Left geofence; default: <b>All</b></td> | |||
<td>Informs on when the device has entered or left a user defined geofence zone.</td> | |||
</tr> | |||
<tr> | |||
<td><b>Mobile data</b></td> | |||
<td>All | Connected | Disconnected; default <b>All</b></td> | |||
<td>Informs on changes to the state of the device's mobile connection.</td> | |||
</tr> | |||
<tr> | |||
<td><b>New DHCP client</b></td> | |||
<td>All | Connected from LAN | Connected from WiFi; default <b>All</b></td> | |||
<td>Informs on new DHCP lease give outs.</td> | |||
</tr> | |||
<tr> | |||
<td><b>Ports state</b></td> | |||
<td>All | Link speed | Link state | Unplugged | Plugged in | Specific port; default: <b>All</b></td> | |||
<td>Informs on Ethernet port state (plugged in or unplugged) or speed (100 Mbps or 1000 Mbps) changes.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>Reboot</b></td> | |||
<td>All | From button | From Input/Output | From Ping Reboot | From Reboot Scheduler | From WebUI | From SMS; default: <b>All</b></td> | |||
<td>Informs after device reboot occurrences.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>Signal strength</b></td> | |||
<td>All | - 121 dBm - 113 dBm | - 113 dBm - 98 dBm | - 98 dBm - 93 dBm | - 93 dBm - 75 dBm | - 75 dBm - 60 dBm | - 60 dBm - 50 dBm; default: <b>All</b></td> | |||
<td>Informs on signal strength changes.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>SMS</b></td> | |||
<td>SMS received</td> | |||
<td>Informs on received SMS messages.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>SSH</b></td> | |||
<td>All | Successful authentication | Unsuccessful authentication; default: <b>All</b></td> | |||
<td>Informs on successful or unsuccessful SSH login attempts.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>Topology state</b></td> | |||
<td>Topology changes</td> | |||
<td>Informs on changes to the device's network topology.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>WAN failover</b></td> | |||
<td>All | Switched to failover | Switched to main; default: <b>All</b></td> | |||
<td>Informs on WAN failover occurrences.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td><b>WebUI</b></td> | |||
<td>ALL | Successful authentication | Unsuccessful authentication; default: <b>All</b></td> | |||
<td>Informs on successful or unsuccessful HTTP/HTTPS login attempts.</td> | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<table> | <td><b>New WiFi client</b></td> | ||
<td>All | Connected | Disconnected; default: <b>All</b></td> | |||
<td>Informs on new WiFi clients. Possible triggers are:</td> | |||
</tr> | |||
</table> | |||
---- | ---- | ||
To create new rule chose action and press "Add" button, specify rule values and save | To create new rule chose action and press "Add" button, specify rule values and save: | ||
[[File: | [[File:SNMP_config_example_7.8_2.png|1000px]] | ||
---- | ---- | ||
Modify the trap to your needs: | |||
[[File:SNMP_config_example_7.8_3.png|1000px]] | |||
[[File: | |||
---- | ---- | ||
New rule should appear in the main Trap window | New rule should appear in the main Trap rules window: | ||
[[File:SNMP_config_example_7.8_4.png|1000px]] | |||
[[File: | |||
---- | ---- | ||
====Testing Trap with MIB browser==== | ====Testing Trap with MIB browser==== | ||
| Line 225: | Line 269: | ||
'''Note:''' Preferably open MIB browser with root/admin permissions. | '''Note:''' Preferably open MIB browser with root/admin permissions. | ||
[[File:Networking device configurationexample snmp trap receiver config | [[File:Networking device configurationexample snmp trap receiver config v2.png]] | ||
---- | ---- | ||
To test "Connection type trap" reboot mobile modem. You can reboot modem through Status -> Network window. | To test "Connection type trap" reboot mobile modem. You can reboot modem through Status -> Network window. | ||
MIB browser should receive Trap message. | MIB browser should receive Trap message. | ||
[[File:Networking configurationexample received trap | [[File:Networking configurationexample received trap v2.png]] | ||
===Testing Trap with Linux Terminal=== | |||
To test Traps with Linux terminal extra configurations and packages are required. All information how to setup Trap listening service and how to test it can be found here [[Testing Trap With Linux Operating System]]. | |||
[[Category:SNMP]] | |||