* Allow new {{ $xxxx }} syntax
* Properly handle urlencode on variable values without braking the URL, and uses Blades
* Doc
Doc typo
* use Guzzle for HTTP requests
* Add Basic auth support
* Doc update
* clean
* Revert Blades, but keep the {{ $xxxx }} syntax
* Revert Blades, but keep the {{ $xxxx }} syntax
* Init Vars and comments
* Notifications
* api-options are not required
* Update notifications.rss
Long option support in net-snmp relies on non-portable usage of getopt(3) with "-:" in the argument string, this doesn't work on all OS. Replace with the alternative -V which works everywhere.
* Refactor: use get_state_label() for the overview
* Move state translation to get_state_label()
Several html pages used similar database calls and sometimes very
different methodology to determine the state label and state text
before calling get_state_label(), so moved that part of the task
into the function itself instead of replicating the same code
multiple times on different pages.
* Move label creation to get_sensor_label_color()
Also removed a duplicate sensor class to unit function.
* Refactor some if/else statements for simplicity.
* Enable state translations for the inventory page.
* Remove blank line found at end of control structure
* Enable unit translation, fix typos.
* Change to dbFetchRow(), return string directly.
* Update functions.inc.php
* Stop displaying the raw value on state labels.
* Apply 1c7c3ca change for default case too.
* Add 2 class for graph / mini graph (styles.css)
Add 2 class for graph / mini graph (styles.css)
for changing bg color and more (mini graph port / device) (graph port / general)
* Update styles.css
Add 2 class for graph / mini graph (styles.css)
for changing bg color and more (mini graph port / device) (graph port / general)
* Add class CSS for mini graph
Add class CSS for mini graph
* Update graph.inc.php
Change graph.inc.php, add css class / overlib
* restore original bg #f5f5f5 .graph-all-common
restore original bg #f5f5f5 .graph-all-common
* Update ports.inc.php
correct extra \
* Update graph.inc.php
* Update ports.inc.php
* Update ports.inc.php
* Update graph.inc.php
* Comment line 88 URL.php, because description of location enlarge too much overlib devices's title
* Update Url.php
* Update Url.php
Line 88 -> re ident to pass travis...
* Default to null for group yaml discovery.
* Update test data for a154bda yaml group null fix.
* Changes to guessed limit functions for sensors.
Original behaviour
===================
The file `includes/discovery/functions.inc.php` contains
`sensor_limit_low()` and `sensor_limit()` which both attempt to
guess a sane value for sensors when no explicitly defined
low_limit or high_limit can be found during discovery.
Both switch control structures used in those two functions
have empty case statements which means that if one of those matches,
it's going to fall through and run the code for each subsequent
case until a `break` is reached.
For example, when we call `function sensor_low_limit(dbm, -13.036)`
it will return the value `-12.3842` instead of `null`. That is
because there will be a match at `case 'dbm':` which falls through
all the way to `case 'cooling':`, where it performs
`$limit = -13.036 * 0.95` before hitting a `break`.
Changed behaviour
===================
Removed `power_consumed` and `count` guessed low_limit and
high_limit, I personally added those sensor classes in PR #9471
when I didn't understand that a switch control structure has
fall-through behaviour so I can guarantee that guessing limits for
those is a mistake on my behalf. It should not be there, only
power_factor can have guessed limits. Apologies for the issue,
I'm still a beginning programmer!
Furthermore, I removed guessed high_limit values for `current`
and `power` because these are supposed to draw higher values as
more devices or components are installed on for example a PDU or
a chassis.
Finally, I removed guessed low_limit and high_limit for `dbm`
sensors, there is a much too large variance in power budget on
commercially available optical transceivers for there to be a
sensible window where you can guess these values.
* Documentation on adding sensor classes.
* Update test data - sensor limit changes @ 30212d2
* Improve UI of filter menu
In the current UI of the filter menu, it's not readily apparent that one, you are supposed to use the filter tabs, and two, that you need to refresh in order for the filter to apply. This request adds button colors to search, update, and refresh to make the filter bar and action buttons stand out.
* Only change search button color
Changed search button color to blue to fit in better
* Device Groups rewrite
Updated web ui
Static or dynamic groups allowed
Alert rule query builder
Translation support
Permissions support
* cleanup, make relationship save, and validate it
* builder WIP
* rules builder and rules saving/loading
* Parse query builder to Laravel Fluent query
* Upgrade existing groups when editing.
Properly update only dynamic groups when polling.
* remove unused old code
Update API and other places to use Eloquent
* debug output in poller restored
* Fix up some things
creating static
improved validation
fix js error on creation
Fix static groups in polling
* hide pattern for static group
* Implement authorization
Use in the menu too
* update schema
* fix rollback
* Don't abort on invalid queries
* fixes to query builder
* add test data, looks like macros aren't handled (omitted them because groups don't use them generally)
* Add macro support for QueryBuilderFluentParser
* add test for macro that accepts value
* More space in forms
Retain rules when converted to static
no duplicate names allowed
* Better error feedback
Update related devices on save
* Add button icon
* format
* update docs
* fix tests
* Fix some QueryBuilderFluentParser issues with OR
updated/more test data
* Show device groups runtime
fix querybuilder.json format
* Store table joins in the rules to minimize polling time
Update group joins in daily.sh (and when they are saved)
* Update daily.php
* Add units to time
* Device Groups rewrite
Updated web ui
Static or dynamic groups allowed
Alert rule query builder
Translation support
Permissions support
* cleanup, make relationship save, and validate it
* builder WIP
* rules builder and rules saving/loading
* Parse query builder to Laravel Fluent query
* Upgrade existing groups when editing.
Properly update only dynamic groups when polling.
* remove unused old code
Update API and other places to use Eloquent
* debug output in poller restored
* Fix up some things
creating static
improved validation
fix js error on creation
Fix static groups in polling
* hide pattern for static group
* Implement authorization
Use in the menu too
* update schema
* fix rollback
* Don't abort on invalid queries
* fixes to query builder
* add test data, looks like macros aren't handled (omitted them because groups don't use them generally)
* Add macro support for QueryBuilderFluentParser
* add test for macro that accepts value
* More space in forms
Retain rules when converted to static
no duplicate names allowed
* Better error feedback
Update related devices on save
* Add button icon
* format
* update docs
* fix tests
* Aruba IAP: Fix Radio State Sensor
Fix state sensor for radio status from warning when disabled to unknown state.
* Update aruba-instant.json
* Update aruba-instant_105.json
* Fix Software Version #
I don't think setting $firmware does anything, not to mention the regex wasn't matching correctly. I tested this fix tons of different software versions and they all seem to work.
* Revert "OS CIMC Software Version Number"
* version and features
* fixed feature
* Fix Extra Blank line EOF
* Extend the Dell drac module to report CMC status and sensors
* CMC status sensors do not have chassis id
* Update test data for drac OS
* Add missing test data for drac os
* WIP - Add MPLS Support
This introduce the generic MPLS support
- New database tables for MPLS LSPs
- actually discovery and polling on NOKIA SR OS (Timetra) devices
- new routing->MPLS HTML pages
- ToDo MPLS LSP paths table and views
Suggestions and improvements are welcome
* add db schema
* some fixes
* add path table, discovery and polling
* add path views
* add test data
* Convert MPLS module to new style
Implement a SyncsModels trait to simplify code a lot
* abs() for negative value from snmp (bug?), test data
* fix db schema
* Fix up test data, remove uneeded data in json
* fix whitespace
* change tab <h2></h1> ? by tab span and class like the other
replace bad tag h1 h2 by span and class to be in phase with the others link
* Update sensors-common.php
* Fix Software Version #
I don't think setting $firmware does anything, not to mention the regex wasn't matching correctly. I tested this fix tons of different software versions and they all seem to work.
* Revert "OS CIMC Software Version Number"
* cimc-version-fix
* added test data
* Update cimc.snmprec
* feature: Add a 'session' sensor type
This allows things like the SRX5800 SPU's to be graphed as they expose current and maximum usage in a table.
The intent is to contain things like TTY sessions, flow counters from other vendors, or other resources with support a finite number of simultaneous users or connections.
* Include the node description in the descr field
Chassis clusters use the same FPC's
* Track PanOS session count
* Add JunOS CP Flows
* Missed file containing overview
* Missed a spot
* remove custom sessions sensor and use count
* Update junos.yaml
* Update panos.yaml
* Dynamic entPhysicalIndex values for YamlDiscovery
* Use degree symbol when displaying temperature values
* Adjust SNMP options for new snmp_get_multi()
The OS polling module for mrv-od was using snmpget commands with
-Ovqs, rather than -OQUs, which meant that the equal sign was
stripped in the snmpget output. But that equal sign is now used
as the explode() delimiter so it broke the construction of the
returned array for the snmp_get_multi() function.
Additionally, I removed the NBS-CMMC-MIB:: prefix which is no
longer returned by snmp_get_multi() as part of the OID. Now,
the mrv-od.inc.php OS polling module is retrieving data from
positions in the array with actual content.
* Convert mrv-od to yaml, improve sensors discovery
Converted sensors discovery for mrv-od to yaml, retaining all
functionality for pre-cache, dbm, and temperature. Replaced specific
SFF-8472 Digital Diagnostics state sensors with generic ones, given that
we are now reading out detailed values through new dbm, current, voltage
sensors.
Reasoning: the generic Digital Diagnostics state sensors report state
diagsOk, or else the worst severity level measured among all of the
Digital Diagnostics values for that optical data point. You'd really
only want to set a generic "alarm" so the box can report that it
thinks something is wrong, whereafter a human can look at the graphs
and/or the CLI to draw their conclusions about the alarm. Otherwise,
things would quickly become too spammy as you are essentially duplicating
every sensor across both regular measurements and state measurements.
Further changes:
- Increase maximum number of detected PSUs from 4 to 8 per the MIB.
- State sensor to detect (in)sufficient power budget for all modules.
- Use skip_values to hide state sensors with the notSupported value.
- Use skip_values to hide sensors which are unsupported per the MIB,
signified by the device returning special values -1 or -2147483648.
- Add dBm, temperature "over" graphs to the mrv-od device header bar.
* Add mrv-od entity-physical support
MRV does not use the ENTITY-MIB data format, so we had to reconstruct
the inventory from their proprietary format using the following tables
from their NBS-CMMC-MIB:
- nbsCmmcChassisTable
- nbsCmmcSlotTable
- nbsCmmcPortTable
Additionally, since sensors didn't have their own ifindex in the
NBS-CMMC-MIB, I went ahead and appended the last OID digit to
the "containing" ifindex create a unique number. The same was
done for the sensors in the yaml-discovery.
* Test data for mrv-od, fix 2* pre-commit.php issues
* Fix entPhysicalIndex returning 0 instead of null
Some unit test breakage was caused by 62167ebcb which changed
the code to return 0 instead of null when {{ $index }} was
set as the entPhysicalIndex in the YamlDiscovery. So now we
detect if it returns some value which may be interpreted as
false, and if so we set null rather than 0.
* Added configuration options to aggregate input and output bits before making 95th percentile billing calculations
* Changed aggregate to per-bill instead of global. Added config options for making aggregate the default selected option. Refactored out mres() calls in touched files. Changed to Config::get where appropriate.
* Fixed documentation typo
* Fixed scope of aggregate default config option to be under billing
* Fixed getRates issue in Quick Graphs section of 95th percentile bill
* Added configuration options to aggregate input and output bits before making 95th percentile billing calculations
* Changed aggregate to per-bill instead of global. Added config options for making aggregate the default selected option. Refactored out mres() calls in touched files. Changed to Config::get where appropriate.
* Fixed documentation typo
* Fixed scope of aggregate default config option to be under billing
* Fixed getRates issue in Quick Graphs section of 95th percentile bill
* Fixed formatting
* Fix for RouterOS LLDP discovery
Only the first nine neighbors were correct on RouterOS - missing hexdec() led to the remaining neighbors being linked to the wrong ports. Ex. port 10 in hex was incorrectly linked to port 10 decimal when it should be 16 in decimal
* Added test data for MikroTik RouterOS CRS317 switch
* Added configuration options to aggregate input and output bits before making 95th percentile billing calculations
* Changed aggregate to per-bill instead of global. Added config options for making aggregate the default selected option. Refactored out mres() calls in touched files. Changed to Config::get where appropriate.
* Fixed documentation typo
* Fixed scope of aggregate default config option to be under billing
* fix client count polling, add ap count polling.
* Set low warning/critical thresholds for AP count sensors
* Add Aruba AP Count Warning and Critical Alerts to collection, lint alert_rules.json
* add newline at end of alert_rules.json
* add/update tests/data/arubaos*.json test data
* Support for system APP_LOCALE
* Start preferences re-write
* port 2fa form
* Working user preferences
* Language user preference
* Don't look up locale from the DB every request
* Device list working
* Deny demo user middleware
* Finish password changing
* remove used resource methods
* remove leftover use
* warn that translation is incomplete
* fix style
RunFollowUp checks if there is a custom sql query attached to
the alert and uses this before invoking GenSQL to build the query.
However, the custom query column was not included when selecting
alerts so the GenSQL function was always invoked.
This patch includes the alert_rules.query in the loadAlerts function
used by RunFollowUp.
* Fix Cisco MAC acounting discovery, polling and HTML templates.
* Remove empty code.
* Provide test data for cisco-mac-accounting module.
* Added module test dependency.
* Collect Appliance serial number from Sophos device
Add serial number read. Added on polling session instead of discovery because the S/N changes in case HA functionality is enabled, and there is a switch between active and standby.
* Update cyberoam-utm.inc.php
* Fix Siklu Version/Serial
Siklu allows for two software images. We must first determine which SW bank is "running" in order to report the correct version.
Also adding correct Serial Number detection for Siklu devices.
* Update siklu.inc.php
* Update siklu.snmprec
* Create siklu.json
* Replace Cyberoam with Sophos (icon and logo)
Cyberoam has been completely incorporated by Sophos since many years.
I'll try to replace everything related to Cyberoam, staring from logo and icon.
* Updated Sophos logo
Updated Sophos logo
* Added Sophos logo
Added Sophos logo
* Merge pull request #54 from librenms-plugins/revert-52-PluginNamespaceCorrection
Revert "Adding namespace LibreNMS\Plugins;"
Fix plugins menu
* Only use scrollable where needed
* New OS: Aruba Instant
* New OS: Aruba Instant
* recreate test data
* remove aruba_instant test data
* remove empty file includes/definitions/discovery/aruba-instant.yaml
* fix state sensor discovery
* remove minor changes to includes/polling/functions.inc.phpwq
* move mac helper functions to Rewrite class
* simplify snmpwalk_group usage, general code cleanup
* fixes
* fixes
* fixes
* fixes
* fixes
* fixes
* recreate test data for 105 variant
* Add Client sensors for 8.4.0.0+
* begin stream-lining discovery and polling. separating discovery functions
* update test data
* update test data
* update test data
* improve mempool discovery/polling, clean up os polling, improve state discovery, improve os definition, misc fixes to wireless sensors module
* attempt to implement custom AP and client discovery and polling
* code fixes
* re-add ap count top graph
* more fixes
* more fixes
* more fixes
* more fixes
* remove some debugging, update test data
* code cleanup
* code cleanup
* address some scrutinizer warnings
* Move services graph code from device to service and remove unused code
* Add proper support for services to dashboard graph weidget
* Fix phpdoc in ServiceController still pointing to MuninPluginController
- Fixed ospf port listing, as current query only returned ospf ports for last AreaID in area foreach loop.
- Added Area ID column to Ports table.
- Removed whitespaces.
* Remove legacy index php file
* fix routing page missing data
* WIP
* fix $navbar global usage
* remove global use of $locations
* ObjectCache again...
* move vars.inc.php to init.php for legacy ajax
* navbar is more local than I thought before. Fix it.
* Fix some sensors tables escaping
* restore custom menu functionality, but with blade
and docs
* cleanup
* tidy menu @if checks
* Fix up the rest of the global variables and remove print-menubar.php
* consolidate some counting in the menu
* filter out empty custom port descr types
* Fix up custom port groups
* Fix up apps menu
* Fix services menu when all are ok
* Limit cached data to the user it is for
* Fix style
* A few clean ups
* fix pseudowire bug
* Fixes a MySQL error were the prepared statement contains too many placeholders. Modifies dbBulkInsert to run array_chunk on incoming data and inserts those smaller chunks.
* Trying to address some automatic checks about blank lines.
* Trying to make Code Climate happy with reduced cognitive complexity.
* Trying to make Code Climate happy with reduced cognitive complexity.
* Fix Avtech discovery
pre-cache stored the data incorrectly
* Fix RA-4E external sensors
sen1 had incorrect oids (duplicate of sen2)
Description oid from data doesn't match the mib, perhaps outdated MIB?
* add test data
* Updated 4E MIB
* additional sensors for timos
change to yaml discovery for sensors
remove obsolete tmnxChassisPowerSupplyTable
* inconsistent data in snmpsim
* fix snmpsim data
* fix snmpsim data
* fix snmpsim data
* Added support for Zmtel greenpacket devices (os: zmtel)
* added more sensors
* move count sensors to features
* rename MIB and move modulation scheme to state sensor
* added test data
* graph pCID
Ensures check_ds variable is always null on each run of loop that displays services graphs. Fixes services that have script (like check_dns) but don't set check_dns on their own inheriting check_dns from previous service that ran (for example check_icmp) and displaying additional bogus graphs as result.
sysName is a valid option via the WebGUI to set when SNMP is turned off. Currently you cannot set this via the API add device. This is to enable setting the sysName via the API.
* Rewrite user management.
Error management
Revert edituser legacy page
Connect user permissions button to legacy page for now.
Implement user creation
Refine form
Remove PingCheck.php accidental add :)
Fixes for redirection and deletion
More fixes: realname accidental validation setting, hide can modify for read-only auths
Use a panel to improve style
Add icon to panel-title
Not allowed to delete own user (at least via the click of a button)
Use request validation to reduce complexity of controller.
Improve protection against users doing things they should not.
Switch to horizontal form and not nearly as wide of layout :)
delete without refresh.
Fix for buttons
Include all users (not just from this auth)
Hide the auth column if there is only one auth type
Show username if real name isn't set
Don't allow creation of demo users via the webui
a fix to the lnms user:add command, it didn't set auth_id
update edituser.inc.php to current
just redirect to users page
* Remove TwoFactorTest for now
* Update edituser.inc.php
* Update .env.dusk.testing
* Enable 2fa for 2fa test...
* Security fix: unauthorized access
Affects nginx users:
Moved php files outside of public html directory (Apache was protected by .htaccess)
Affects all users:
Some files did not check for authentication and could disclose some info.
Better checks before including files from user input
* git mv html/includes/ includes/html
git mv html/pages/ includes/html/
Fixes an issue with several uptime graphs using the average value when it should be using the minimum value.
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 5926`
After you are done testing, you can remove the changes with `./scripts/github-remove`. If there are schema changes, you can ask on discord how to revert.
Fixes#9718
This PR adds POE graphs, even if not all the values that are polled on other OSes are available on this one.
DO NOT DELETE THIS TEXT
#### Please note
> Please read this information carefully. You can run `./scripts/pre-commit.php` to check your code before submitting.
- [X] Have you followed our [code guidelines?](http://docs.librenms.org/Developing/Code-Guidelines/)
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 10075`
After you are done testing, you can remove the changes with `./scripts/github-remove`. If there are schema changes, you can ask on discord how to revert.
DO NOT DELETE THIS TEXT
#### Please note
> Please read this information carefully. You can run `./scripts/pre-commit.php` to check your code before submitting.
- [X] Have you followed our [code guidelines?](http://docs.librenms.org/Developing/Code-Guidelines/)
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 5926`
After you are done testing, you can remove the changes with `./scripts/github-remove`. If there are schema changes, you can ask on discord how to revert.
DO NOT DELETE THIS TEXT
#### Please note
> Please read this information carefully. You can run `./scripts/pre-commit.php` to check your code before submitting.
- [ ] Have you followed our [code guidelines?](http://docs.librenms.org/Developing/Code-Guidelines/)
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 5926`
After you are done testing, you can remove the changes with `./scripts/github-remove`. If there are schema changes, you can ask on discord how to revert.
DO NOT DELETE THIS TEXT
#### Please note
> Please read this information carefully. You can run `./scripts/pre-commit.php` to check your code before submitting.
- [X] Have you followed our [code guidelines?](http://docs.librenms.org/Developing/Code-Guidelines/)
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 5926`
After you are done testing, you can remove the changes with `./scripts/github-remove`. If there are schema changes, you can ask on discord how to revert.
* Added support for IONODES video encoders
* fixed expected number instead of string value error when running tests
* removed extra colon
* added mibs_dir for ionodes
* removed IF-MIB from ionodes.yaml
https://community.librenms.org/t/modify-discovery-protocols-inc-php-to-fix-neighbours-problem-on-extreme-networks-exos-switch/7797
The bug is caused by SNMP polling switch-1 with ifIndex to DB (associate
ifIndex when adding switch), the port “1” is “1001”. Another switch-2
discover the switch-1 port “1” by LLDP is “1” (after LiberNMS get this
information). Two values are not equal (“1001” != “1”). If I change to
use ifName associate when adding device, because ifName is “1:1”, so it
can not equal to LLDP too (“1:1” != “1”).