SonicWall templates ?

Templates, scripts for templates, scripts and requests for templates.

Moderators: Developers, Moderators

Post Reply
blenherr
Posts: 1
Joined: Tue Dec 09, 2003 11:26 pm
Location: Lewisburg, WV
Contact:

SonicWall templates ?

Post by blenherr »

Anyone got a data, host or graph template for SonicWall products ? We would like to graph VPN status and utilization.

Thanks in advance.
macdonaldc
Posts: 25
Joined: Thu Nov 10, 2005 12:00 am

Post by macdonaldc »

Im interested as well. If anyone has anything please post it.

Thanks in advance
chrisl1977
Posts: 4
Joined: Wed Nov 23, 2005 9:23 am

Post by chrisl1977 »

The interface stats are easy to get (as you've probably figured out). Some one will probably need to devise a script to agregate the data from the VPN OID's by the tunel name. I'm not sure how to do that.
wazoqaz
Posts: 15
Joined: Wed May 24, 2006 9:40 am
Location: md, us
Contact:

Sonicwall Templates for VPN Usage, CPU, Memory & Connect

Post by wazoqaz »

I have created the following templates and scripts for monitoring your Sonicwall firewall. The template includes graphs for CPU Utilization, Memory Usage, Current Connections Cache, and most importantly VPN utilization on a tunnel-by-tunnel basis as well as the basic interface stats.

If you are running SonicOS Enhanced then you be able to graph everything, if you are running SonicOS Standard or the older the 6.X firmware, then you will only get the VPN monitoring as the other stats are unavailable via SNMP.

The script portion (written is PERL) queries the firewall and returns the list of currently active tunnels (by the IP address on the Peer Gateway) as well as the tunnel name and decrypted (received) bytes and encrypted (transmitted) bytes. Because the tunnels are renegotiated (by default every 8 hours) you will experience spikes in your graph unless you follow the installation instructions.

Also because the firewall does not always return the VPN tunnel name you must renegotiate each tunnel prior to creating the graphs the first time in order for it to correctly pull in the name. You may need to do this a couple of times being sure to press the green O button in cacti before they will all show up.

Installation Instructions
1. Download query_sonicwall_vpn.pl.txt and copy and rename to your <path_cacti>/scripts/query_sonicwall_vpn.pl
2. Import the Template cacti_host_template_sonicwall.xml
3. When creating graphs you will be prompted to enter a maximum value for decrypt/encrypt bytes. You MUST enter a value equal to the fast connection of any of the tunnels being monitored from this device. Otherwise you will see huge spikes every 8 hours.

Hopefully this works for you, please let me know. I know the script is less than optimal, but I'm not really a programmer so I'd appreciate any feedback. Additionally, the basis for the script came from Dan Brummer in this post.

--wazoqaz
Attachments
query_sonicwall_vpn.pl.txt
Copy to your &lt;path_cacti&gt;/scripts/ directory and rename without .txt
(4.74 KiB) Downloaded 9746 times
cacti_host_template_sonicwall.xml
Template for CPU, Memory, Connections, and VPN Usage for Sonicwall Firewall
(44.99 KiB) Downloaded 13046 times
jond3rd
Posts: 3
Joined: Wed Sep 27, 2006 2:56 am

Post by jond3rd »

Hi,

Thanks for your script and template. Iv'e try using it but I cannot see a graph on CPU and Memory, Connections seems to be graphing fine. Any hints?


Regarsd,
-jon-
wazoqaz
Posts: 15
Joined: Wed May 24, 2006 9:40 am
Location: md, us
Contact:

Post by wazoqaz »

jond3rd - are you running the SonicOS Enhanced? If not, then you won't see the cpu or memory. From my testing those were only reported by firewalls running the Enhanced version.

Let me know which version of the firmware you are running on which platform.
jcheney
Posts: 8
Joined: Tue Aug 15, 2006 1:48 pm
Contact:

Post by jcheney »

jond3rd:
I had the exact same problem, I was running the Sonic Enhanced and still only got the connections graph. Upgrading to the most recent version fixed this, and now everything works perfectly.

I wish I had thought to write down the old version number...

[Edit]
By the way, thanks for the great set of templates. I really appreciate it.
[/Edit]
jond3rd
Posts: 3
Joined: Wed Sep 27, 2006 2:56 am

Post by jond3rd »

Hi,

I am running SonicOS Enhanced 3.1.0.12-46e on a SonicWall 4060

I'm not getting any graphs on CPU's and Memory
wazoqaz
Posts: 15
Joined: Wed May 24, 2006 9:40 am
Location: md, us
Contact:

Post by wazoqaz »

jond3rd,

I developed and tested the scripts against our new Sonicwall Pro 4060 running SonicOS Enhanced 3.2.0.3-54e, which I believe is the latest firmware release.

I don't have any older boxes to test against sorry, and seeing as how this one is in production I can't monkey too much with. So all I can say at this point is to update to lastest version and see if you get anything then.

Just as an aside though my memory graph has been completely flat for the last 2 weeks at 25%.


jcheney,

My pleasure. It is finally nice to be able to give back to the community.

--wazoqaz
jcheney
Posts: 8
Joined: Tue Aug 15, 2006 1:48 pm
Contact:

Post by jcheney »

jond3rd:
I am pretty sure that upgrading to the latest firmware will solve your problem. I think that the version I was using that didn't work was 3.1.something, and once I upgraded to 3.2.0.3-54e, it worked perfectly.

If the upgraded firmware doesn't work, then we can start taking a look at everything else.
jond3rd
Posts: 3
Joined: Wed Sep 27, 2006 2:56 am

Post by jond3rd »

Thanks for the information, so sad I can't upgrade to the latest firmware because our subscription is already expired. Time to initiate renewal process I guess. I'll let you know if upgrading to the latest firmware will solve my problem. Thank you for the replies.
jlucas
Posts: 7
Joined: Sat Oct 14, 2006 10:11 pm

Strange error... xml file not dreated on import

Post by jlucas »

Thanks wazoqaz for creating the scripts im looking forward to getting them working. I have a small issue with the data query. It appears the sonicwall_vpn.xml file never gets created. Im on version 0.8.6h of cacti. Running a verbose query :

__________________________________

Data Query Debug Information

+ Running data query [18].
+ Found type = '4 '[script query].
+ Could not find data query XML file at '/var/www/html/cacti/resource/script_queries/sonicwall_vpn.xml'
+ Error parsing XML file into an array.
+ Could not find data query XML file at '/var/www/html/cacti/resource/script_queries/sonicwall_vpn.xml'
+ Could not find data query XML file at '/var/www/html/cacti/resource/script_queries/sonicwall_vpn.xml'
+ Could not find data query XML file at '/var/www/html/cacti/resource/script_queries/sonicwall_vpn.xml'

_________________________________

the file sonicwall_vpn is not created after the import of cacti_host_template_sonicwall_749.xml

Any one have an idea? can someone post the file sonicwall_vpn.xml so I can simply drop it in this directory?

Thanks all.
jlucas
Posts: 7
Joined: Sat Oct 14, 2006 10:11 pm

I should add

Post by jlucas »

I should add ...this is the result I get from xml template import

Import Results

Cacti has imported the following items:

Round Robin Archive

[success] Daily (5 Minute Average) [update]
[success] Weekly (30 Minute Average) [update]
[success] Monthly (2 Hour Average) [update]
[success] Yearly (1 Day Average) [update]

CDEF

[success] Turn Bytes into Bits [update]

GPRINT Preset

[success] Normal [update]

Data Input Method

[success] Get SNMP Data [update]
[success] Get Script Data (Indexed) [update]

Data Template

[success] Sonicwall CPU Usage [update]
[success] Sonicwall Memory Usage [update]
[success] Sonicwall Connection Cache [update]
[success] Sonicwall VPN - Traffic [update]

Graph Template

[success] Sonicwall CPU Usage [update]
[success] Sonicwall Memory Usage [update]
[success] Sonicwall Connection Cache [update]
[success] Sonicwall VPN Traffic (bits/sec) [update]
[success] Sonicwall VPN Traffic (bits/sec, Total Bandwidth) [update]

Data Query

[success] Script - Sonicwall VPN [update]

Host Template

[success] Sonicwall [update]
wazoqaz
Posts: 15
Joined: Wed May 24, 2006 9:40 am
Location: md, us
Contact:

Post by wazoqaz »

jlucas,

I'm not sure why it didn't import correctly, but check you inbox for the a copy of the file.
User avatar
icetoad
Cacti User
Posts: 65
Joined: Wed Oct 18, 2006 6:20 pm
Location: Orlando
Contact:

Post by icetoad »

I have the same issue with the sonicwall_vpn.xml file. The data import shows no problems but the file is not on the hard drive anywhere. :?
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest