How can I hold or disconnect the telnet connection without error ? #803
-
QuestionHello guys, SituationI want to use the Nornir to reload the router, but when it be triggered the terminal will display the error messages
ActionI tried to use the Execution CodeEnvironment
Procedure
Error Messages
Thanks a lot ! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
Hi, have you tried using try/except blocks to catch the error within your task? Alternatively have a look at RetryRunner - https://nornir-salt.readthedocs.io/en/latest/Runners/RetryRunner.html - it should handle your telnet issue case if you initiate it with |
Beta Was this translation helpful? Give feedback.
-
I figure out the problem, before I executed the
|
Beta Was this translation helpful? Give feedback.
I figure out the problem, before I executed the
.send_command('y')
the telnet connection is disconnect, in my route, after enter the reload command if received the\n
then will immediately reload the system, so it triggered the error after the send the.send_command('y')