Commit Graph

7585 Commits

Author SHA1 Message Date
Tony Murray
881d581448
Fix existing, oops (#14332) 2022-09-09 15:12:02 -05:00
bp0
94830fe47e
API update_device, make location field work (as does location_id) (#14325)
* update_device, add location to list of bad_fields

The field 'location' can't be changed using API update_device_field, even when used with 'override_sysLocation'. It should not return success, with the "Device fields have been updated" message that is untrue.

* Actually make it work

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-09-09 11:40:55 -05:00
Jellyfrog
152497a098
PHPStan: Enable more checks (#14318)
* PHPStan: Enable more checks

* Fixes

* Fixes

* Deprecation fixes
2022-09-09 07:08:06 -05:00
Jellyfrog
8692abb830
Prevent errors when hrStorageTable doesn't exist (#14327)
Prevents Illegal string offset 'hrStorageDescr'
2022-09-08 21:52:33 -05:00
Maikel de Boer
bd02df14b6
Added support for UHP VSAT modems (#14317)
* Started UHP VSAT support

* continue uhp

* end of day

* uhp  support

* fixed icon / logo

* cleanup

* added test data

* Delete Uhp.php

If the file is empty let's delete it

* added test data

* Update uhp.yaml

spacing fix

* Fixed identation

* New test data

* Fixed

* styling

* fix

Co-authored-by: PipoCanaja <38363551+PipoCanaja@users.noreply.github.com>
2022-09-08 15:27:51 +02:00
Tony Murray
fdbee0f5ee
Revert "ZTE ZXA10 Update (Added dBm graphs) (#14049)" (#14320)
This reverts commit 6e98139cd1.
2022-09-08 09:04:37 +02:00
PipoCanaja
53bfb24ef9
Migrate xDSL code to module, and add support for VDSL2 MIB (#14207)
* use component to discover if xDSL polling is needed

use component to discover if xDSL polling is needed

* Components OK, Polling in correct files, no DB for VDSL

* GUI

GUI_suite

* per port as well

* rename

* interface listing

* draytek_snmpsim

* fix arraymerge

fix names and max value

* schema

schema

style

* remove one dbFetchRows

remove 2x dbFetchCell

style

style

remove Legacy dbFetchRow

tests

tests

eloquent

more eloquent

more eloquent

one more gone

* fix properties access

eloquent_insert_update

style

tests

tests

tests

tests

* tests

tests

tests

* adslLineCoding

* Models

* fix not nullable cols in DB from code

default values

typo

rename

typo

schema

fix

fix

vdsl fix now

typo

typo

fix size

fix size

* Power values for VDSL

Power values for VDSL

Power values for VDSL

DB

* cleanup

* Rrd::checkRrdExists

* always enable DSL discovery

style

* xdsl module

* cleanup and move to Module

cleanup and move to Module

cleanup and move to Module

cleanup and move to Module

* Fix display

* fix polling and tenth

* remove legacy poller

* Style and Cosmetics

Cosmetics

Cleanup

* Translations

Translations

* exists

exists

* add test support for xdsl

* remove last component call

unused

* translations

* remove non standard onclick event on xdsl line

* Update Discovery Support.md

Update Poller Support.md

toner_gone

* Notification for removal of lnms config:set enable_ports_adsl true

* enable on devices with potential DSL interfaces

* tests are working now

fix teldat tests

* os_schema

* teldat

* move to new module structure

* move to new module structure

* wrong dump function

* wrong dump function

* laravel_through_key hidden

* Update notifications.rss

* Update notifications.rss

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-09-07 19:29:17 -05:00
Tony Murray
6342d69b18
Do not include _token in legacy vars (#14313) 2022-09-07 16:17:08 -05:00
Tony Murray
ae15c8eb2a
Port pages fixes and cleanups (#14310)
* Port pages fixes and cleanups
Fix mac display on device port page
Move ports query building into the graph page where it is used
Add the filter ui to the all ports graphs pages

* whitespace
2022-09-07 15:33:29 -05:00
Tony Murray
c3f31c14e0
Handle connection timed out errors in unix agent (#14286)
* handle connection timed out errors in unix agent

* Update unix-agent.inc.php
2022-09-06 12:00:35 -05:00
electrocret
e458f95bd8
Billing module fix/cleanup (#14309)
* Delete autoadd definitions

Never actually used. Inherited from Observium.

* Allow Billing API to set dir_95th (for agg bills)

Currently we're unable to set dir_95th via API to configure Aggregate bills. This should fix that.
2022-09-06 11:49:15 -05:00
Martin22
3f27d89278
Ray2 - Oid repair for BER sensor (#14302)
* Ray2 - Oid repair at ber
* Fix double dots
* New test data created
2022-09-06 09:38:17 +02:00
Tony Murray
302a989d4e
Email Transport: embed graphs by default (#14270)
* Email embed graphs

* Allow attachment for non-html
Add setting to webui
Correct $auth setting

* Cleanups, throw RrdGraphException instead of returning an error image.
Generate the error image later, giving more control.
Reduce code duplication a little

* Style and lint fixes
Change to flags

* Add baseline for lint errors I don't know how to resolve

* oopsie, changed the code after generating the baseline

* Tiny cleanups.  Make set DeviceCache primary, it is free.

* Docs.

* email_html note

* Allow control of graph embed at the email transport level to override the global config.

* Allow control of graph embed at the email transport level to override the global config.

* Add INLINE_BASE64 to make it easier to create inline image tags
2022-09-05 20:41:55 -05:00
Peca Nesovanovic
93572cd5d3
empty, not empty (#14304) 2022-09-05 16:06:42 -05:00
Jellyfrog
9e5ced28d4
Fix hrStorageType being undefined (#14260) 2022-09-05 22:34:59 +02:00
Tony Murray
4614183cca
Fix undefined variable (#14287)
https://flareapp.io/errors/1540406-undefined-variable-i/latest#F4
2022-09-05 18:12:43 +02:00
Tony Murray
09c6c725a1
Check if polling module exists (#14289)
Users have old configurations defined, do not try to include them and post a message about it
2022-09-05 09:22:59 +02:00
Tony Murray
8f5582f85a
Fix more percent calculations (#14294) 2022-09-05 09:22:42 +02:00
Tony Murray
c2761b4e12
Remove unused function (#14283)
duplicates other functionality
2022-09-04 13:04:55 +03:00
Tony Murray
5c76890373
Add @signedGraphTag() and @signedGraphUrl() blade directives (#14269)
* More secure external graph access
Add @signedGraphTag() and @signedGraphUrl() blade directives
Takes either an array of graph variables or a url to a graph
Uses a signed url that is accessible without user login, embeds signature in url to authenticate access
See Laravel Signed Url for more details.
Adds Laravel route to graphs (does not change links to use it yet)
@graphImage requires the other PR
Also APP_URL is required in .env

* missing files from rebase

* Fix url parsing with a get string

* allow width and height to be omitted

* Documentation

* Add to, otherwise it will always be now

* Doc note for to and from relative security

* fix vars.inc.php (Laravel has a dummy url here)
2022-09-03 12:48:43 -05:00
Jellyfrog
3e2d7435af
Fix more error exceptions (#14266) 2022-09-01 12:30:51 -05:00
Félix Bouynot
f0c92d02c8
Fix for Cisco group device health tab (#14265)
* Fix Cisco group devices health tab

* Fix indent

* Ternary if

* Update health.inc.php

* Update health.inc.php

* Update health.inc.php

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-09-01 12:30:00 -05:00
Tony Murray
f85064bdea
Fix unauth graphs again (#14268)
$auth = false; was in the wrong place
2022-09-01 02:50:46 -05:00
Tony Murray
6f5cf7727a
Misc webui code cleanups (#14242)
* Misc webui cleanups

* Style

* More

* graphing fixes

* More graph cleanups

* more fixes, graphs and device pages

* style
2022-08-30 12:55:37 -05:00
Jellyfrog
797d73ad16
Misc errors cleanup (#14257)
* Misc errors cleanup

* Rename the variable in the loop to match

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-30 09:00:12 -05:00
Tony Murray
323f0ea8b5
Fix removing all port groups (#14253)
* Fix removing all port groups

* Make backend work in the situation where this endpoint is used for more than just this setting change
change event is called multiple times when select2 is cleared (once for each item)
prevent duplicate backend calls
Remove no default Port Group item
2022-08-28 20:57:16 -05:00
Tony Murray
a664d12eb7
Fix ipv6 hexdec error (#14254)
* Fix ipv6 hexdec error
convert to SnmpQuery and Ipv6 util

* Don't walk other oids if one fails.
2022-08-28 20:47:51 -05:00
Tony Murray
cc787dbc28
Fix ciena-sds inventory bugs (#14252)
* Fix ciena-sds inventory bugs

* mib dir is extraneous
2022-08-26 09:25:51 -05:00
Jellyfrog
835eac1233
Fix some ErrorExceptions (#14241)
* Fix some ErrorExceptions

* Use Config::get default value

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-25 10:03:06 +02:00
PipoCanaja
70e0a17031
Fix Argument #2 ($array) must be of type array in cache (#14240) 2022-08-25 00:37:40 +02:00
PipoCanaja
2ae0e84091
Fix redeclare of function breaking tests in OS eltex-mes23xx (#14227)
* eltex
* function in Class file
* style
2022-08-24 23:05:38 +02:00
PipoCanaja
5b10d5a1ce
Quick fix for cipsec-tunnels Cisco implementation (#14232)
* fix for cipsec
* style
2022-08-24 23:04:54 +02:00
Tony Murray
603713e87c
Juniper bgp-peers cleanup (#14236)
Also found a device bug.  Held off on refactoring everything...
2022-08-24 14:45:59 -05:00
Tony Murray
db54161b10
Fix os_group unset errors (#14238)
Instead of requiring an isset check for os_group, just set it, but to null
valid isset checks will still work right since it is now set to null.
2022-08-24 14:45:43 -05:00
Tony Murray
33461e6092
firebrick bgp polling was broken (#14237)
It checked the wrong os variable, so was never run
Other option is to delete the code
2022-08-24 14:29:55 -05:00
Tony Murray
34163703fb
Percentage calculation helper (#14235)
* Percentage calculation helper
Helper function to prevent divide by zero mistakes
Replace all percent calculations

* style
2022-08-24 21:01:54 +02:00
Jellyfrog
1dbab5ac7e
Error reporting (#14190)
* Error reporting

* Move code to ErrorReportingProvider
Enable reporting of error (and warning) messages.
report module exceptions

* Restore flare key
Not needed to set late anymore.  We set up filtering before it is initialized.

* Remove unnecessary and maybe double Flare report

* lint

* Cannot use typed properties yet, use phpdoc

* fix handleError return type

* Filter both exceptions and reports (so we don't miss any)
Consolidate the check if reporting should be enabled

* Cache reportingEnabled check for the runtime

* Split out middleware to improve readability
Logging of why reporting is disabled
Fix reportingEnabled cache

* Style

* Return some user data

* Change to class based middleware, it looks nicer

* Fix error page error id report, add url.

* also rewrite intended url

* remove link

* Move ignition to production and update flare-client

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-24 00:33:28 +02:00
Félix Bouynot
7cd61ef57f
F5 partition ram (#14226)
* Add other RAM partitions

F5 does partition its RAM, display other partitions, see https://support.f5.com/csp/article/K44014003

* Create f5_ve-14.1.5.1.snmprec

* Create f5_ve-14.1.5.1.json
2022-08-23 14:02:50 +02:00
Peca Nesovanovic
c3545ce860
memcached undefined vars (#14225) 2022-08-23 13:46:11 +02:00
Félix Bouynot
b643a5033f
Add Cisco Flash storage support (#14219)
* Add Cisco flash storage discovery

* Add Cisco flash storage polling

* LibreNMS indentation

* Move file to storage module

* move file to storage module

* Rename and check

Rename the file and add a check only against Cisco devices

* Rename file

* Change parameter from mib name to file name

Co-authored-by: Tony Murray <murraytony@gmail.com>

* Add a first test file for review - Nexus C9340 NXOS ver 10.2.2

* Add first device test files for review - Nexus 9340 ver 10.2.2

* Add Cisco IOS 15.2.7 on C2960X snmprec file

* Add Cisco IOS 15.2.7 on C2960X test data file

* Create nxos_n5548-7.3.3.snmprec

* Create nxos_n5548-7.3.3.json

* Update nxos_n5548-7.3.3.snmprec

* Update nxos_n9340-10.2.2.snmprec

* Update ios_c2960x-15.2.7.snmprec

* Update nxos_n5548-7.3.3.json

* Update nxos_n9340-10.2.2.json

* Update ios_c2960x-15.2.7.json

* Update cisco-flash.inc.php

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-23 11:31:47 +02:00
Tony Murray
465fa3986a
Fix Undefined variable/key warnings (#14134)
* Fix Undefined variable/key warnings

* massage for test data

* restore set_numeric, only generates noise

* Fix ucd storage used (apparently free is not stored in discovery...)
2022-08-21 16:23:43 -05:00
Tony Murray
d2a692c3c4
Fix luminato port poll (#14217)
* Fix luminato port poll
I still don't like it, but this improves the code consistency a bit.

* better comments

* Update luminato.inc.php
2022-08-19 14:02:44 -05:00
Tony Murray
d36afc6a75
Fix unauth application graphs (#14216)
* Fix unauth application graphs

* Use when
2022-08-19 08:04:46 -05:00
Peca Nesovanovic
59fc562d99
autodiscovery fix (#14213)
* autodiscovery fix

* much simpler approach

* murrant suggestion

* Simplify even more

* Use nullable operator

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-18 20:30:57 -05:00
Warren Ashcroft
73fee2a1aa
Allow specifying the background colour in graph images (#14192) 2022-08-18 20:21:28 -05:00
Zane C. Bowers-Hadley
55c62b234e
add Opensearch\Elasticsearch monitoring (#14053)
* add new poller

* add a missing ;

* formatting cleanup

* graph stuff and metrics move

* add rrd name

* clean up metrics/rrd def

* more metric/rrd def cleanup

* cleanup

* add basic opensearch graphs

* add opensearch to apps.inc.php

* begin work on opensearch app page

* formatting cleanup

* add translog graphs

* add a missing graph

* fix pending tasks

* add the ability to fetch the saved cluster name

* add fetching the cluster name

* correct the opensearch comment

* add combined shard stats

* add indexing graphs

* correct graph name

* correct some units as being per second

* add more graphs

* add more items for graph sets

* cleanup of units and naming... also more graphs

* more graph stuff

* change the RRD def again and define a few more graphs

* finish basic graph sets

* more graph stuff

* another rrd def change

* add more graphs

* add some more graph sets

* correct unit for c_task_max_in_time

* more graph stuff

* more graph stuff

* correct the unit

* add missing tw_time and another rrd def change

* another unit change

* add trc graphs

* more graph stuff

* add tseg graphs

* add all shards graph to both cluster items

* more graph stuff

* update opensearch app page

* add Opensearch\Elasticsearch app

* add opensearch tests

* run php-cs-fixer on two files

* add alert examples for checking cluster status

* remove an item that was accidentally added as a metric in the test but is not

* derp! thanks jellyfrog

* make it come up as Elisticsearch\Opensearch in the webui

* no longer use components, but app_data, for cluster name change

* update the web side for opensearch for using app_data

* style fix

* update opensearch for new app data stuff

* update to the new Application model

* update poller and device app page for ES/OS

* style cleanup

* update graphs

* test fix

* more test cleanup

* Update alert_rules.json

* begin work on breaking out the RRDs

* update all non-multi rrd graphs for opensearch

* update time_all

* add a unass shards graph

* correct rrd name

* should all be good now

* add missing tm stats

* Un Assigned -> Unassigned

* style cleanup

* another style fix

* remove cluster_name from saved metrics as it is not a metric

Co-authored-by: Tony Murray <murraytony@gmail.com>
Co-authored-by: Jellyfrog <Jellyfrog@users.noreply.github.com>
2022-08-15 14:44:20 -05:00
rhinoau
4682e9385a
Initial support for Moxa AWK Industrial APs (#14197)
* Initial support for Moxa AWK Industrial APs

* discovery yaml OID changes
2022-08-15 08:55:34 +02:00
Maikel de Boer
4d4ac9dc38
initial commit (#14202) 2022-08-12 19:50:08 +02:00
Janno Schouwenburg
7b3a6250f0
Bats support (#14108)
* BATS support

* Removed disabled discovery modules

* Style change, more test data, removed unused rows

* Style correction LibreNMS/OS/Bats.php

* Removed old reference

* Another style correction add LibreNMS/OS/Bats.php

* Changed location info and temperature

* Style, again

* Style, again

* New testdata needed

* Fix wrong state color in discovery/bats.yaml

* New test data

* Update bats_bats.json

* Saved the test data in a different way

* More test data

* Manually changed test data

* New test data

* New test data

* Update bats_bats.json

* Saved the test data in a different way

* More test data

* Manually changed test data

* New test data

* New test data

* Delete bats_bats.snmprec

* Update bats.json

* Update bats.json

Co-authored-by: Maikel de Boer <mdb@tampnet.com>
Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-10 09:07:31 -05:00
Fehler12
8d863fbc83
Cisco SB/CBS environment sensors (#14154)
* Update ciscosb.yaml

Added detection for environment sensors (FAN and PSU) for cisco small business devices

* Added test data

* Update ciscosb_sg550x-8f8t.json

Korrektur Übertragungsfehler

* Update ciscosb_cbs250-24p-4x.json

* Update ciscosb_cbs250-24p-4x.json

* Update ciscosb_cbs250-24p-4x.json

* Update ciscosb_cbs250-24p-4x.json

* Update ciscosb_cbs250-24p-4x.json

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-08-07 20:12:07 -05:00