Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Monitoring AI-Scripts Behavior by Using the AI-Scripts Event Simulator

    With the AI-Scripts event simulator, you can generate error messages to monitor AI-Scripts behavior.

    When the event simulator generates and enters an error message in the system logs of the device, the AI-Script pertaining to the event that caused the error message is triggered to generate a JMB for the event.

    The event simulator is packaged with an AI-Scripts bundle starting from AI-Scripts Release 3.2R1.

    To use the AI-Scripts event simulator for monitoring AI-Scripts behavior:

    1. Log in to the device running Junos OS.
    2. Verify that AI-Scripts Release 3.2R1 or later is installed on the device.

      To verify that an AI-Scripts bundle is installed on the device, see Troubleshooting AI-Scripts Installation Issues.

      If not already installed, create an event profile by using AI-Scripts Release 3.2R1 or later and install the event profile on the device. To create and install an event profile, see Adding an Event Profile to Junos Space Service Now in the Service Automation User Guide.

    3. On the device running Junos OS, run shell.
    4. Navigate to the directory where the event simulator is located:

      cd /var/db/scripts/op/.

    5. Run the event simulator:

      sh AIS_event_sim.sh

      A menu of event types is displayed, as shown in the following sample:

       AIS PROBLEM SIMULATION MENU (AI-Scripts 3.7R4/4.0R2 release)
       ======================================================
      
      1. Hardware Failure
      2. Software Failure
      3. Resource Exhaustion Failure
      4. Daemon crash [WARNING: This test could be service affecting as it kills the daemon]
      5. Unstructured Events
      6. Events that may be triggered on a Backup Routing Engine (platform dependent)
      7. Events added/modified to 3.3R1
      8. Events added/modified to 3.3R2
      9. Events added to 3.3R3
      10. Events added/modified to 3.4R1
      11. Events added to 3.5R1/3.4R2
      12. Events added to 3.6R1
      13. Events added/modified for 3.6R2/3.7R1
      14. Events added/modified for 3.7R3/4.0R1
      15. Events added/modified for 3.7R4/4.0R2
      16. Exit
      
      Please enter option [1 - 16]:
      
    6. From the menu, select an event type and enter its number at the command prompt. For example, type 3 to generate error messages for a resource exhaustion failure event on the device.

      A menu listing the events for the selected event type appears. The following menu appears when you type 3.

       RESOURCE EXHAUSTION FAILURE MENU
       ================================
      
      1. ACCT_MALLOC_FAILURE
      2. ASP_L2TP_NO_MEM
      3. AUTOCONFD_AUTH_NO_MEM
      4. CHASSISD_IPC_MSG_DROPPED
      5. L2CPD_SCHED_SLIP
      6. L2CPD_SYSTEM_CALL_FAILED
      7. RPD_ISIS_OVERLOAD
      8. RPD_OS_MEMHIGH
      9. RT_SCREEN_TCP
      10. RT_SCREEN_UDP
      11. RTPERF_CPU_THRESHOLD_EXCEEDED
      12. SNMPD_SUBAGENT_NO_RESOURCES
      13. TASK_OS_MEMHIGH
      14. VCCPD_PROTOCOL_OVERLOAD
      15. Exit
      
      Please enter option [1 - 15]: 
    7. Select an event from the menu and type its number at the command prompt.

      The event simulator enters the error message in the system logs for the event that you select from this list.

    8. Type the highest number on the menu to exit the program. For example, 15 in this case.

      The CLI prompt appears.

    9. Execute the following command to monitor the execution of the cscript process to verify that a JMB is created for the event.

      show system processes extensive | match csc

    10. Log in to the Junos Space GUI and navigate to Service Now > Service Central > Incidents.

      An incident is generated in Service Now for the event that you generated using the event simulator. The incident is usually generated in Service Now within a few minutes after the event is generated on the device.

    Modified: 2016-07-07