Question 1
Q1An automation engineer is developing a Junos event script to automatically disable an interface upon receiving a specific BGP notification log message. The script is written in Python and uses the jcs.invoke() function to execute the set interfaces disable command. During testing, the event policy triggers the script correctly, but the interface is not disabled. What is the most likely cause of this issue?
Show answer & explanation
Correct answer: C
Event scripts execute in an environment that does not have an open configuration session by default. To make a configuration change, the script must explicitly open a database connection (e.g., using Junos_Context['user-context']['jcs:open']), load the configuration change, and then commit it. Simply invoking a set command does not alter the persistent configuration.