Remove $config['oxidized']['features']['versioning']. I did not update the schema to remove the entry from the config table.

Update the documentation a bit.

Issue #2812
This commit is contained in:
Tony Murray 2016-02-12 10:23:49 -06:00
parent 3eddfd46bd
commit aa9d4798dc
3 changed files with 7 additions and 16 deletions

View File

@ -12,14 +12,10 @@ $config['oxidized']['enabled'] = TRUE;
$config['oxidized']['url'] = 'http://127.0.0.1:8888';
```
We also support config versioning within Oxidized, this will allow you to see the old configs stored.
```php
$config['oxidized']['features']['versioning'] = true;
```
LibreNMS supports config versioning if Oxidized does. This is known to work with the git output module.
Oxidized supports various ways to utilise credentials to login to devices, you can specify global username/password within Oxidized, Group level username/password or per device.
We currently support sending groups back to Oxidized so that you can then define group credentials within Oxidized. To enable this support please switch on 'Enable the return of groups to Oxidized':
LibreNMS currently supports sending groups back to Oxidized so that you can then define group credentials within Oxidized. To enable this support please switch on 'Enable the return of groups to Oxidized':
```php
$config['oxidized']['group_support'] = true;
@ -35,7 +31,7 @@ $config['oxidized']['default_group'] = 'default';
Oxidized has support for feeding devices into it via an API call, support for Oxidized has been added to the LibreNMS API. A sample config for Oxidized is provided below.
You will need to configure default credentials for your devices, LibreNMS doesn't provide login credentials at this time.
You will need to configure default credentials for your devices in the Oxidized config, LibreNMS doesn't provide login credentials at this time.
```bash
source:
@ -61,7 +57,7 @@ $config['oxidized']['reload_nodes'] = TRUE;
```
### Using Groups
#### Using Groups
To return a group to Oxidized you can do this by matching a regex for either hostname or location. The order is hostname is matched first, if nothing is found then location is attempted.
The first match found will be used. To match on the device hostnames that contain 'lon-sw' or if the location contains 'London' then you would place the following within config.php:
@ -80,7 +76,7 @@ groups:
password: <password>
```
### Miscellaneous
#### Miscellaneous
If you have devices which you do not wish to appear in Oxidized then you can edit those devices in Device -> Edit -> Misc and enable "Exclude from Oxidized?"

View File

@ -103,11 +103,10 @@ if (is_admin()) {
}
}
else if ($config['oxidized']['enabled'] === true && isset($config['oxidized']['url'])) {
// fetch info about the node and then a list of versions for that node
$node_info = json_decode(file_get_contents($config['oxidized']['url'].'/node/show/'.$device['hostname'].'?format=json'), true);
$config_versions = json_decode(file_get_contents($config['oxidized']['url'].'/node/version?node_full='.(!empty($node_info['group']) ? $node_info['group'].'/' : '').$device['hostname'].'&format=json'), true);
if ($config['oxidized']['features']['versioning'] === true) { // fetch a list of versions
$config_versions = json_decode(file_get_contents($config['oxidized']['url'].'/node/version?node_full='.(!empty($node_info['group']) ? $node_info['group'].'/' : '').$device['hostname'].'&format=json'), true);
}
if (is_array($config_versions)) {
$config_total = count($config_versions);
}

View File

@ -13,10 +13,6 @@ $oxidized_conf = array(
'descr' => 'URL to your Oxidized API',
'type' => 'text',
),
array('name' => 'oxidized.features.versioning',
'descr' => 'Enable config versioning access',
'type' => 'checkbox',
),
array('name' => 'oxidized.group_support',
'descr' => 'Enable the return of groups to Oxidized',
'type' => 'checkbox',