[ Contents] [ Prev] [ Next] [ Index] [ Report an Error]

Installing AI-Scripts Packages

There are two ways to install AI-Scripts:

AI-Scripts System Requirements

AI-Scripts run on Juniper Networks J-series, M-series, MX-series, and T-series devices. Ensure that all devices on which you install AI-Scripts are running JUNOS Release 9.0 or later.

Downloading AI-Scripts Install Packages and Release Notes

AI-Scripts are released in AI-Scripts install packages. AI-Scripts install packages are available for download from the AIS download site. Download also the AI-Scripts Release Notes.

To download an AI-Scripts install package, follow these steps:

  1. Using a Web browser, go to the following location:
  2. Log in to the Juniper Networks authentication system using the username and password supplied by Juniper Networks. To download the software, you must have a service contract and an access account. If you do not have an access account, complete the registration form at the Juniper Networks Web site, https://www.juniper.net/registration/Register.jsp.
  3. Download the AI-Scripts install package.

    If you are installing an AI-Scripts install package manually, move the package to the /var/sw/pkg directory on the device. If you do not move the AI-Scripts install package to the device, you have to use ftp or scp in conjunction with the request system scripts add command.

    If you will use the JUNOScope software to automatically install a package to a group of devices at once, Download the AI-Scripts install package to the same server as Advanced Insight Manager (AIM).

AI-Scripts Install Package Versioning

AI-Script install packages are versioned as follows:

jais-m.nZx.x-signed.tgz

For example:

jais-1.0R1.5-signed.tgz

The AI-Script files that in the install package are compressed into a tgz tarball file.

Each AI-Script install package supports up to 3 previous years of JUNOS software releases.

The show version CLI operational command displays the version of the AI-Script install package that is installed on a device.

The JMB contains the output of the show version CLI command to indicate the version of the AI-Script install package installed on a device.

Refer to the AI-Script Release Notes for current release information.

AI-Script Install Locations on Devices

AI-Scripts are installed on a device hard disk in the following location:

/var/db/scripts/

AI-Scripts are installed on a device flash drive in the following location:

/config/scripts

Note: If you configure the load-scripts-from-flash option, the system reads event-scripts from /config/scripts/ directory. Otherwise the system reads AI-Scripts from the /var/db/scripts/ directory. The /var/run/scripts directory will always point to the right scripts directory.

Automatically Installing AI-Script Bundles

You can optionally use AIM to install AI-Script bundles (also known as AI-Script install packages) on devices as long as there is a JUNOScope software installation. AIM communicates with JUNOScope to install AI-Script bundles on JUNOS devices managed by JUNOScope. See Figure 10.

Figure 10: Automatic Installation of AI-Script Install Packages Using JUNOScope

Image g040002.gif

To configure auto installation of AI-Script bundles to devices, follow these steps:

  1. Configure the credentials used to communicate with JUNOScope, see Configuring JUNOScope Settings.
  2. Import devices that are managed by JUNOScope, see Configuring JUNOScope Settings.
  3. Configure Script Bundles, see Configuring Script Bundle Settings.
  4. Associate imported devices with a device group, see Creating Device Groups.
  5. Configure the Script Bundle of the device group and set the No-copy and Unlink installation attributes, see Creating Device Groups.
  6. Add archive locations specifying the upload command password attributes, see Configuring Archive Locations.
  7. Press the Save Changes button, AIM sends a message to JUNOScope to install the selected script bundle on the associated devices.

If you do not want to use AIM to install AI-Script bundles, you can manually configure and install AI-Script bundles to each device separately. To install AI-Script bundles manually, see Manually Configuring and Installing AI-Scripts on Devices.

Manually Configuring and Installing AI-Scripts on Devices

Within AIM, devices that are configured for AIS manually will automatically be added to the device group that is associated with the AIM archive location to which the JMB was sent. When the AIM detects a JMB for a device that is not managed by JUNOScope Script Management, it will note it.

Figure 11 shows the basic steps you must perform to manually configure and install AI-Scripts to devices.

Figure 11: Basic Steps to Manually Configure and Install AI-Scripts on Devices

Image g040005.gif

