napalm-automation-community / napalm-dellos10

NAPALM Driver for Dell EMC OS10 Enterprise
http://dellos10-napalm.readthedocs.io/en/latest/
Apache License 2.0
10 stars 11 forks source link

[Request] implement get_mac_address_table method #13

Closed lboue closed 6 years ago

lboue commented 6 years ago

Hello,

Could you please implement the _get_mac_addresstable method? It is a basic feature that works on every supported driver:

NAPALM doc

Here is what you can get from the _NAPALM docs:_ about the get_mac_address_table method.

Returns a lists of dictionaries. Each dictionary represents an entry in the MAC Address Table, having the following keys:

XML API test from CLI:

Switch# show mac address-table  | display-xml
<?xml version="1.0" encoding="UTF-8"?>
<rpc-reply>
  <bulk>
    <data>
      <fwd-table>
        <mac-addr>**:**:**:**:**:**</mac-addr>
        <vlan>vla**</vlan>
        <entry-type>dynamic</entry-type>
        <if-name>port-channel**</if-name>
      </fwd-table>
      <fwd-table>
        <mac-addr>**:**:**:**:**:**</mac-addr>
        <vlan>vla**</vlan>
        <entry-type>dynamic</entry-type>
        <if-name>port-channel**</if-name>
      </fwd-table>
      <fwd-table>
        <mac-addr>**:**:**:**:**:**</mac-addr>
        <vlan>vla**</vlan>
        <entry-type>dynamic</entry-type>
        <if-name>port-channel**</if-name>
      </fwd-table>
    <last-keys>
      <entry-type>static</entry-type>
      <mac-addr>**:**:**:**:fc:**</mac-addr>
      <vlan>vlan****</vlan>
    </last-keys>
  </bulk>
</rpc-reply>

Regards, Ludovic

skg-net commented 6 years ago

https://github.com/napalm-automation-community/napalm-dellos10/pull/14 @lboue, please verify

lboue commented 6 years ago

Thanks, I will test 1.0.6 version ASAP.