Commit Graph

94 Commits

Author SHA1 Message Date
James Andrewartha
1792a9cd02 Add some previously undocumented WirelessSensors and fix units (#8296) 2018-02-25 20:27:46 -06:00
Tony Murray
11147d3bbf
Major Processors rewrite (#8066)
* Extract DiscoveryItem and move some things to better places.
Extract model class
Fix up model construction.  I have problem with construction...
Makeshift model working.  Switch constructor to factory.  discover() and create()
Support legacy discovery.
Remove uneeded custom pollers
Remove netonix custom detection as we try ucd on all os now.
Add a few yaml procs.  Fix a couple things.
More processor discovery conversions
Move Calix e7 to standard hrProcessorLoad, but it doesn't fully implement the HR-MIB, move things around to make it work.
Add a few yaml procs.  Fix a couple things. Correct some stupid mib stuff.
Move more, drop php 5.3
Add netscaler which uses string indexes.  Port fiberhome to yaml and use skip_values
More conversions.  BroadcomProcessorUsage Trait
Serveriron and Ironware share some mibs.  Create a common abstract os for them.
Add yaml support for mib specification in each data entry
Make legacy discover_processor() set 0 for hrDeviceIndex

Untangle Dell switch OS processors

Use use shared OS for groups if they don't have a specific group.
fix silly mib mistake

Make index optional

Move HR and UCD to Traits and out of Processor.

* forgot to update the fortiswitch index

* Make sgos and avaya-ers match the old index.

* fix comware test data

* fix merge errors

* fix dsm and remove pointless empty modules

* file not found exception is in the wrong place.

* Updated processor development docs
2018-02-05 07:39:13 -06:00
Neil Lathwood
10e5873f55
small fix for test unit docs (#8122) 2018-01-21 20:23:55 +00:00
Tony Murray
494c29aefa
Split save-test-data.php into two scripts, allow mass update (#8115)
* Add mass update to save-test-data.
Fail when snmpsim doesn't start and try to give a hint.

* Split save-test-data.php into two scripts

One for updating snmprec files.
One for updating db dump files.
2018-01-20 20:22:47 -06:00
mattie47
2b1d63c0ef Update Test-Units.md (#8093)
Fixed name of save-test-data.php script.
2018-01-18 21:12:43 +00:00
FTBZ
c80f9726c8 feature: Added new EER and Water Flow Rate sensors (#8104)
* Add new EER sensor

* remove bad RRD option

* add waterflow sensor

* add test data result

* added test json data
2018-01-18 20:50:19 +00:00
Tony Murray
b2a54dae3b
Testing updates: module testing and collect only (#8063)
* Testing updates module testing and collect only

* cache clear no-longer needed.
2018-01-09 11:40:26 -06:00
Tony Murray
dea1a26ee6 docs: Emphasize snmpsim is required for most tests (#8059) 2018-01-09 16:36:39 +00:00
mattie47
d20508153c Update Initial-Detection.md (#8053)
* Update Initial-Detection.md

While trying to add support for awplus under https://github.com/librenms/librenms/pull/7670, I was advised to delete the os_defs.cache file. 

This was hugely helpful, as I wasted a number of hours trying to figure out why I couldn't get any changes to the OS configs to work.

* Small updates
2018-01-09 09:33:09 -06:00
Neil Lathwood
42e5819130 refactor: Updated discovery/poller to use numeric sysObjectID (#7922)
* refactor: Updated discovery to use a core module for sysDescr/sysObjectID use

* final update hopefully

* revert changes

* more changes + docs

* migrated poller to use numerical sysObjectID

* more updates for sysObjectID

* update any alert rules which might have enterprises. in

* moved schema file

* small updates

* updated getHostOS()

* scrut fixes

* updated sysObjectId -> sysObjectID

* updated sysObjectId -> sysObjectID

* updated remainder of sysObjectId -> sysObjectID

* another sysObjectId -> sysObjectID

* fixed secureplatform test data

* Fix tests: $device is not pulled from the database before polling
Also, update the db in the core discovery module.
2018-01-06 23:00:47 -06:00
Tony Murray
34ed39c1f9 docs: Additional testing documentation (#8001)
* Additional testing documentation

* snmpsim is required for save-test-data.php already

* Update Test-Units.md
2018-01-02 21:36:31 +00:00
Tony Murray
20865b0ca4
OS Testing update (#7971)
* OS Testing update
Option on pre-commit.php to run tests for just one OS. Reorganize tests a bit to support this.
Improved bgp-peers capture and os module capture (initial)
Better output when phpunit tests fail

* fix a couple issues.  Better output for another

* Use the correct setup function
2017-12-28 16:12:08 -06:00
Tony Murray
fff66d3c00
Feature: Generic discovery and poller tests (#7873)
* Processor Tests!

* Capture data from live devices easily.

* fix up some stuff, remove powerconnect things as they seem to be just broken.

* formatting, fix missing assignment
add netonix processor data

* fix multi-line, always add sysDescr and sysObjectID
ios cpm test file

* revert composer change and fix whitespace issues

* add help text

* missed help text

* tighter debug output

* handle empty strings properly and mibs with numbers

* use keys for sorting as intended

* fix type with empty data

* oops :)

* whitespace fix

* try installing fping

* Fix TestCase collision + cleanup

* mark TestCase as abstract
don't run two instances of snmpsim

* better database dumps, improved capture

* style fixes

* fix quotes add a few more tables

* add --prefer-new, properly merge data

* Support separate discovery and poller data. But don't waste space if they aren't needed.

* refactor to use class
collects all code in one place for reusability

* reorganize

* Print out when not saving.

* Support for running multiple (or all) modules at once.

* tidy

* Change unit test to a generic name and test all modules we have data for.

* Add documentation and a few more tidies

* whitespace fixes

* Fix tests, add a couple more modules, more docs

* More docs updates

* Fix scrutinizer issues

* add bgp-peers
2017-12-20 08:36:49 -06:00
bergroth
84fdfdf542 Junos dwdm interface sensor support (#7714)
* Junos dwdm interface sensor support  …
  four new sensors
    Chromatic Dispersion ps/nm
    Delay s (seconds)
    Q_factor (dB)
    preFEC_BER (ratio)

  reuse of
    SNR, dbm, temperature, current

* new dwdm sensors more generic, ber and quality_factor

* new sensors updated

* renamed html graphs new sensors

*  fixed ber polling

* Change to base SI Hz and s.

* update sensor divisors to bigint

* rename sql-schema/216.sql to 218.sql

* YAML junos dwmd sensor definitions, except BER

* bigint divisor fixed

* deafult 1 divisior

* small fixes including schema change for another PR

* schema fix
2017-12-12 20:27:10 -06:00
Paul Heinrichs
0dd3ec25d3 device: Update Cambium devices to the new wireless sensors (#7703)
* Inital cambium refactor

* Refactored tests

* Remove CMM from pmp group

* Add sensors / Give CMM individual OS

* Fix linting

* More Sensors / states and Revised Headers

* Added old graphs / more sensors

* Add modulation rate to sensor

* Fix Hardware detection bug

* Further hardware detection refinments

* Modify pmp hardware detection

* New Wireless Metric - SSR

* SSR Sensor Graph

* Migrate SSR to metric

* Added last metric file

* Add master check to isAp method

* Fix variables in epmp

* CMM Discovery and state addition

* Add another test for cmm
2017-12-06 21:36:01 +00:00
Neil Lathwood
5357dd9515
feature: Added support for entity values in sensors (#7805)
* Added info on using OIDs in skip_values for sensors

* added more docs + entity support

* remove whitespace
2017-12-02 22:56:57 +00:00
Neil Lathwood
d00cb228bb
doc: Updated sensor state doc (#7822) 2017-11-29 21:34:10 +00:00
Tony Murray
ce913cd8d3 docs: Improve developer intro, add learning resources (#7811) 2017-11-29 08:08:18 +00:00
Tony Murray
3bd9920e38 docs: Continue to reorganize docs (#7762)
* docs: Continue to reorganize things
Make landing pages for /Installation, /API, etc.
Split API out into multiple docs
Properly use multi-level navigation
Add lower nav buttons (tops are bug so disable for now)
Add logo for fanciness
Refine index page a bit

* Improve API TOC layout

* Couple of fixes.

* Fix API/API-Docs, assumed it was at the right url.
2017-11-19 01:19:18 +00:00
Paul Heinrichs
06510bba5e Switching Multiplier and Divisor Position - Docs (#7720)
The Constructor declares multiplier first, so just re-arranging to avoid confusion
2017-11-13 19:48:22 +00:00
Kevin Krumm
1c3f0d8345
docs: added link to Documentation (#7716)
Added Markdown Cheatsheet, helpful when creating docs.
2017-11-13 08:47:35 -06:00
Tony Murray
4dd56bc72e refactor: Wifi cleanup (#7607)
* refactor: remove duplicated data collection in old wifi module
Still a bit more work before we can fully remove it

* remove unused graphs
update overview graphs for some wireless os
2017-11-02 21:07:58 +00:00
Tony Murray
0d07f85257 feature: Allow snmpget in os discovery yaml (#7587)
* feature: Allow snmpget in os discovery yaml

Re-submit after release

* Remove extra trim in discovery and in snmp_get.
also trim() always returns a string, so is_string() check is a waste of cpu cycles.
2017-11-02 12:41:18 +00:00
Tony Murray
426916dbe4
Revert "feature: Allow snmpget in os discovery yaml (#7558)" (#7576)
This reverts commits:
193db02475
b73c4e9d6e
a93bb6635d
2017-10-29 14:04:26 -05:00
Tony Murray
193db02475 feature: Allow snmpget in os discovery yaml (#7558)
* feature: Allow snmpget in os discovery yaml
Convert all remaining os except airos.

Affected OS: asuswrt-merlin, ddnons, dsm, extrahop, huaweiups, ibmtl, pcoweb, pktj, qnap, remoteeye4, sentry3, sentry4, tomato

There should be not change in detection.

* Fix, asuswrt-merlin and tomato with snmpsim.  May not have been an issue with actual devices because of -Oa leading " was a bit odd.

* missed file
2017-10-26 20:48:33 +01:00
Tony Murray
1f7274d371 docs: document discovery and poller module enable/disable (#7505) 2017-10-21 23:51:28 +01:00
Neil Lathwood
e3c0714ede docs: Updated references for ##librenms to discord (#7523)
* docs: Updated references for ##librenms to discord

* updated channel -> server

* updated channel -> server
2017-10-20 14:22:18 -05:00
Tony Murray
48afb3258c Add nobulk documentation (#7478) 2017-10-11 20:02:18 -05:00
tomarch
c927e6d68c newdevice: Updated Zyxelnwa to add storage, mempools and wireless support
* zyxelnwa: add storage, mempools and wireless

* zyxelnwa: add storage, mempools and wireless

* Update Zyxelnwa.php

* zyxelnwa: add MIB and use snmp-get
2017-10-07 21:17:51 +01:00
Neil Lathwood
592e8aca4c newdevice: Added sensor detection for APC In Row RD devices (#7385)
* newdevice: Added sensor detection for APC In Row RD devices

* Update apc.yaml

* Update apc.yaml

* Update cooling.inc.php

* Update pressure.inc.php
2017-09-29 21:13:27 +01:00
Tony Murray
6ea6218f47 refactor: rewrite is_valid_port() (#7360)
* refactor: speed up is_valid_port()
Convert is_valid_port to Config
Several Config optimizations
Update documentation

* fix getCombined() when os key is not set, but global is.
Add more tests
2017-09-21 18:02:01 +01:00
Neil Lathwood
b19b9e90d2 Revert "refactor: rewrite is_valid_port()" (#7355)
* Revert "refactor: Added detection of vlan name changes (#7348)"

This reverts commit 4ad8faecdc.

* Revert "refactor: Rewrite is_valid_port() (#7337)"

This reverts commit 31607418e1.
2017-09-17 08:21:28 +01:00
Tony Murray
31607418e1 refactor: Rewrite is_valid_port() (#7337)
Convert is_valid_port to Config
Several Config optimizations
Update documentation
2017-09-16 10:13:03 +01:00
Tony Murray
98786c0ea7 feature: Allow ignore_mount, ignore_mount_string, ignore_mount_regex per OS (#7304)
* feature: Allow ignore_mount, ignore_mount_string, ignore_mount_regex at OS level

* Change the storage settings to override global instead of merge.
Add documentation
2017-09-13 19:43:21 +01:00
Neil Lathwood
edae33507a feature: Added script to generate config for new OS (#7161)
* feature: Added script to generate config for new OS

* scrut fixes
2017-09-04 21:38:09 +01:00
Tony Murray
7b262a6851 refactor: Improve yaml state discovery (#7221)
* feature: Improve yaml state discovery
Handle state values that are returned as strings instead of int
Synchronize state values for existing state translations so we can change them without creating a new translation and losing historical data
More extensive/verbose yaml discovery phpunit tests
dbBulkInsert, use the first entry instead of requiring the first entry to be at index 0

* Update sensor state documentation
re-order values for better readability
remove os check
Use snmpwalk_group since it is more flexible

* Add some more debug output in dynamic discovery
2017-09-03 19:58:39 +01:00
Bennett Blodinger
f37f3ddff6 docs: Swap mdx_del_ins with pymdownx.tilde
It's actively developed and in the same package as pymdownx.tasklist
2017-08-19 19:39:00 +01:00
Tony Murray
149857f246 Update Using-Git.md (#7178) 2017-08-17 12:49:44 -05:00
Neil Lathwood
1f98bf46a5 Update Using-Git.md (#7159) 2017-08-15 15:59:58 +01:00
Neil Lathwood
262a3967ec docs: Centralised the Metric storage docs (#7109) 2017-08-13 19:18:19 +01:00
Neil Lathwood
75ea45d275 changed the way snmpwalk is done for yaml sensors (#7069) 2017-07-22 15:03:11 +01:00
Neil Lathwood
d30e5660f9 feature: Added ability specify options for sensors yaml discovery (#6985)
* feature: Added ability specify options for sensors yaml discovery

* travis fix for new line + skip_values_* -> skip_value_*
2017-07-10 16:27:46 -05:00
Tony Murray
d8913baded docs: a couple of small fixes to the dynamic sensor docs (#6922) 2017-06-30 06:22:44 +01:00
Neil Lathwood
5e32474d26 feature: Added support for sensors to be discovered from yaml (#6859)
* feature: Added support for sensors to be discovered from yaml

* added discovery definitions

* Updated docs, more code updates + tests

* removed the oid_name use

* pre-set variable from scrut output

* small updates as per comments in pr

* Allow index in descr

* Added ability to skip values

* Check for numeric values

* small update of oid name
2017-06-26 23:27:57 +01:00
network-guy
c66f6c9704 docs: Update custom OS graphs doc to current standard. (#6837) 2017-06-14 20:32:56 +01:00
deepseth
986f99d0a4 Update Validating-Code.md (#6784)
Reflect the actual command that needs to be run
2017-06-06 22:49:53 +01:00
Nick Peelman
cbb67b35d6 Remove a leading space that broke some code rendering (#6632) 2017-05-11 15:42:47 +01:00
Tony Murray
e67708d1f7 fix typo (#6604) 2017-05-06 12:51:21 -05:00
Tony Murray
a5ee8a3ce5 docs: Add all current wireless types. (#6603)
* Fix missing wireless sensors docs

* WIP: moving all legacy polling to wifi module
2017-05-06 11:52:36 -05:00
Tony Murray
4dbab407bb refactor: OS discovery tests are now dynamic (#6555)
* refactor: OS discovery tests are now dynamic
All that needs to be done now is supply snmprec files with the proper name. os.snmprec or os_description.snmprec
I also tweaked the loading of yaml files to speed up the tests substantially.
Verifies all os have at least one test and all snmprec files are tested.

* fix typo
2017-05-03 15:52:53 +01:00