To manually configure and install AI-Scripts on Devices, follow these steps:

  1. Configure the device by following these steps:
    1. Enter the configure command or the edit command to enter configuration mode. The CLI prompt changes from user@host> to user@host# and a banner appears to indicate the hierarchy level.
    2. Enter an ais destination under group juniper-ais:
        user@host# set groups juniper-ais event-options destination juniper-junoscope {...}

      This configuration determines the AIS archive location where JMBs are deposited for a device.

    3. Configure the commit script:
        user@host# set groups juniper-ais system scripts commit file jais-activate-scripts.slax optional

      The AI-Script installer creates this script to activate AI-Scripts on the device.

    4. Configure the allow-transients option to allow transient changes:
        user@host# set groups juniper-ais system scripts commit allow-transients

      Transient changes are configuration changes made by commit scripts that do NOT appear in the committed configuration (except with a special command).

    5. Apply the juniper-ais group:
        user@host# set apply-groups juniper-ais

      This configuration applies the configuration group juniper-ais.

    6. (Optional) Configure the load-scripts-from-flash option:
        user@host# set groups juniper-ais system scripts load-scripts-from-flash

      Note: If you configure the load-scripts-from-flashoption, the system reads AI-Scripts from /config/scripts/ directory otherwise the system reads AI-Scripts from the /var/db/scripts/ directory. The /var/run/scripts directory will always point to the right scripts directory.

  2. Verify that the syntax of a configuration is correct by using the configuration mode commit check command:
  3. Commit the configuration. To save software configuration changes to the configuration database and activate the configuration on the router, use the commit configuration mode command. You can issue the commit command from any hierarchy level.
  4. View the configuration:
    groups {
        juniper-ais {
            system {
                scripts {
                    commit {
                        allow-transients;
                        file jais-activate-scripts.slax {
                            optional;
                        }
                    }
                    load-scripts-from-flash;
                }
            }
            event-options {
                destinations {
                    juniper-junoscope {
                        archive-sites {
                            "ftp://anonymous@10.7.0.124/aimdemo";
                        }
                    . . .
    
  5. If you have not moved the AI-Script to the device, do so now. See Downloading AI-Scripts Install Packages and Release Notes.
  6. Install the AI-Script package. (For more information about working with AI-Script packages, see Working With AI-Scripts.
  7. Verify that the AI-Scripts are activated:
    system {
        scripts {
            commit {
                allow-transients;
                file jais-activate-scripts.slax {
                    optional;
                }
            }
        }
    }
    event-options {
        event-script {
             file problem-event-pfecrash.slax;
             file problem-event-dcrash.slax;
             file intelligence-event-main.slax;
             file SPD_EVLIB_CREATE_FAILURE.slax;
             file SPD_DAEMONIZE_FAILED.slax;
             file RPD_TASK_FORK.slax;
             . . . }
        destinations {
            juniper-junoscope {
                archive-sites {
                    "ftp://anonymous@10.7.0.124/aimdemo";
                }
            }
        }
    }
    

Working With AI-Scripts

This section describes the basic commands you perform to install, delete, or roll back AI-Scripts.

Installing an AI-Script Package

To install an AI-Script package to a router, use the following command:

user@host> request system scripts add <package-name>

Deleting an AI-Script Package

To delete an AI-Script from a router, use the following command:

user@host> request system scripts delete

Rolling Back an AI-Script Package

After the deletion of an AI-Script jais package, you can roll back to the last installed jaispackage by using the following command:

user@host> request system scripts rollback

Not Saving Copies of AI-Scripts Package Files During Installation

To prevent the installer from saving copies of AI-Script jaispackage files during installation, use the following command:

user@host> request system scripts add no-copy <package-name>.

Note: If you use the no-copy option during the jaisinstallation, the jaispackage cannot be rolled back.

You can specify the no-copy option in AIM Device Group settings by selecting the no-copy check box.

Removing AI-Script Packages After Installation

To remove the AI-Script jaisbundle after successful installation, use the following command:

user@host> request system scripts add unlink <package-name>

You can specify the unlink option in AIM Device Group settings by selecting the unlink check box.


[ Contents] [ Prev] [ Next] [ Index] [ Report an Error]