Administrator Guide

6 Python Scripting for Dell Networking N-Series | Version 1.0.1
The topology includes two networks. The Out-of-Band (OOB) network is used only for management of
switches on the network, while the Data network handles production traffic such as applications and file
sharing. The examples in this guide apply to both a single N-Series switch as well as multiple, stacked N-
Series switches as shown in Figure 1. A console cable may also be used between the management station
and each switch to view the output of Python scripts.
1.1 Console output
Python scripting output is displayed from the console. Administrators can use the console cable that comes
with the Dell N-Series switch to view console output, as well as configure the switch using any of the
commands in this guide. See the User Guide for your switch for more information on how to use the console
port.
Note: See Appendix B for more information about console output.
1.2 OOB Network
Administrators can also use the OOB or management network (for example, VLAN 1) for switch configuration.
This allows the administrator to SSH or telnet into each switch from a single management station. All
commands in this guide may be entered through the OOB/management network.
1.3 SSH/Telnet
Telnet access must be allowed (default) on the switch since Python scripts use the telnetlib module to telnet
internally into the switch console (localhost). From there, the scripts initiate CLI commands for both managing
and configuring Dell N-Series switches. Where required, the example scripts in this document provide the
basic framework for a local, internal Telnet session to the switch console.
Consequently, three distinct uses of Telnet/SSH may be used when deploying and running Python scripts:
The telnetlib module mentioned above is used for internal commands.
SSH and Telnet can be used to remotely access each switch from a management station.
As with any CLI command, telnet may be embedded into a Python script for automating a process
that requires remote access to another switch.
For those new to Python scripting, it is important to differentiate these three uses, since it is easy to confuse
them when reading this guide.