Header Only - DO NOT REMOVE - Extreme Networks

How to get the possible port range on a switch within a script?


Userlevel 4
Create Date: Jun 22 2012 2:04AM

Hi!

I want to write a script for Ridgeline that enables 802.1x on all ports that have MAC authentication enabled. The problem now is that I've following x450e setups:

    24 Port 48 Port 48 + 24 Port (stacked) 48 + 48 Port (stacked)
Whats the best way to get the port range used on this stack/switch so I can execute for example:

enable netlogin ports 1:1-48, 2:1-24 dot1x

Thx for your help.

(from Robert_Penz)

1 reply

Userlevel 4
Create Date: Aug 3 2012 6:11AM

I would have a script parse through a "show config netlogin" command and grab all the ports with the "enable netlogin port mac". Once the ports are added to a list, then they can easily be added to a "enable netlogin ports dot1x" command.

(from john_padilla)

Reply