18059 Commits

Author SHA1 Message Date
Tony Murray
292d6a0fdb permissions query fixes (#12220) 2020-10-15 20:38:26 -05:00
Tony Murray
0de03ad582 validate dashboard id (#12219) 2020-10-15 12:43:24 -05:00
Tim de Boer
aa9f6d2cbe Update IRC-Bot.md (#12216)
Fixed the IRC-Bot Extensions link.
2020-10-15 10:33:20 -05:00
Richard Kojedzinszky
2ca6f2f8d4 schema: add missing primary keys (#12106)
* schema: add missing primary keys

* Exclude ipv4_mac.id

* Made primary key migrations SQLite compatible

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-14 20:37:40 -05:00
Jellyfrog
3bfafc857f Convert Device>vlan view to Laravel (#12163)
* Convert Device>vlan view to Laravel
2020-10-14 19:40:44 -05:00
Tony Murray
31881303f0 add two day period to graph widget (#12210) 2020-10-14 19:33:54 -05:00
SourceDoctor
e7f2de79ec Health Overlib Correction (#12203)
* Health Overlib Correction

* style correction
2020-10-11 17:07:52 -05:00
ottorei
40479ce36a Update only latest Null Value Row in Outages Table (#12206)
* Fix multiple null-values on outages

Fixes a specific issue where multiple null-values on device_outages-table prevent updating the correct outage details

* Fix multiple null-values on outages

Fixes a specific issue where multiple null-values on device_outages-table prevent updating the correct outage details
2020-10-11 23:55:06 +02:00
Tony Murray
2793585cce Fix SQL injection vulnerability in MAC Accounting graph (#12204)
* Fix SQL injection vulnerability in MAC Accounting graph
I didn't have any real test data, so tried to keep the changes minimal.

* fix style
2020-10-11 01:17:25 +02:00
Jellyfrog
bbf394362e Add table of content to installation guide (#12202) 2020-10-09 07:52:02 -05:00
mjeffin
90483b8cfa Update Install-LibreNMS.md (#12201)
Change the symbol for comments from # to ; 
This threw an error for me while following the steps and had to google to fix the issue. Changing to ; might help people like me who are new to php. Not sure if it would affect any older versions.
2020-10-08 15:32:33 +02:00
Jellyfrog
782db09bd4 Add docs for Supermicro Superdoctor (#12200) 2020-10-08 12:55:06 +02:00
Tony Murray
1e4702fa4f Support multiple daily process locking backends with distributed polling (#11896)
* Implement locks in the file cache

* Replace custom locks

* implement restore lock
Used when re-hydrating

* remove legacy use statements

* Add class descriptions

* Fix style

* Default to database cache driver

* missed cache_locks table
prevent chicken-egg issue

* style fixes

* Remove custom file lock implementation

* missed items from file cache

* Update schema definition
hmm, other schema noise must be from manual modification as this is generated from a freshly migrated db.

* require predis, it is pure python, so no harm in adding

* and set predis as the default client
2020-10-07 07:36:35 -05:00
RobJE
e52531fba4 Ircbot fix (#12192)
* send alert to channel, do not send channel key

* correct indentation, use spaces not tab
2020-10-06 21:07:49 +02:00
Dag Bakke
f9d1719296 make Eaton Gigabit Network Card (AKA M2) a separate OS (#12156)
* - make Eaton Gigabit Network Card (AKA M2) a separate OS
  (this hardware shares the sysOID with an older product, but not much more than that.)
- add relevant and updated mib-files. This creates duplicates of the same mibfile in mibs/.
  unsure if this can be avoided

* axed some old mibs again
2020-10-06 16:57:45 +02:00
Tony Murray
d66751c192 Revert "Ignore changelog in docs search (#12194)" (#12199)
This reverts commit 2832230c1ce0668d6ba93d2afce0a3b262f110c6.
2020-10-06 07:40:35 -05:00
Tony Murray
0d47a74cd2 Updated linux snmpd.conf example (#12195)
remove hard-coded oids an use the defaults
The Unix.php code detects both
2020-10-06 07:37:46 -05:00
Dag Bakke
45788130a0 Put all Eaton mibs in the same subdir, update mibs, update YAML-files (#12197)
* put all Eaton mibs in the same subdir (common dependencies on EATON-OIDS, avoid file duplicates)
* update all mibs (for which a more recent version was found)
* update relevant YAML-files, so mib_dir points at eaton/.
2020-10-06 07:35:12 -05:00
Jellyfrog
b5d94c38a6 Add support for Supermicro hardware/serial discovery (#12176)
* Add support for Supermicro hardware/serial discovery

* add tests

* prefix with supermicro

* Update ServerHardware.php

* Update linux_supermicro.json

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-06 01:16:29 -05:00
Jellyfrog
3fdbd5c720 Fix Linux OS mib_dir usage (#12190)
* remove invalid mib_dir

* set mibdir for supermicro

* set mibdir for dell

* set mibdir for hp

* styleci
2020-10-06 00:20:27 -05:00
Jellyfrog
2832230c1c Ignore changelog in docs search (#12194) 2020-10-06 02:20:51 +02:00
Jellyfrog
4068b04cc9 Add missing mkdocs extension (#12193)
Regression from 551e95a2e0da814af3cd08141c2f2fab30da2d4f
2020-10-06 01:52:16 +02:00
RobJE
c2db8f3c58 add a bunch more Brocade Ironware devices (#12191) 2020-10-06 01:01:14 +02:00
Tony Murray
1b0210e16b Add opengear hardware discovery (#12189)
Thanks @sjtarik
2020-10-05 18:10:11 +02:00
Tony Murray
88b40c3d6c All os detection now uses Yaml (#12186)
* All os detection now uses Yaml
Move OS detection code into the Core module.
Defer all OS with snmp queries.
Add snmpwalk option.
Port ubnt and mobileiron to yaml.

* Silly ide refactor
2020-10-05 14:26:37 +02:00
Tony Murray
210be6266e Yaml support to translate sysObjectID to get hardware (#12187)
* Yaml support to translate sysObjectID to get hardware

* restore ironware behavior

* ...
2020-10-05 13:50:28 +02:00
SourceDoctor
f6e3397a80 Cleanup generate_sensor_link (#12154)
* Cleanup generate_sensor_link

* Cleanup generate_sensor_link

* remove fixifname on sensor function

* Update functions.inc.php

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-04 20:45:41 -05:00
Dan Baker
a818b26b58 Ciena SAOS 8 device improvements (#12172)
* Ciena SAOS 8 device improvements
- improved interface polling for certain devices with broken ifXEntry and long ifEntry value caching
- added G.8032 virtual ring status sensors
- adjusted default alert threshold for a sensor because some devices provide a nonsensical value (more work to be done here)

* Style fixes

* missed whitespace

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-04 20:43:54 -05:00
Anders Lowinger
56852380cc Additional fix for Cisco Crossbar overview missing (#12185)
* Additional fix for Cisco Crossbar overview missing

* Fix code style
2020-10-04 19:51:21 -05:00
Hans Erasmus
2bd4f146b5 Accommodate upcoming php 7.3 change (#12180)
* Accommodate upcoming php 7.3 change

An announcement on Twitter as well as [this](https://github.com/librenms/librenms/pull/12118) says future release will depend on PHP7.3 minimum. CentOS 8 ships with 7.2 by default. Also, the composer package's availability via `dnf` was dropped somewhere by CentOS project, so one needs to install it "manually" nowadays. I have yet to find a different solution than the one showed here. Any inputs welcome.

* Removed the dnf list command

* Made manual composer install the fallback method

* Fixed minimum PHP version.
2020-10-04 23:46:29 +02:00
Tony Murray
4f4ebacef9 Suggest Fast Ping before 1 Minute Polling (#12179)
* Update 1-Minute-Polling.md

* Update 1-Minute-Polling.md
2020-10-03 18:33:59 +02:00
TheGreatDoc
6357db57f7 New device: Rohde & Schwarz Sx800 (#12181)
* New device R&S

* Fix SVGs

* Fix SVG (v2)

* Fix definition
2020-10-03 18:31:44 +02:00
Tony Murray
6d2a8867dc Fix lnms update command (#12182)
hmm, other schema noise must be from manual modification as this is generated from a freshly migrated db.
2020-10-03 18:27:59 +02:00
Avinash Kumar
ff4dcd5678 icecast doc correction (#12183) 2020-10-03 18:26:41 +02:00
Negatifff
173ca83018 Refresh in widget settings (#12127)
* add timeout for widget in widget settings

* forgot get saved timeout and added default value for all widgets

* code correction

* move refresh to json

* forgot remove old code

* added refresh validate rule

* fix empty refresh for exist widgets

* fix empty settings for new widgets

* Set refresh in base
Update refresh at runtime (doesn't interrupt previous timeout)

* Update WidgetSettingsController.php

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-02 08:52:04 -05:00
FingerlessGloves
039ce4cb55 Add FreshTomato OS definition which is fork of tomato (#12173)
* add freshtomato snmprec file

add freshtomato snmprec , generated from latest freshtomato release

* add freshtomato test data

add freshtomato test data, generated from latest freshtomato release

* add freshtomato os definition

add freshtomato os definition

* freshtomato discovery for version, hardware model 

freshtomato discovery for version, hardware model

* update freshtomato.snmprec, extra oid

update freshtomato.snmprec, extra oid now showing since going to 1.68, from over night update.
LibreNMS can now show version and hardware (router model) correctly.

* update freshtomato.json, hardware is now populated

update freshtomato.json, hardware is now populated, since going to 1.68, definition discovery is working correctly it seems.

* Regenerate without lo ignored.

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-02 08:50:49 -05:00
Olen
ba636e9617 IRC Add simple tag-parsing of colors and highlights in alerts (#12138)
* Add simple tag-parsing of colors and highlights in alerts

* Fixing a few CodeClimate-issues

* Fixing a missing ;

* Fixing some more typography

* Whitespace...

* Deduplicate code

* Missing ; - too much python lately...

* Fix end of function name

* Simplifying sendAlert a bit

* Keeping up with PR#12141

* ; again...

* this->sendAlert...
2020-10-02 07:54:12 -05:00
Diego Canton de Brito
5b892dc4f8 Force lower case (#12178)
We force the strings returned from the "unbound-control stats" command to "lower case", avoiding problems with future changes to the unbound output in other variables.

All code must contain lower case letters in the $ unbound [] variable
2020-10-01 19:59:24 -05:00
Tony Murray
863fb96205 Scheduled maintenance test (#12171)
* alert schedule test

* Fix style

* Skip broken tests for now
2020-10-01 03:00:42 -05:00
gerhardqux
09ae9e49bd Do not remove users with API tokens (#12162)
* Do not remove users with API tokens

* Use eloquent

* Fix missing namespace and convert fully to Eloquent

* fix bug in purge

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-10-01 01:16:28 +02:00
Tony Murray
a08b092e4b Update PHP dependencies (#12169) 2020-10-01 00:40:13 +02:00
Dan Baker
f2746f526c Corrected information about mib_dir (#12174)
Corrected information about mib_dir. An array is not handled by discovery.php -- only one directory may be specified.
2020-10-01 00:30:44 +02:00
Dag Bakke
7bd0ee4260 Update Example-Hardware-Setup.md (#12170)
Additional example hw.
2020-09-30 10:12:41 +02:00
Tony Murray
551e95a2e0 Docs: don't index changelogs (#12166)
* Docs: don't index changelogs

* Exclude 2019 changelog
2020-09-30 10:11:32 +02:00
Adam Bishop
41ed0537b4 Fix midnight poller data loss (#11582)
* Handle more signals

* Flush buffers before exiting process
This ensures log messages aren't lost

* Restart process before jobs have finished
If there is a very log running job it can cause service restart to
take over 5 minutes.

We tweak the order of things to make sure that running processes
continue, but nothing more is scheduled.

The worst case impact is that a pollling/discovery job gets
scheduled twice, but this should not be a big issue - this should
only occur at most once per day.

* Remove python 3.8 feature

* Ensure that processes from the previous invocation are reaped

* Correct typo's

* Attach subprocess descriptors to /dev/null

Occasionally, PHP would throw a fit and crash when its stdout went
away. To avoid this, we attach stdout to devnull.

This means we lost output of daily.sh - but this is already recorded
in $LOGDIR/daily.log

* Don't immediately schedule long running jobs

To avoid the situation where the maintenance reload happens or a sighup,
then a second long running job is immediately started, we wait
(`last_[poll/discovery]_timetaken` * 1.25) seconds before scheduling
any jobs.

* Add `psutil` to requirements

* Add support for "systemctl reload" to the unit files

* Add a fallback for systems that don't have psutil

* Reduce CPU load when psutil is not installed

* Don't avoid double polling by extending the timeout

This shouldn't happen due to locks

* Remove fallback option

* Remove extra variable

* Fix issue introduced during rebase

* Fix issue introduced when fixing issue introduced during rebase

* Make psutil optional
2020-09-29 23:50:40 -05:00
Olen
a8ca361acd Add missing setting of channels to join (#12160) 2020-09-29 23:12:09 -05:00
Jellyfrog
0e99b472c2 Add Blade Submenu component (#12159) 2020-09-29 23:11:05 -05:00
Tony Murray
90d0d46dfb Bump version to 1.68 1.68 2020-09-29 22:16:05 -05:00
Tony Murray
a3c7426a32 Changelog for 1.68 2020-09-29 22:16:04 -05:00
Jellyfrog
04ab47707a Fix edgeswitch regex (#12168) 2020-09-30 01:04:56 +02:00