manjunatha.mahalinga...@gmail.com writes:
> I'm very much new to python. 
> I'm doing the automation for networking device testing , I will be opening 
> the 4 telnet session, and doing some testing operations on each of those  
> telnet sessions and capture or log the respective output in 4 different log 
> files.

Personally, I find it a bit strange that each (telnet) session
should get its own logfile, but, if that is what you need, I would
approach it as follows:

  * define a class "TelnetSession"; create a logger in its "__init__" method;
    use this logger for all operations inside a "TelnetSession"

  * instantiate the class "TelnetSession" for each telnet session you
    want to open.
    Use those objects method to operate on the sessions.

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to