Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support to Dell EMS OS6 #3169

Closed
wants to merge 11 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
## [Unreleased]

### Added
- os6: Added support to Dell EMC Networking OS6 (@anubisg1)
- model for Siklu Multihaul TG radios (@bdg-robert)


### Changed
- h3c: change prompt to expect either angle (user-view) or square (system-view) brackets (@nl987)
- xos: Hide radius and user secrets for XOS (@iriseden)
Expand Down
10 changes: 10 additions & 0 deletions docs/Model-Notes/OS6.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# OS6 Configuration

The commands Oxidized executes are:

1. terminal length 0
2. show version
3. show interfaces transceiver properties
4. show running-config

Back to [Model-Notes](README.md)
1 change: 1 addition & 0 deletions docs/Supported-OS-Types.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@
|DELL |PowerConnect |[powerconnect](/lib/oxidized/model/powerconnect.rb)
| |AOSW |[aosw](/lib/oxidized/model/aosw.rb) | |Same model as Aruba Wireless
| |DellX |[dellx](/lib/oxidized/model/dellx.rb)
| |Dell EMC Networking OS6 |[os6](/lib/oxidized/model/os6.rb) | |[Dell EMC Networking OS6](Model-Notes/OS6.md)
| |Dell EMC Networking OS10 |[os10](/lib/oxidized/model/os10.rb) | |[Dell EMC Networking OS10](Model-Notes/OS10.md)
|D-Link |D-Link |[dlink](/lib/oxidized/model/dlink.rb)
| |D-Link cisco like CLI |[dlinknextgen](/lib/oxidized/model/dlinknextgen.rb)
Expand Down
48 changes: 48 additions & 0 deletions lib/oxidized/model/os6.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
class OS6 < Oxidized::Model
using Refinements

# For switches running Dell EMC Networking OS6 #
#
# Tested with : Dell PowerSwitch N2048

comment '! '

cmd :all do |cfg|
cfg.gsub! /^% Invalid input detected at '\^' marker\.$|^\s+\^$/, ''
cfg.each_line.to_a[2..-2].join
end

cmd :secret do |cfg|
cfg.gsub! /(password )(\S+)/, '\1<secret hidden>'
cfg
end

cmd 'show version' do |cfg|
comment cfg
end

cmd 'show interfaces transceiver properties' do |cfg|
comment cfg
end

cmd 'show running-config' do |cfg|
cfg.each_line.to_a[3..-1].join
end

cfg :telnet do
username /^Login:/
password /^Password:/
end

cfg :telnet, :ssh do
if vars :enable
post_login do
send "enable\n"
cmd vars(:enable)
end
end
post_login 'terminal length 0'
pre_logout 'exit'
pre_logout 'exit'
end
end
Loading