Commit Graph

389 Commits

Author SHA1 Message Date
Neil Lathwood
7bb329661f Set allow_duplicate_sysName to be false by default (#5027) 2016-11-27 22:03:01 +00:00
Tony Murray
9a33464c52 refactor: Centralize includes and initialization (#4991) 2016-11-21 20:12:59 +00:00
laf
6006720b7f Re-added one default 2016-10-20 22:19:07 +00:00
laf
46d2f578e7 added central function and updated 2016-10-18 03:06:03 +00:00
NetworkNub
2aae3e6dff add xdp exclude device filters 2016-10-17 00:38:47 -04:00
Eldon Koyle
5749179cf5 feature: Add the ability to include an LDAP filter for users/groups in AD (#4494)
* Add auth_ad_(group|user)_filter options

* use global

* Fix some AD annoyances

Use the power of the LDAP filter to minimize the number of queries and
hopefully help performance in get_userlist, change semantics of
auth_ad_(user|group)_filter in $config to be anded with
samaccountname=USERNAME.

* remove unused variable

* update documentation

* Update Authentication.md
2016-09-21 14:42:59 -05:00
Tony Murray
ce95ceaa2b refactor: set mysqli as the default + cleanup (#4430)
* refactor: set mysqli as the default
dbFacile.mysqli cleanup
Init $db_stats array
number_format() returns string
remove unreachable statement, commented code, and unused global

* Fix style issues
2016-09-14 09:05:32 +01:00
Neil Lathwood
7dec670494 refactor: Updated a lot of references to LibreNMS - copyright still left intact (#4339) 2016-09-08 08:12:23 -05:00
David Bell
f00c383d60 fix: Stop irc bot crashing on .reload #4353
* Removed duplicate include

* Move set_debug into functions.php, and restore the (re)loading of includes/defaults

* Move debug call until after function has been included
2016-09-07 18:42:49 +01:00
Tony Murray
9284bc60ff Update code in includes to be PSR-2 compliant (#4220)
refactor: Update code in /includes to be psr2 compliant #4220
2016-08-28 18:32:58 +01:00
Tony Murray
15b0cd68ea Move libraries in /includes to /lib (#4217) 2016-08-26 14:04:21 +01:00
Neil Lathwood
1055003d3f Remove requirement for ['enable_printers'] (#4192) 2016-08-24 12:42:06 -05:00
Tony Murray
7b93b564da Centralize class loader (#4169)
Move the classloader to as early as possible in defaults.inc.php
This should cover all application entrances.
Set install_dir based on the location of defaults.inc.php
2016-08-22 23:59:59 +01:00
Tony Murray
e920e28e48 Change the default error_reporting level to include all fatal errors (#4165)
* Change the default error_reporting level
This will hopefully save confusion when there are things like syntax errors and missing required files.

* Add E_PARSE error as well.
This is a fatal error too.
2016-08-22 23:55:21 +01:00
Aaron Daniels
4c060a430a - Made module generic, not cisco specific. 2016-08-12 17:21:55 +10:00
Aaron Daniels
27eb389409 Merge branch 'master' into issue-3999 2016-08-12 16:34:13 +10:00
Aaron Daniels
b9747b2002 CISCO-NTP-MIB
A new Discovery/Poller module to collect NTP statistics from devices which support the CISCO-NTP-MIB
Discovered peers are stored using components and statistics are displayed using 'applications'
A critical alarm is raised when a stratum of 16 is reported.
2016-08-09 07:14:25 +10:00
Tony Murray
e3772e2653 Don't use $config['rrdcached_dir'] anymore, always use relative directories when using rrdcached.
Wait for output on every command, this prevents input left in the buffer from messing up subsequent commands.
It doesn't seem like there is a penalty, but I'd have to do more testing.
2016-07-25 16:24:09 -05:00
Brandon Boudrias
cccb07d2a7 matching default port description types with their names 2016-06-30 17:05:55 -07:00
Tony Murray
c3dfba4a20 Revert "Sort many items in defaults.inc.php" 2016-06-08 15:34:11 -05:00
Tony Murray
c6112d9a43 Sort many items in defaults.inc.php
The main target is the poller and discovery modules
2016-06-06 23:45:19 -05:00
Rick Hodger
ddb04ad870 Added config option to includes/defaults.inc.php 2016-05-27 17:04:29 +01:00
Tony Murray
84acb3077b Merge pull request #3473 from laf/issue-3012
Add support for stopping devices being added with duplicate sysNames
2016-05-10 17:16:05 -05:00
laf
8a46c7611d Add support for stopping devices being added with duplicate sysNames 2016-05-02 20:20:29 +00:00
laf
624fbede32 Added ability to specify a different tile url 2016-05-02 19:59:45 +00:00
laf
c14577db34 Added alert log purge setting - defaults to 365 2016-05-02 19:06:51 +00:00
Sawachier
683d0617c7 Update defaults.inc.php 2016-04-19 23:52:32 +02:00
jpasquie
c0697be934 Update defaults.inc.php 2016-04-19 23:48:56 +02:00
HenocKA
f17f061bea adding route for vrf lite 2016-04-19 23:48:56 +02:00
Adam Winberg
5871681015 change from poller_module to include from os polling 2016-04-19 13:58:38 +02:00
Adam Winberg
5f9c797bce Added RSSI and MNC graphing to Cisco WWAN routers 2016-04-14 16:18:53 +02:00
Aaron Daniels
111a52d48c Merge branch 'master' into issue-2193 2016-04-12 07:34:40 +10:00
Juho Vanhanen
0b078e0486 Add https transport for influxDB 2016-04-01 17:53:56 +03:00
Aaron Daniels
0d6cfec589 Nagios Services
- Moved check-services.php to a poller module
    - Added performance data collection to the poller
    - Centralised DB functions to includes/services.inc.php
    - Created add/edit/delete functions off the device, services page
    - Removed legacy edit/delete interfaces.
    - Moved and modified check.inc scripts
    - Documentation Updates
    - Modified services table
2016-03-15 22:23:14 +10:00
pblasquez
591c40a6f4 Update defaults.inc.php 2016-02-17 13:10:07 -08:00
HenocKA
0161260b17 merging 2016-02-13 21:48:26 +01:00
Neil Lathwood
fa783dc07e Merge pull request #2841 from adaniels21487/issue-2665
Cisco OTV
2016-02-10 19:49:59 +00:00
HenocKA
24df0a059c merging 2016-02-08 20:12:05 +01:00
Maximilian Wilhelm
79eab54fd9 Allow ignoring unmapable interfaces in poller.
When using the ifName or ifDescr as means to map discovered ports to
  known ports in the DB (think of port association mode) it's possible
  that we're facing the problem that the ifName or ifDescr polled from
  the device is unset or an empty string (like when querying some ubnt
  devices...). If this happends we have no way to map this port to any
  port found in the database. As reported this situation may occur for
  the time of one poll and might resolve automagically before the next
  poller run happens. Without this special case this would lead to new
  ports added to the database each time this situation occurs. To give
  the user the choice between »a lot of new ports« and »some poll runs
  are missed but ports stay stable« the 'ignore_unmapable_port' option
  has been added to configure this behaviour. To skip the port in this
  loop is sufficient as the next loop is looping only over ports found
  in the database and "maps back". As we did not add a new port to the
  DB here, there's no port to be mapped to.

  I'm using the in_array() check here, as I'm not sure if an "ifIndex"
  can be legally set to 0, which would yield True when checking if the
  value is empty().

Signed-off-by: Maximilian Wilhelm <max@rfc2324.org>
2016-02-03 21:14:24 +01:00
HenocKA
6de58f55df merging 2016-02-02 12:58:05 +01:00
Neil Lathwood
b72c1282d9 Merge pull request #2797 from BarbarossaTM/issue-386-v2
Ability to use ifIndex,ifName and ifDescr to create and update port rrd files
2016-01-29 13:05:03 +00:00
HenocKA
e755edfafc modify order of cisco-vrf-lite 2016-01-26 15:47:35 +01:00
HenocKA
08658e34ae Syntax update 2016-01-26 15:46:03 +01:00
HenocKA
724ad08d76 discoverying and polling VRF 2016-01-26 15:42:59 +01:00
HenocKA
21d2b45742 Syntax update 2016-01-26 15:27:50 +01:00
HenocKA
0ac8f584b2 discoverying and polling VRF 2016-01-26 15:22:49 +01:00
Maximilian Wilhelm
2c9df26bbf Update discovery and poller to allow stable interface mapping by ifName/ifDescr based port mapping.
By default libreNMS used the ifIndex to associate ports just found via SNMP
  with ports discoverd/polled before and stored in the database. On Linux boxes
  this is a problem as ifIndexes are rather likely to be unstable between reboots
  or (re)configuration of tunnel interfaces (think: GRE/OpenVPN/Tinc/...), bridges,
  Vlan interfaces, Bonding interfaces, etc.

  This patch adds a »port association mode« configuration option per device which
  allows to map discovered and known ports by their ifIndex, ifName, ifDescr, or
  maybe other means in the future.
  The default port association mode still is ifIndex for compatibility reasons.

  As port RRD files were stored by their ifIndex before, they are now identified
  by their unique and stable port_id to ensure a stable and unique mapping and
  allow future port association modes to be added without requireing any further
  internal changes. Existing RRD files are renamend accordingly in discovery and
  poller tools to ensure stability of port associations in both modules as we
  don't know which might run first after an update.

Signed-off-by: Maximilian Wilhelm <max@rfc2324.org>
2016-01-26 13:49:30 +01:00
Maximilian Wilhelm
64ce4f335f Add HTTP Authentication / LDAP Authorization module.
This Authentitation / Authorization module provides the ability to let
  the webserver (e.g. Apache) do the user Authentication (using Kerberos
  f.e.) and let libreNMS do the Authorization of the already known user.
  Authorization and setting of libreNMS user level is done by LDAP group
  names specified in the configuration file. The group configuration is
  basicly copied from the existing ldap Authentication module.

  To save lots of redundant queries to the LDAP server and speed up the
  libreNMS WebUI, all information is cached within the PHP $_SESSION as
  long as specified in $config['auth_ldap_cache_ttl'] (Default: 300s).

Signed-off-by: Maximilian Wilhelm <max@rfc2324.org>
2016-01-21 21:49:08 +01:00
Aaron Daniels
8f4dbb5338 Cisco OTV
Implements the CISCO-OTV-MIB to retrieve OTV counters from Cisco devices.
This collects information on the configured Overlays and Adjacencies

Statistics are collected for the amount of VLAN's on each overlay and the amount of MAC addresses available over each OTV endpoint.
OTV alerts are collected and generated if the appropriate alerting rules exist.

Data is displayed under routing at both the global and device level.

Includes function snmpwalk_array_num, which performs a numeric SNMPWalk and returns an array containing $count indexes
One Index:
 From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0
 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27.18']['655360'] = 0
Two Indexes:
 From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0
 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27']['18']['655360'] = 0
And so on...
2016-01-21 22:04:20 +10:00
Aaron Daniels
bf37312bdc Cisco CBQOS
Implements the CISCO-CLASS-BASED-QOS-MIB to retrieve QOS counters from Cisco devices.
Policy and Class-map details are collected and stored in the database.
Details are presented on a new "CBQoS" tab of the interface that the policy is applied to.
Includes a policy selector that allows you to select which policy-map to show graphs for.

Each class-map has its own rrd file, in which 3 metrics are stored: Bytes, QoS Drops, Buffer Drops.
This can produce a LOT of rrd files.

As an example:
A Cisco 4500 series switch, running MQC on 200 ports. Each port has a common 5 class queueing policy applied, this creates 1000 (5 x 200) RRD's.

Because of this I have currently set:
```
$config['discovery_modules']['cisco-cbqos']    = 0;
```

Includes function snmpwalk_array_num, which performs a numeric SNMPWalk and returns an array containing $count indexes
One Index:
 From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0
 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27.18']['655360'] = 0
Two Indexes:
 From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0
 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27']['18']['655360'] = 0
And so on...
2016-01-21 21:18:14 +10:00