From 0df8fe8872a5ac4eabac840edc29e63a61706d4f Mon Sep 17 00:00:00 2001 From: The Gitter Badger Date: Tue, 23 Aug 2016 11:32:54 +0000 Subject: Add Gitter badge --- README.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 90fd7f8..f1ebf3c 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) +[![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) + [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) Oxidized is a network device configuration backup tool. It's a RANCID replacement! -- cgit v1.2.3 From 2da8494f90d29d2278be616b20743233c91522f8 Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Tue, 23 Aug 2016 14:35:11 +0300 Subject: rearrange badges --- README.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index f1ebf3c..9b500ba 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,4 @@ -# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) - -[![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) - -[![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) +# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) [![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) Oxidized is a network device configuration backup tool. It's a RANCID replacement! -- cgit v1.2.3 From 43272714ed4e1c353afdc633e836711da571f7aa Mon Sep 17 00:00:00 2001 From: Danilo Sousa Date: Fri, 26 Aug 2016 14:50:25 -0300 Subject: ready: cleanup exited container & better docs the first container run it's only needed for creating the config file, so we run it with `--rm` to be removed after its exit --- README.md | 56 ++++++++++++++++++++++++++++++++------------------------ 1 file changed, 32 insertions(+), 24 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 9b500ba..c7bc7d4 100644 --- a/README.md +++ b/README.md @@ -254,46 +254,54 @@ rvm use --default 2.1.2 ``` # Running with Docker -1. clone git repo: + +clone git repo: ``` - root@bla:~# git clone https://github.com/ytti/oxidized -``` -2. build container locally: +git clone https://github.com/ytti/oxidized ``` - root@bla:~# docker build -q -t oxidized/oxidized:latest oxidized/ + +build container locally: + ``` -3. create config directory in main system: +docker build -q -t oxidized/oxidized:latest oxidized/ ``` - root@bla~:# mkdir /etc/oxidized + +create config directory in main system: + ``` -4. run container the first time: +mkdir /etc/oxidized ``` - root@bla:~# docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest oxidized + +run container the first time: +_Note: this step in only needed for creating Oxidized's configuration file and can be skipped if you already have it + ``` -5. add 'router.db' to /etc/oxidized: +docker run --rm -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest oxidized ``` - root@bla:~# vim /etc/oxidized/router.db - [ ... ] - root@bla:~# + +create the `/etc/oxidized/router.db` + ``` -6. run container again: +vim /etc/oxidized/router.db ``` - root@bla:~# docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest - oxidized[1]: Oxidized starting, running as pid 1 - oxidized[1]: Loaded 1 nodes - Puma 2.13.4 starting... - * Min threads: 0, max threads: 16 - * Environment: development - * Listening on tcp://0.0.0.0:8888 - ^C - root@bla:~# +run container again: + +``` +docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest +oxidized[1]: Oxidized starting, running as pid 1 +oxidized[1]: Loaded 1 nodes +Puma 2.13.4 starting... +* Min threads: 0, max threads: 16 +* Environment: development +* Listening on tcp://0.0.0.0:8888 ``` If you want to have the config automatically reloaded (e.g. when using a http source that changes) + ``` - root@bla:~# docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -e CONFIG_RELOAD_INTERVAL=3600 -t oxidized/oxidized:latest +docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -e CONFIG_RELOAD_INTERVAL=3600 -t oxidized/oxidized:latest ``` ## Cookbook -- cgit v1.2.3 From 1b82a94e7372fdf6186662b7c84d4c6e715a88a3 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 28 Aug 2016 11:25:32 -0500 Subject: Update README.md --- README.md | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index c7bc7d4..c61766c 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Output: File](#output-file) * [Output types](#output-types) * [Advanced Configuration](#advanced-configuration) + * [Advanced Group Configuration](#advanced-group-configuration) 7. [Ruby API](#ruby-api) * [Input](#input) * [Output](#output) @@ -580,7 +581,7 @@ rest: 10.0.0.1:8000/oxidized ### Advanced Configuration -Below is an advanced example configuration. You will be able to (optinally) override options per device. The router.db format used is ```hostname:model:username:password:enable_password```. Hostname and model will be the only required options, all others override the global configuration sections. +Below is an advanced example configuration. You will be able to (optionally) override options per device. The router.db format used is ```hostname:model:username:password:enable_password```. Hostname and model will be the only required options, all others override the global configuration sections. ``` --- @@ -619,12 +620,35 @@ source: name: 0 model: 1 username: 2 - password: 3 + passsword: 3 vars_map: enable: 4 model_map: cisco: ios juniper: junos + +``` + +### Advanced Group Configuration + +For group specific credentials + +``` +groups: + mikrotik: + username: admin + password: blank + ubiquiti: + username: ubnt + password: ubnt + +``` +and add group mapping +``` +map: + model: 0 + name: 1 + group: 2 ``` # Hooks -- cgit v1.2.3 From 0d4922fc25dd821981b0f2ccd0301c2f3bb5b1b6 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 28 Aug 2016 11:26:03 -0500 Subject: Update README.md --- README.md | 1 - 1 file changed, 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index c61766c..3d818da 100644 --- a/README.md +++ b/README.md @@ -641,7 +641,6 @@ groups: ubiquiti: username: ubnt password: ubnt - ``` and add group mapping ``` -- cgit v1.2.3 From fa8e95e441a8e2636261642f25caa37f578ce8c4 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 28 Aug 2016 11:27:30 -0500 Subject: Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 3d818da..3c8043f 100644 --- a/README.md +++ b/README.md @@ -620,7 +620,7 @@ source: name: 0 model: 1 username: 2 - passsword: 3 + password: 3 vars_map: enable: 4 model_map: -- cgit v1.2.3 From c12667b99594ef234f0ea181a0b38dcf03a3af43 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Tue, 30 Aug 2016 17:54:00 -0500 Subject: Update README.MD --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 3c8043f..0a46d73 100644 --- a/README.md +++ b/README.md @@ -50,6 +50,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * AOS7 * ISAM * Wireless + * Alvarion + * BreezeACCESS * Arista * EOS * Arris @@ -747,7 +749,7 @@ The following objects exist in Oxidized. ## Input * gets config from nodes * must implement 'connect', 'get', 'cmd' - * 'ssh' and 'telnet' implemented + * 'ssh', 'telnet, sqlite, ftp, and tftp' implemented ## Output * stores config -- cgit v1.2.3 From 990aa6036c427a5cf56da5a7c007bcd6a1938a0a Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Tue, 30 Aug 2016 17:54:49 -0500 Subject: Update README.MD Fix mistake on input --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 0a46d73..4534727 100644 --- a/README.md +++ b/README.md @@ -749,7 +749,7 @@ The following objects exist in Oxidized. ## Input * gets config from nodes * must implement 'connect', 'get', 'cmd' - * 'ssh', 'telnet, sqlite, ftp, and tftp' implemented + * 'ssh', 'telnet, ftp, and tftp' implemented ## Output * stores config -- cgit v1.2.3 From 3910efc7f07719dc22b5f996f3ffb3a0914aeced Mon Sep 17 00:00:00 2001 From: Schylar Utley Date: Sun, 4 Sep 2016 11:27:10 -0700 Subject: Update ruby support in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 4534727..342b518 100644 --- a/README.md +++ b/README.md @@ -150,7 +150,7 @@ gem install oxidized-script oxidized-web # if you don't install oxidized-web, ma ``` ## CentOS, Oracle Linux, Red Hat Linux -On CentOS 6 / RHEL 6, install Ruby 1.9.3 or greater (for Ruby 2.1.2 installation instructions see "Installing Ruby 2.1.2 using RVM"), then install Oxidized dependencies +On CentOS 6 / RHEL 6, install Ruby greater than 1.9.3 (for Ruby 2.1.2 installation instructions see "Installing Ruby 2.1.2 using RVM"), then install Oxidized dependencies ```shell yum install cmake sqlite-devel openssl-devel libssh2-devel ``` -- cgit v1.2.3 From 52c8427e532be178d106d015b764213b1d345d10 Mon Sep 17 00:00:00 2001 From: Schylar Utley Date: Sun, 4 Sep 2016 13:52:34 -0700 Subject: Update README.md --- README.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 342b518..03583e5 100644 --- a/README.md +++ b/README.md @@ -397,6 +397,31 @@ vars_map: ssh_proxy: 3 ... ``` +### Source: SQL->MYSQL + +One row per device, filtered by hostname +require 'mysql' +sudo apt-get install libmysqlclient-dev + +``` +source: + default: sql + sql: + adapter: mysql + database: oxidized + table: nodes + username: root #Make sure the user has permissions to login + password: rootpass + #The keys inside the map hash are static + #The values correspond to your fields in the DB + map: + name: ip #<-- IP is a field + model: model + username: username + password: password + vars_map: + enable: enable +``` ### Source: SQLite -- cgit v1.2.3 From 5c16ce270b427da30e225897fcd6b4854856f1da Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 4 Sep 2016 13:55:50 -0700 Subject: Update README.md --- README.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 03583e5..10411f8 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,9 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Privileged mode](#privileged-mode) * [Disabling SSH exec channels](#disabling-ssh-exec-channels) * [Source: CSV](#source-csv) - * [Source: SQLite](#source-sqlite) + * [Source: SQL](#source-sqlite) + * [Source: SQLite](#source-sqlite) + * [Source: Mysql](#source-mysql) * [Source: HTTP](#source-http) * [Output: GIT](#output-git) * [Output: HTTP](#output-http) @@ -397,7 +399,8 @@ vars_map: ssh_proxy: 3 ... ``` -### Source: SQL->MYSQL + +### Source: MYSQL One row per device, filtered by hostname require 'mysql' -- cgit v1.2.3 From aa2d7a53eabc4d519c19fc42845643dfc4e807c1 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 4 Sep 2016 13:58:28 -0700 Subject: UPDATE README.md Add MYSQL help --- README.md | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 10411f8..f7a6372 100644 --- a/README.md +++ b/README.md @@ -399,13 +399,23 @@ vars_map: ssh_proxy: 3 ... ``` - +### Source: SQL ### Source: MYSQL One row per device, filtered by hostname + require 'mysql' + sudo apt-get install libmysqlclient-dev +Make sure the user has permissions to login + +The keys inside the map hash are static + +The values correspond to your fields in the DB + +ip, model, etc are field names in the DB + ``` source: default: sql @@ -413,12 +423,11 @@ source: adapter: mysql database: oxidized table: nodes - username: root #Make sure the user has permissions to login + username: root password: rootpass - #The keys inside the map hash are static - #The values correspond to your fields in the DB + map: - name: ip #<-- IP is a field + name: ip model: model username: username password: password -- cgit v1.2.3 From 450568ae6cd57702a0afd13657cfc356a9414542 Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 4 Sep 2016 14:01:01 -0700 Subject: Update README.md --- README.md | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index f7a6372..83e8e5c 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Privileged mode](#privileged-mode) * [Disabling SSH exec channels](#disabling-ssh-exec-channels) * [Source: CSV](#source-csv) - * [Source: SQL](#source-sqlite) + * [Source: SQL](#source-sql) * [Source: SQLite](#source-sqlite) * [Source: Mysql](#source-mysql) * [Source: HTTP](#source-http) @@ -401,12 +401,7 @@ vars_map: ``` ### Source: SQL ### Source: MYSQL - -One row per device, filtered by hostname - -require 'mysql' - -sudo apt-get install libmysqlclient-dev +```sudo apt-get install libmysqlclient-dev``` Make sure the user has permissions to login @@ -425,7 +420,6 @@ source: table: nodes username: root password: rootpass - map: name: ip model: model -- cgit v1.2.3 From 617fbd2906960afa74cc9d41af3e48c2a16510ad Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 4 Sep 2016 14:02:40 -0700 Subject: Update README.md --- README.md | 90 +++++++++++++++++++++++++++++---------------------------------- 1 file changed, 42 insertions(+), 48 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 83e8e5c..0ef212d 100644 --- a/README.md +++ b/README.md @@ -400,54 +400,48 @@ vars_map: ... ``` ### Source: SQL -### Source: MYSQL -```sudo apt-get install libmysqlclient-dev``` - -Make sure the user has permissions to login - -The keys inside the map hash are static - -The values correspond to your fields in the DB - -ip, model, etc are field names in the DB - -``` -source: - default: sql - sql: - adapter: mysql - database: oxidized - table: nodes - username: root - password: rootpass - map: - name: ip - model: model - username: username - password: password - vars_map: - enable: enable -``` - -### Source: SQLite - -One row per device, filtered by hostname. - -``` -source: - default: sql - sql: - adapter: sqlite - database: "/var/lib/oxidized/devices.db" - table: devices - map: - name: fqdn - model: model - username: username - password: password - vars_map: - enable: enable -``` + ### Source: MYSQL + ```sudo apt-get install libmysqlclient-dev``` + + The values correspond to your fields in the DB such that ip, model, etc are field names in the DB + + ``` + source: + default: sql + sql: + adapter: mysql + database: oxidized + table: nodes + username: root + password: rootpass + map: + name: ip + model: model + username: username + password: password + vars_map: + enable: enable + ``` + + ### Source: SQLite + + One row per device, filtered by hostname. + + ``` + source: + default: sql + sql: + adapter: sqlite + database: "/var/lib/oxidized/devices.db" + table: devices + map: + name: fqdn + model: model + username: username + password: password + vars_map: + enable: enable + ``` ### Source: HTTP -- cgit v1.2.3 From 7a0085714fb909e27834968cb89973e9df70b06d Mon Sep 17 00:00:00 2001 From: MajesticFalcon Date: Sun, 4 Sep 2016 14:05:38 -0700 Subject: UPDATE README.md Add MYSQL docs --- README.md | 86 ++++++++++++++++++++++++++++++++------------------------------- 1 file changed, 44 insertions(+), 42 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 0ef212d..d822b21 100644 --- a/README.md +++ b/README.md @@ -400,48 +400,50 @@ vars_map: ... ``` ### Source: SQL - ### Source: MYSQL - ```sudo apt-get install libmysqlclient-dev``` - - The values correspond to your fields in the DB such that ip, model, etc are field names in the DB - - ``` - source: - default: sql - sql: - adapter: mysql - database: oxidized - table: nodes - username: root - password: rootpass - map: - name: ip - model: model - username: username - password: password - vars_map: - enable: enable - ``` - - ### Source: SQLite - - One row per device, filtered by hostname. - - ``` - source: - default: sql - sql: - adapter: sqlite - database: "/var/lib/oxidized/devices.db" - table: devices - map: - name: fqdn - model: model - username: username - password: password - vars_map: - enable: enable - ``` + Oxidized uses the `sequel` ruby gem. You can use a variety of databases that aren't explicitly listed. For more information visit https://github.com/jeremyevans/sequel Make sure you have the correct adapter! +### Source: MYSQL + +```sudo apt-get install libmysqlclient-dev``` + +The values correspond to your fields in the DB such that ip, model, etc are field names in the DB + +``` +source: + default: sql + sql: + adapter: mysql + database: oxidized + table: nodes + username: root + password: rootpass + map: + name: ip + model: model + username: username + password: password + vars_map: + enable: enable +``` + +### Source: SQLite + +One row per device, filtered by hostname. + +``` +source: + default: sql + sql: + adapter: sqlite + database: "/var/lib/oxidized/devices.db" + table: devices + map: + name: fqdn + model: model + username: username + password: password + vars_map: + enable: enable +``` ### Source: HTTP -- cgit v1.2.3 From ff35d151afa5251fc7a5a131db9bf99c23085925 Mon Sep 17 00:00:00 2001 From: Schylar Utley Date: Sun, 4 Sep 2016 16:58:12 -0700 Subject: Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index d822b21..339d9b2 100644 --- a/README.md +++ b/README.md @@ -411,7 +411,7 @@ The values correspond to your fields in the DB such that ip, model, etc are fiel source: default: sql sql: - adapter: mysql + adapter: mysql2 database: oxidized table: nodes username: root -- cgit v1.2.3 From 56bac9722fe26ce8e0af54ec52ca0b17aa7c9fa1 Mon Sep 17 00:00:00 2001 From: Schylar Utley Date: Wed, 7 Sep 2016 16:48:15 -0700 Subject: Add OS-Model mapping in README --- README.md | 102 ++++++++++++++++++++++---------------------- lib/oxidized/model/alvarion | 13 ------ 2 files changed, 52 insertions(+), 63 deletions(-) delete mode 100644 lib/oxidized/model/alvarion (limited to 'README.md') diff --git a/README.md b/README.md index 339d9b2..46d9683 100644 --- a/README.md +++ b/README.md @@ -44,101 +44,103 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Model](#model) # Supported OS types + * Vendor + * OS - model_name * A10 Networks - * ACOS + * ACOS - acos * Alcatel-Lucent - * AOS - * AOS7 - * ISAM - * Wireless + * AOS - aos + * AOS7 - aos7 + * ISAM - isam + * Wireless 0 * Alvarion - * BreezeACCESS + * BreezeACCESS - alvarion * Arista - * EOS + * EOS - eos * Arris - * C4CMTS + * C4CMTS - c4cmts * Aruba - * AOSW + * AOSW - aosw * Brocade - * FabricOS - * Ironware - * NOS (Network Operating System) - * Vyatta - * 6910 + * FabricOS - fabricos + * Ironware - ironware + * NOS (Network Operating System) - nos + * Vyatta - vyatta + * 6910 - br6910 * Check Point - * GaiaOS + * GaiaOS - gaiaos * Ciena - * SOAS + * SOAS - saos * Cisco - * AireOS - * ASA - * CatOS - * IOS - * IOSXR - * NXOS - * SMB (Nikola series) + * AireOS - aireos + * ASA - asa + * CatOS - catos + * IOS - ios + * IOSXR - iosxr + * NXOS - nxos + * SMB (Nikola series) * Citrix - * NetScaler (Virtual Applicance) + * NetScaler (Virtual Applicance) - netscaler * Coriant (former Tellabs) - * TMOS (8800) - * 8600 + * TMOS (8800) - tmos + * 8600 - * Cumulus * Linux * DataCom * DmSwitch 3000 * DELL - * PowerConnect - * AOSW + * PowerConnect - powerconnect + * AOSW - aosw * Ericsson/Redback - * IPOS (former SEOS) + * IPOS (former SEOS) - ipos * Extreme Networks - * XOS + * XOS - xos * WM * F5 * TMOS * Force10 - * DNOS - * FTOS + * DNOS - dnos + * FTOS - ftos * FortiGate - * FortiOS + * FortiOS - fortios * HP - * Comware (HP A-series, H3C, 3Com) - * Procurve + * Comware (HP A-series, H3C, 3Com) - comware + * Procurve - procurve * Huawei * VRP * Juniper * JunOS * ScreenOS (Netscreen) * Mellanox - * MLNX-OS + * MLNX-OS - mlnxos * Mikrotik - * RouterOS + * RouterOS - routeros * Motorola * RFS * MRV - * MasterOS + * MasterOS - masteros * Netonix - * WISP Switch (As Netonix) + * WISP Switch (As Netonix) - netonix * Nokia (formerly TiMetra, Alcatel, Alcatel-Lucent) - * SR OS (TiMOS) + * SR OS (TiMOS) - timos * Opengear - * Opengear + * Opengear - opengear * Palo Alto - * PANOS - * pfSense + * PANOS - panos + * pfSense - pfsense * Quanta - * Quanta / VxWorks 6.6 (1.1.0.8) + * Quanta / VxWorks 6.6 (1.1.0.8) - quantaos * Supermicro - * Supermicro + * Supermicro - supermicro * Ubiquiti - * AirOS - * Edgeos - * EdgeSwitch + * AirOS - airos + * Edgeos - edgeos + * EdgeSwitch - edgeswitch * Watchguard - * Fireware OS + * Fireware OS - firewareos * Zyxel - * ZyNOS + * ZyNOS - zynos # Installation diff --git a/lib/oxidized/model/alvarion b/lib/oxidized/model/alvarion deleted file mode 100644 index 3c762de..0000000 --- a/lib/oxidized/model/alvarion +++ /dev/null @@ -1,13 +0,0 @@ -class Alvarion < Oxidized::Model - - # Used in Alvarion wisp equipment - - # Run this command as an instance of Model so we can access node - pre do - cmd "#{node.auth[:password]}.cfg" - end - - - cfg :tftp {} - -end -- cgit v1.2.3 From fee27ab4f6a2593e23b764fda6363cec748f3c28 Mon Sep 17 00:00:00 2001 From: Schylar Utley Date: Wed, 7 Sep 2016 16:49:53 -0700 Subject: Add OS-Model mapping in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 46d9683..4460926 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * AOS - aos * AOS7 - aos7 * ISAM - isam - * Wireless 0 + * Wireless * Alvarion * BreezeACCESS - alvarion * Arista -- cgit v1.2.3 From a0ba8841a44d65fb22ace73ab5688d1421ca0584 Mon Sep 17 00:00:00 2001 From: Cyril LAVIER Date: Thu, 29 Sep 2016 11:50:47 +0200 Subject: Redoing the modifications on a up to date base --- README.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 4460926..926f656 100644 --- a/README.md +++ b/README.md @@ -56,6 +56,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * Wireless * Alvarion * BreezeACCESS - alvarion + * APC + * AOS - apc_aos * Arista * EOS - eos * Arris -- cgit v1.2.3 From 077798d301766ec4e24daabc393473e1fcd12f72 Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Thu, 29 Sep 2016 19:05:25 +0300 Subject: update model names --- README.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 926f656..77012a1 100644 --- a/README.md +++ b/README.md @@ -81,16 +81,16 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * IOS - ios * IOSXR - iosxr * NXOS - nxos - * SMB (Nikola series) + * SMB (Nikola series) - ciscosmb * Citrix * NetScaler (Virtual Applicance) - netscaler * Coriant (former Tellabs) - * TMOS (8800) - tmos - * 8600 - + * TMOS (8800) - corianttmos + * 8600 - coriant8600 * Cumulus - * Linux + * Linux - cumulus * DataCom - * DmSwitch 3000 + * DmSwitch 3000 - datacom * DELL * PowerConnect - powerconnect * AOSW - aosw @@ -98,9 +98,9 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * IPOS (former SEOS) - ipos * Extreme Networks * XOS - xos - * WM + * WM - mtrlrfs * F5 - * TMOS + * TMOS - tmos * Force10 * DNOS - dnos * FTOS - ftos @@ -110,16 +110,16 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * Comware (HP A-series, H3C, 3Com) - comware * Procurve - procurve * Huawei - * VRP + * VRP - vrp * Juniper - * JunOS - * ScreenOS (Netscreen) + * JunOS - junos + * ScreenOS (Netscreen) - screenos * Mellanox * MLNX-OS - mlnxos * Mikrotik * RouterOS - routeros * Motorola - * RFS + * RFS - mtrlrfs * MRV * MasterOS - masteros * Netonix -- cgit v1.2.3 From bb754581b297161cbb72a836a139be6609e747a4 Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Thu, 29 Sep 2016 21:23:30 +0300 Subject: add links to models --- README.md | 124 +++++++++++++++++++++++++++++++------------------------------- 1 file changed, 62 insertions(+), 62 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 77012a1..128af1d 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) [![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) +# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) [![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) Oxidized is a network device configuration backup tool. It's a RANCID replacement! @@ -45,104 +45,104 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen # Supported OS types * Vendor - * OS - model_name + * OS model * A10 Networks - * ACOS - acos + * [ACOS](lib/oxidized/model/acos.rb) * Alcatel-Lucent - * AOS - aos - * AOS7 - aos7 - * ISAM - isam + * [AOS](lib/oxidized/model/aos.rb) + * [AOS7](lib/oxidized/model/aos7.rb) + * [ISAM](lib/oxidized/model/isam.rb) * Wireless * Alvarion - * BreezeACCESS - alvarion + * [BreezeACCESS](lib/oxidized/model/alvarion.rb) * APC - * AOS - apc_aos + * [AOS](lib/oxidized/model/apc_aos.rb) * Arista - * EOS - eos + * [EOS](lib/oxidized/model/eos.rb) * Arris - * C4CMTS - c4cmts + * [C4CMTS](lib/oxidized/model/c4cmts.rb) * Aruba - * AOSW - aosw + * [AOSW](lib/oxidized/model/aosw.rb) * Brocade - * FabricOS - fabricos - * Ironware - ironware - * NOS (Network Operating System) - nos - * Vyatta - vyatta - * 6910 - br6910 + * [FabricOS](lib/oxidized/model/fabricos.rb) + * [Ironware](lib/oxidized/model/ironware.rb) + * [NOS (Network Operating System)](lib/oxidized/model/nos.rb) + * [Vyatta](lib/oxidized/model/vyatta.rb) + * [6910](lib/oxidized/model/br6910.rb) * Check Point - * GaiaOS - gaiaos + * [GaiaOS](lib/oxidized/model/gaiaos.rb) * Ciena - * SOAS - saos + * [SOAS](lib/oxidized/model/saos.rb) * Cisco - * AireOS - aireos - * ASA - asa - * CatOS - catos - * IOS - ios - * IOSXR - iosxr - * NXOS - nxos - * SMB (Nikola series) - ciscosmb + * [AireOS](lib/oxidized/model/aireos.rb) + * [ASA](lib/oxidized/model/asa.rb) + * [CatOS](lib/oxidized/model/catos.rb) + * [IOS](lib/oxidized/model/ios.rb) + * [IOSXR](lib/oxidized/model/iosxr.rb) + * [NXOS](lib/oxidized/model/nxos.rb) + * [SMB (Nikola series)](lib/oxidized/model/ciscosmb.rb) * Citrix - * NetScaler (Virtual Applicance) - netscaler + * [NetScaler (Virtual Applicance)](lib/oxidized/model/netscaler.rb) * Coriant (former Tellabs) - * TMOS (8800) - corianttmos - * 8600 - coriant8600 + * [TMOS (8800)](lib/oxidized/model/corianttmos.rb) + * [8600](lib/oxidized/model/coriant8600.rb) * Cumulus - * Linux - cumulus + * [Linux](lib/oxidized/model/cumulus.rb) * DataCom - * DmSwitch 3000 - datacom + * [DmSwitch 3000](lib/oxidized/model/datacom.rb) * DELL - * PowerConnect - powerconnect - * AOSW - aosw + * [PowerConnect](lib/oxidized/model/powerconnect.rb) + * [AOSW](lib/oxidized/model/aosw.rb) * Ericsson/Redback - * IPOS (former SEOS) - ipos + * [IPOS (former SEOS)](lib/oxidized/model/ipos.rb) * Extreme Networks - * XOS - xos - * WM - mtrlrfs + * [XOS](lib/oxidized/model/xos.rb) + * [WM](lib/oxidized/model/mtrlrfs.rb) * F5 - * TMOS - tmos + * [TMOS](lib/oxidized/model/tmos.rb) * Force10 - * DNOS - dnos - * FTOS - ftos + * [DNOS](lib/oxidized/model/dnos.rb) + * [FTOS](lib/oxidized/model/ftos.rb) * FortiGate - * FortiOS - fortios + * [FortiOS](lib/oxidized/model/fortios.rb) * HP * Comware (HP A-series, H3C, 3Com) - comware - * Procurve - procurve + * [Procurve](lib/oxidized/model/procurve.rb) * Huawei - * VRP - vrp + * [VRP](lib/oxidized/model/vrp.rb) * Juniper - * JunOS - junos - * ScreenOS (Netscreen) - screenos + * [JunOS](lib/oxidized/model/junos.rb) + * [ScreenOS (Netscreen)](lib/oxidized/model/screenos.rb) * Mellanox * MLNX-OS - mlnxos * Mikrotik - * RouterOS - routeros + * [RouterOS](lib/oxidized/model/routeros.rb) * Motorola - * RFS - mtrlrfs + * [RFS](lib/oxidized/model/mtrlrfs.rb) * MRV - * MasterOS - masteros + * [MasterOS](lib/oxidized/model/masteros.rb) * Netonix - * WISP Switch (As Netonix) - netonix + * [WISP Switch (As Netonix)](lib/oxidized/model/netonix.rb) * Nokia (formerly TiMetra, Alcatel, Alcatel-Lucent) - * SR OS (TiMOS) - timos + * [SR OS (TiMOS)](lib/oxidized/model/timos.rb) * Opengear - * Opengear - opengear + * [Opengear](lib/oxidized/model/opengear.rb) * Palo Alto - * PANOS - panos - * pfSense - pfsense + * [PANOS](lib/oxidized/model/panos.rb) + * [pfSense](lib/oxidized/model/pfsense.rb) * Quanta - * Quanta / VxWorks 6.6 (1.1.0.8) - quantaos + * [Quanta / VxWorks 6.6 (1.1.0.8)](lib/oxidized/model/quantaos.rb) * Supermicro - * Supermicro - supermicro + * [Supermicro](lib/oxidized/model/supermicro.rb) * Ubiquiti - * AirOS - airos - * Edgeos - edgeos - * EdgeSwitch - edgeswitch + * [AirOS](lib/oxidized/model/airos.rb) + * [Edgeos](lib/oxidized/model/edgeos.rb) + * [EdgeSwitch](lib/oxidized/model/edgeswitch.rb) * Watchguard - * Fireware OS - firewareos + * [Fireware OS](lib/oxidized/model/firewareos.rb) * Zyxel - * ZyNOS - zynos + * [ZyNOS](lib/oxidized/model/zynos.rb) # Installation @@ -349,10 +349,10 @@ Device models can contain substitution filters to remove potentially sensitive d As a partial example from ios.rb: -``` +``` cmd :secret do |cfg| cfg.gsub! /^(snmp-server community).*/, '\\1 ' - (...) + (...) cfg end ``` @@ -418,10 +418,10 @@ source: adapter: mysql2 database: oxidized table: nodes - username: root + username: root password: rootpass map: - name: ip + name: ip model: model username: username password: password -- cgit v1.2.3 From 63bd57f7f5df792fb6ff2e0b6cbcfcd4375c0f9b Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Thu, 29 Sep 2016 21:25:38 +0300 Subject: add comware link name contained -, which my replace regexp didn't allow, thus didn't generate link for that model --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 128af1d..854c0a5 100644 --- a/README.md +++ b/README.md @@ -107,7 +107,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * FortiGate * [FortiOS](lib/oxidized/model/fortios.rb) * HP - * Comware (HP A-series, H3C, 3Com) - comware + * [Comware (HP A-series, H3C, 3Com)](lib/oxidized/model/comware.rb) * [Procurve](lib/oxidized/model/procurve.rb) * Huawei * [VRP](lib/oxidized/model/vrp.rb) -- cgit v1.2.3 From dbc55487a6839b71899acd7cac65a3a04770ee5f Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Thu, 29 Sep 2016 21:26:52 +0300 Subject: regexp missed this model --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 854c0a5..166cce8 100644 --- a/README.md +++ b/README.md @@ -115,7 +115,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [JunOS](lib/oxidized/model/junos.rb) * [ScreenOS (Netscreen)](lib/oxidized/model/screenos.rb) * Mellanox - * MLNX-OS - mlnxos + * [MLNX-OS](lib/oxidized/model/mlnxos.rb) * Mikrotik * [RouterOS](lib/oxidized/model/routeros.rb) * Motorola -- cgit v1.2.3 From cdcc4de05c33504c1542d78363fb75b78d3fc45d Mon Sep 17 00:00:00 2001 From: frederic-loui Date: Wed, 12 Oct 2016 16:45:16 +0200 Subject: Update README.md Added correction related to issue #445 and docker-compose file example --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 166cce8..c348573 100644 --- a/README.md +++ b/README.md @@ -288,6 +288,24 @@ _Note: this step in only needed for creating Oxidized's configuration file and c ``` docker run --rm -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest oxidized ``` +If the RESTful API and Web Interface are enabled, on the docker host running the container +edit /etc/oxidized/config and modify 'rest: 127.0.0.1:8888' by 'rest: 0.0.0.0:8888' +this will bind port 8888 to all interfaces then expose port out. (Issue #445) + +You can also use docker-compose to launch oxidized container: +``` +# docker-compose.yml +# docker-compose file example for oxidized that will start along with docker daemon +oxidized: + restart: always + image: oxidized/oxidized:latest + ports: + - 8888:8888/tcp + environment: + CONFIG_RELOAD_INTERVAL: 600 + volumes: + - /etc/oxidized:/root/.config/oxidized +``` create the `/etc/oxidized/router.db` -- cgit v1.2.3 From ee48fd9512df8ec839119317f58319a18a398c22 Mon Sep 17 00:00:00 2001 From: Christoffer Stokbaek Date: Tue, 25 Oct 2016 11:03:10 +0200 Subject: Added support for fujitsu blade switches --- README.md | 2 ++ lib/oxidized/model/fujitsupy.rb | 42 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 lib/oxidized/model/fujitsupy.rb (limited to 'README.md') diff --git a/README.md b/README.md index c348573..1e276e3 100644 --- a/README.md +++ b/README.md @@ -106,6 +106,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [FTOS](lib/oxidized/model/ftos.rb) * FortiGate * [FortiOS](lib/oxidized/model/fortios.rb) + * Fujitsu + * [PRIMERGY Blade switch 1/10Gbe](lib/oxidized/model/fujitsupy.rb) * HP * [Comware (HP A-series, H3C, 3Com)](lib/oxidized/model/comware.rb) * [Procurve](lib/oxidized/model/procurve.rb) diff --git a/lib/oxidized/model/fujitsupy.rb b/lib/oxidized/model/fujitsupy.rb new file mode 100644 index 0000000..20a78dd --- /dev/null +++ b/lib/oxidized/model/fujitsupy.rb @@ -0,0 +1,42 @@ +class FujitsuPY < Oxidized::Model + + prompt /^(\([\w.-]*\)\s#|^\S+\#\s)$/ + comment '! ' + + cmd :all do |cfg| + cfg.each_line.to_a[1..-2].join + end + +# 1Gbe switch + cmd 'show version' do |cfg| + cfg.gsub! /^( : 2 : format error)$/, '' + comment cfg + end + +# 10Gbe switch + cmd 'show system information' do |cfg| + cfg.gsub! /^Current-time : [\w\s:]*$/, '' + cfg.gsub! /^(\s{33}\^)$/, '' + cfg.gsub! /^(\% Invalid input detected at '\^' marker.)$/, '' + comment cfg + end + + cmd 'show running-config' do |cfg| + cfg + end + + cfg :telnet do + username /^Username:/ + password /^Password:/ + end + + cfg :telnet, :ssh do + post_login 'no pager' + post_login 'terminal pager disable' + pre_logout do + send "quit\n" + send "n\n" + end + end + +end -- cgit v1.2.3 From f8f5d43f732b7567dc26a2c12cc13f44a604458c Mon Sep 17 00:00:00 2001 From: Eric Lindsjö Date: Wed, 26 Oct 2016 09:01:37 +0200 Subject: Added Support for MRV FiberDriver Linux based management module --- README.md | 1 + lib/oxidized/model/fiberdriver.rb | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 lib/oxidized/model/fiberdriver.rb (limited to 'README.md') diff --git a/README.md b/README.md index 1e276e3..a7e9af7 100644 --- a/README.md +++ b/README.md @@ -124,6 +124,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [RFS](lib/oxidized/model/mtrlrfs.rb) * MRV * [MasterOS](lib/oxidized/model/masteros.rb) + * [FiberDriver](lib/oxidized/model/fiberdriver.rb) * Netonix * [WISP Switch (As Netonix)](lib/oxidized/model/netonix.rb) * Nokia (formerly TiMetra, Alcatel, Alcatel-Lucent) diff --git a/lib/oxidized/model/fiberdriver.rb b/lib/oxidized/model/fiberdriver.rb new file mode 100644 index 0000000..8f8eb07 --- /dev/null +++ b/lib/oxidized/model/fiberdriver.rb @@ -0,0 +1,21 @@ +class FiberDriver < Oxidized::Model + prompt /\w+#/ + comment "! " + + cmd :all do |cfg| + cfg.each_line.to_a[1..-2].join + end + cmd 'show inventory' do |cfg| + comment cfg + end + + cmd "show running-config" do |cfg| + cfg.each_line.to_a[3..-1].join + end + + cfg :ssh do + post_login 'terminal length 0' + post_login 'terminal width 512' + pre_logout 'exit' + end +end -- cgit v1.2.3 From c41b79b5a51b1b8d913c3f9c7478718bf3183a4b Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Thu, 27 Oct 2016 14:28:00 +0200 Subject: add support for the HPE BladeSystem --- README.md | 1 + lib/oxidized/model/hpebladesystem.rb | 83 ++++++++++++++++++++++++++++++++++++ 2 files changed, 84 insertions(+) create mode 100644 lib/oxidized/model/hpebladesystem.rb (limited to 'README.md') diff --git a/README.md b/README.md index a7e9af7..091bd46 100644 --- a/README.md +++ b/README.md @@ -111,6 +111,7 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * HP * [Comware (HP A-series, H3C, 3Com)](lib/oxidized/model/comware.rb) * [Procurve](lib/oxidized/model/procurve.rb) + * [BladeSystem (Onboard Administrator)](lib/oxidized/model/hpebladesystem.rb) * Huawei * [VRP](lib/oxidized/model/vrp.rb) * Juniper diff --git a/lib/oxidized/model/hpebladesystem.rb b/lib/oxidized/model/hpebladesystem.rb new file mode 100644 index 0000000..5e34de8 --- /dev/null +++ b/lib/oxidized/model/hpebladesystem.rb @@ -0,0 +1,83 @@ +class HPEBladeSystem < Oxidized::Model + # HPE Onboard Administrator + + prompt /.*> / + comment '# ' + + expect /^\s*--More--\s+.*$/ do |data, re| + send ' ' + data.sub re, '' + end + + cmd :all do |cfg| + cfg = cfg.delete("\r").each_line.to_a[0..-1].map{|line|line.rstrip}.join("\n") + "\n" + cfg.each_line.to_a[0..-2].join + end + + cmd :secret do |cfg| + cfg.gsub! /^(SET SNMP COMMUNITY (READ|WRITE)).*/, '\\1 ' + cfg + end + + cmd 'show oa info' do |cfg| + comment cfg + end + + cmd 'show oa network' do |cfg| + comment cfg + end + + cmd 'show oa certificate' do |cfg| + comment cfg + end + + cmd 'show sshfingerprint' do |cfg| + comment cfg + end + + cmd 'show fru' do |cfg| + comment cfg + end + + cmd 'show network' do |cfg| + comment cfg + end + + cmd 'show vlan' do |cfg| + comment cfg + end + + cmd 'show rack name' do |cfg| + comment cfg + end + + cmd 'show server list' do |cfg| + comment cfg + end + + cmd 'show server names' do |cfg| + comment cfg + end + + cmd 'show server port map all' do |cfg| + comment cfg + end + + cmd 'show server info all' do |cfg| + comment cfg + end + + cmd 'show config' do |cfg| + cfg.gsub! /^#(Generated on:) .*$/, '\\1 ' + cfg.gsub /^\s+/, '' + end + + cfg :telnet do + username /\slogin:/ + password /^Password: / + end + + cfg :telnet, :ssh do + pre_logout "exit" + end +end -- cgit v1.2.3 From 2191cb239f14024327f29040e3548bf3b346f6cb Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Mon, 31 Oct 2016 18:33:11 +0100 Subject: add to README --- README.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 091bd46..b9b97d7 100644 --- a/README.md +++ b/README.md @@ -134,6 +134,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Opengear](lib/oxidized/model/opengear.rb) * Palo Alto * [PANOS](lib/oxidized/model/panos.rb) + * PLANET + * [SGS](lib/oxidized/model/planetsgs.rb) * [pfSense](lib/oxidized/model/pfsense.rb) * Quanta * [Quanta / VxWorks 6.6 (1.1.0.8)](lib/oxidized/model/quantaos.rb) -- cgit v1.2.3 From 60ee472e2cb62b6bae6ab118ec102108b81148b7 Mon Sep 17 00:00:00 2001 From: Robert Drake Date: Fri, 4 Nov 2016 14:17:52 -0400 Subject: Added support for Trango/Trangolink-45 I only have the Trangolink-45 so I'm not sure which other radios this might support. --- README.md | 2 ++ lib/oxidized/model/trango.rb | 62 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 64 insertions(+) create mode 100644 lib/oxidized/model/trango.rb (limited to 'README.md') diff --git a/README.md b/README.md index b9b97d7..9d73ce8 100644 --- a/README.md +++ b/README.md @@ -141,6 +141,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [Quanta / VxWorks 6.6 (1.1.0.8)](lib/oxidized/model/quantaos.rb) * Supermicro * [Supermicro](lib/oxidized/model/supermicro.rb) + * Trango Systems + * [Trango](lib/oxidized/model/trango.rb) * Ubiquiti * [AirOS](lib/oxidized/model/airos.rb) * [Edgeos](lib/oxidized/model/edgeos.rb) diff --git a/lib/oxidized/model/trango.rb b/lib/oxidized/model/trango.rb new file mode 100644 index 0000000..b2aa1e7 --- /dev/null +++ b/lib/oxidized/model/trango.rb @@ -0,0 +1,62 @@ +class Trango < Oxidized::Model + # take a Trangolink sysinfo output and turn it into a configuration file + + prompt /^#>\s?/ + comment '# ' + + cmd 'sysinfo' do |cfg| + out = [] + comments = [] + cfg.each_line do |line| + if line.match /\[Opmode\] (off|on) \[Default Opmode\] (off|on)/ + out << "opmode " + Regexp.last_match[1] + out << "defaultopmode " + Regexp.last_match[2] + end + if line.match /\[Tx Power\] ([\-\d]+) dBm/ + out << "power " + Regexp.last_match[1] + end + if line.match /\[Active Channel\] (\d+) (v|h)/ + out << "freq " + Regexp.last_match[1] + ' ' + Regexp.last_match[2] + end + if line.match /\[Peer ID\] ([A-F0-9]+)/ + out << "peerid " + Regexp.last_match[1] + end + if line.match /\[Unit Type\] (\S+)/ + out << "utype " + Regexp.last_match[1] + end + if line.match /\[(Hardware Version|Firmware Version|Model|S\/N)\] (\S+)/ + comments << '# ' + Regexp.last_match[1] + ': ' + Regexp.last_match[2] + end + if line.match /\[Remarks\] (\S+)/ + out << "remarks " + Regexp.last_match[1] + end + if line.match /\[RSSI LED\] (on|off)/ + out << "rssiled " + Regexp.last_match[1] + end + if line.match /\[Speed\] (\d+) Mbps/ + speed = Regexp.last_match[1] + end + if line.match /\[Tx MIR\] (\d+) Kbps/ + out << "mir ".concat(Regexp.last_match[1]) + end + if line.match /\[Auto Rate Shift\] (on|off)/ + out << "autorateshift ".concat(Regexp.last_match[1]) + if Regexp.last_match[1].eql? 'off' + out << "speed $speed" + end + end + if line.match /\[IP\] (\S+) \[Subnet Mask\] (\S+) \[Gateway\] (\S+)/ + out << "ipconfig " + Regexp.last_match[1] + ' ' + + Regexp.last_match[2] + ' ' + + Regexp.last_match[3] + end + end + comments.push(*out).join "\n" + end + + cfg :telnet do + password /Password:/ + pre_logout 'exit' + end + +end -- cgit v1.2.3 From 8862e0b303b2fdc4c50992cfbffbbccb9b88bc91 Mon Sep 17 00:00:00 2001 From: Robert Drake Date: Fri, 4 Nov 2016 14:21:09 -0400 Subject: This adds support for the Casa C1G CMTS This will probably work for the other Casa CMTS as well. --- README.md | 2 ++ lib/oxidized/model/casa.rb | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 lib/oxidized/model/casa.rb (limited to 'README.md') diff --git a/README.md b/README.md index b9b97d7..03b2d1e 100644 --- a/README.md +++ b/README.md @@ -70,6 +70,8 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen * [NOS (Network Operating System)](lib/oxidized/model/nos.rb) * [Vyatta](lib/oxidized/model/vyatta.rb) * [6910](lib/oxidized/model/br6910.rb) + * Casa + * [Casa](lib/oxidized/model/casa.rb) * Check Point * [GaiaOS](lib/oxidized/model/gaiaos.rb) * Ciena diff --git a/lib/oxidized/model/casa.rb b/lib/oxidized/model/casa.rb new file mode 100644 index 0000000..e85c904 --- /dev/null +++ b/lib/oxidized/model/casa.rb @@ -0,0 +1,46 @@ +class Casa < Oxidized::Model + # Casa Systems CMTS + + prompt /^([\w.@()-]+[#>]\s?)$/ + comment '! ' + + cmd :secret do |cfg| + cfg.gsub! /^(snmp community) \S+/, '\\1 ' + cfg.gsub! /^(snmp comm-tbl) \S+ \S+/, '\\1 ' + cfg.gsub! /^(console-password encrypted) \S+/, '\\1