Configuring the COA Script Service for MX Series Routers (SRC CLI)

To configure the script service for the MX Series router:

  1. Create a script service in the services global service name hierarchy or the services scope name service name hierarchy. For example:
    [edit]user@host# edit services global service cos-service
  2. Set the type to script.
    [edit services global service cos-service]user@host# set type script
  3. (Optional) Configure other properties as needed for your service.
  4. Configure the script properties.
    1. Access the script hierarchy for the configured script service.
      [edit services global service cos-service]user@host# edit script
    2. Specify URL as the script type.
      [edit services global service cos-service script]user@host# set script-type url
    3. Specify the name of the Java class that implements the script service.
      [edit services global service cos-service script]user@host# set class-name net.juniper.smgt.scriptServices.coa.CoaService
    4. Configure the URL of the script service or the path and filename of the service.
      [edit services global service cos-service script]user@host# set file file:///opt/UMC/sae/lib/coa.jar

      If you specify a file URL, you must copy the file to the C Series Controller. If you specify an ftp or http URL, the file can reside on a centralized server. You can find the coa.jar file in the application and SDK distribution on the Juniper Networks Web site at:

      https://www.juniper.net/support/csc/swdist-erx/src.html

      in the SDK+AppSupport+Demos+Samples.tar.gz archive file with the pathname:

      AppSupport+Demos+Samples/SDK/scriptServices/coa/lib/coa.jar

  5. Verify the configuration.
    [edit services global service cos-service script]
    user@host# show
    type script;
    status active;
    available;
    script { 
      script-type url;
      class-name net.juniper.smgt.scriptServices.coa.CoaService;
      file file:///opt/UMC/sae/lib/coa.jar;
    }
    
    
  6. Configure the parameters for the script service.

    See Configuring Parameters for the Script Service for MX Series Routers (SRC CLI).

Related Documentation