When attempting to add a new services this was showing up in the logs:
[2019-07-07 09:44:53] production.ERROR: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'servcie_disabled' in 'field list' (SQL: INSERT IGNORE INTO `services` (`device_id`,`service_ip`,`service_type`,`service_changed`,`service_desc`,`service_param`,`service_ignore`,`service_status`,`service_message`,`service_ds`,`servcie_disabled`)
No error was presented in the gui, it said the service was added but in fact it was not and when you went back to the list of all services the one you tried to add was not present.
* Added disable and ignore checkboxes to services modal
* Updated add_services function to set disabled field
* Modified check-services.php respect service_disable value
* Minor code change for consistency in new_service.inc.php
* Removed unneeded includes
* 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