We couldn't retrieve the device information from Oxidized!

Hello ,

I have this problem with Oxidized on Librenms can anyone help me in this and tell me what should I do and how to debug this problem please ?

Best Regards

Hi @Ibrahim_Salah,

Are you trying to integrate with Oxidized or did you already have Oxidized working?

Did you follow the documentation?

Yes I did … Should I add Ooxidzied config file ?

or what should I add so someone can help me in that ?

Thanks

Yes, also send the configuration in LibreNMS.

Thanks

Oxidizied Config file

---
username: test
password: test
model: junos
resolve_dns: true
interval: 3600
log: ~/.config/oxidized/log
use_syslog: false
debug: false
threads: 30
timeout: 20
retries: 3
prompt: !ruby/regexp /^([\[email protected]]+[#>]\s?)$/
vars:
  enable: test
groups: {}
rest: 192.168.80.130:8888
input:
  default: ssh, telnet
  debug: false
  ssh:
    secure: false
output:
  default: git
  git:
      user: Oxidized
      email: [email protected]
      repo: "~/.config/oxidized/oxidized.git"
source:
  default: http
  debug: false
  http:
    url: http://192.168.80.131/api/v0/oxidized
    scheme: http
    file: "/home/oxidized/.config/oxidized/router.db"
    delimiter: !ruby/regexp /:/
    map:
      name: hostname
      model: os
      username: username
      password: password
    var_map:
       enable: 4
    headers:
      X-Auth-Token: 'Token'
model_map:
  Vyatta: Vyatta
  cisco: ios
  mikrotik: routeros

Librenms config file

<?php

## Have a look in misc/config_definitions.json for examples of settings you can set here. DO NOT EDIT misc/config_definitions.json!

// This is the user LibreNMS will run as
//Please ensure this user is created and has the correct permissions to your install
#$config['user'] = 'librenms';

### This should *only* be set if you want to *force* a particular hostname/port
### It will prevent the web interface being usable form any other hostname
#$config['base_url']        = "/";

### Enable this to use rrdcached. Be sure rrd_dir is within the rrdcached dir
### and that your web server has permission to talk to rrdcached.
#$config['rrdcached']    = "unix:/var/run/rrdcached.sock";

### Default community
#$config['snmp']['community'] = array('public');

### Authentication Model
#$config['auth_mechanism'] = "mysql"; # default, other options: ldap, http-auth
#$config['http_auth_guest'] = "guest"; # remember to configure this user if you use http-auth

### List of RFC1918 networks to allow scanning-based discovery
#$config['nets'][] = "10.0.0.0/8";
#$config['nets'][] = "172.16.0.0/12";
#$config['nets'][] = "192.168.0.0/16";

# Uncomment the next line to disable daily updates
#$config['update'] = 0;

# Number in days of how long to keep old rrd files. 0 disables this feature
#$config['rrd_purge'] = 0;

# Uncomment to submit callback stats via proxy
#$config['callback_proxy'] = "hostname:port";

# Set default port association mode for new devices (default: ifIndex)
#$config['default_port_association_mode'] = 'ifIndex';

# Enable the in-built billing extension
#$config['enable_billing'] = 1;

# Enable the in-built services support (Nagios plugins)
#$config['show_services'] = 1;



# Oxidized configuration

 $config['oxidized']['enabled']                  = TRUE;

 $config['oxidized']['url']                      = 'http://192.168.80.130:8888';

 $config['oxidized']['features']['versioning']   = true;

 $config['oxidized']['group_support']            = true;

 $config['oxidized']['default_group']            = 'default';

 $config['oxidized']['reload_nodes']             = true;

# Graylog Config

$config['graylog']['server']   = 'http://192.168.80.132';
$config['graylog']['port']     = 8000;
$config['graylog']['username'] = 'test';
$config['graylog']['password'] = 'test123';
$config['graylog']['version']  = '4.1.4';
$config['graylog']['timezone'] = 'Europe/Paris';


# SMokeping

$config['smokeping']['dir'] = '/var/lib/smokeping';
$config['smokeping']['pings'] = 20;
$config['smokeping']['probes'] = 2;
$config['smokeping']['integration'] = true;
$config['smokeping']['url'] = 'http://192.168.80.131/smokeping/';  // If you have a specific URL or path for smokeping


## Nagios

$config['discover_services']           = true;
$config['discover_services_templates']           = true;
$config['show_services']           = 1;
$config['nagios_plugins']   = "/usr/lib/nagios/plugins";

# Nagios Related Polling / Discovery Options

$config['service_poller_enabled']           = true;
$config['service_poller_workers']           = 16;
$config['service_poller_frequency']         = 300;
$config['service_poller_down_retry']        = 5;
$config['service_discovery_enabled']        = true;
$config['service_discovery_workers']        = 16;
$config['service_discovery_frequency']      = 3600;
$config['service_services_enabled']         = true;
$config['service_services_workers']         = 16;
$config['service_services_frequency']       = 60;

Your oxidized settings are a little different from the ones I use.

I use it this way:

groups:
  acos:
    username: oxidized
    password: oxidized
    vars:
      ssh_port: 22
      enable: oxidized
  ios:
    username: oxidized
    password: oxidized
    vars:
      ssh_port: 22
  vrp:
    username: oxidized
    password: oxidized
    vars:
      ssh_port: 2522
source:
  default: http
  debug: false
  http:
    url: https://<librenms>/api/v0/oxidized
    delimiter: !ruby/regexp /:/
    map:
      name: hostname
      model: os
      group: group
      ssh_port: ssh_port
    headers:
      X-Auth-Token: token_librenms

It looks like you haven’t defined the device mapping that the API needs to send to Oxidized.

You are using the configuration through the config.php file, I find it interesting to do this through the WebUI or through the lnms as it is in the documentation.

I use it this way:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.