EasyManua.ls Logo

Cisco 11503 - CSS Content Services Switch User Manual

Cisco 11503 - CSS Content Services Switch
392 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #286 background imageLoading...
Page #286 background image
Chapter 8 Using the CSS Scripting Language
Special Variables
8-18
Cisco Content Services Switch Administration Guide
OL-5647-02
STATUS Variable
Use the STATUS variable to return the exit status of the previously executed CLI
command. In most cases, except for the grep command, an exit status of 0
indicates that a command was successful, while a non-zero value indicates that a
command failed. The CLI sets the STATUS variable automatically after each
command completes execution.
Note Using the grep command sets the STATUS variable equal to the number of lines
that satisfied the search. For details on the grep command, see “Using the grep
Command later in this chapter.
Typically, it is not necessary to examine the STATUS variable because a script
will terminate if a command does not execute properly. However, if you set the
CONTINUE_ON_ERROR variable, you can use the STATUS variable to test the
results of a command.
For example, enter:
set CONTINUE_ON_ERROR “1”
eco “Hello world”
if STATUS “NEQ” “0”
echo “Failure to execute command correctly”
endbranch
In the above example, the STATUS variable is set to a non-zero value. This value
is specific to the type of error that occurred. In this case, the script receives a
general syntax error, which informs you that the command being executed failed.
This is a typical example and one that you should watch closely when using the
CONTINUE_ON_ERROR variable. In most circumstances, you will want to
catch syntax errors as real errors.
Note When writing scripts, keep in mind that the value of the STATUS variable changes
as each command executes. If you intend to use a STATUS value later in a script,
you should save the value of the STATUS variable in another variable.

Table of Contents

Other manuals for Cisco 11503 - CSS Content Services Switch

Question and Answer IconNeed help?

Do you have a question about the Cisco 11503 - CSS Content Services Switch and is the answer not in the manual?

Cisco 11503 - CSS Content Services Switch Specifications

General IconGeneral
BrandCisco
Model11503 - CSS Content Services Switch
CategorySwitch
LanguageEnglish

Summary

CHAPTER 1 Managing the CSS Software

CSS Software Overview

Describes the CSS software files, installation methods, and version format.

Using the Running-Config and Startup-Config Files

Covers saving, copying, clearing, and showing running and startup configuration files.

CHAPTER 2 Specifying the CSS Boot Configuration

Specifying the Primary Boot Configuration

Details configuring the primary boot file, type (disk, FTP, network), and configuration path.

Specifying the Secondary Boot Configuration

Describes configuring the secondary boot file, type (disk, FTP, network), and configuration path.

Configuring a Boot Configuration Record for the Passive SCM

Covers configuring boot records for the passive SCM, including gateway, IP, boot file, and type.

Booting the CSS from a Network Drive

Details the process of network booting the CSS using a .zip file from www.cisco.com.

CHAPTER 3 Configuring User Profiles

User Profiles Overview

Explains user profiles, customizable settings like CLI prompt, expert mode, and terminal parameters.

Configuring User Terminal Parameters

Covers configuring terminal idle time, length, prompt, netmask format, and timeout.

CHAPTER 4 Using the CSS Logging Features

Logging Overview

Introduces CSS logging, log files, destinations, and default logging levels.

Configuring Logging for a Subsystem

Details how to select CSS subsystems and log activity at different logging levels.

Specifying a Log File Destination

Covers specifying destinations for log files: disk, host, or CSS active session.

CHAPTER 5 Configuring Simple Network Management Protocol (SNMP)

SNMP Overview

Provides an overview of SNMP, its standards, and the manager/agent communication model.

Management Information Base (MIB) Overview

Explains MIBs, MIB objects, the MIB tree structure, and MIB variables.

Defining the CSS as an SNMP Agent

Details the steps for configuring the CSS as an SNMP agent, including communities, traps, and contact info.

Configuring Denial of Service (DoS)

Covers configuring enterprise traps for DoS attacks and displaying/resetting DoS statistics.

CHAPTER 6 Configuring Remote Monitoring (RMON)

RMON Overview

Introduces RMON, its supported groups (Statistics, History, Alarm, Event), and MIB objects.

Configuring an RMON Event

Details how to configure RMON events, including quick start, index, attributes, and activation.

Configuring an RMON Alarm

Covers configuring RMON alarms, including sampling methods, thresholds, and events.

Configuring an RMON History

Explains how to configure RMON history for ports, including data sources, buckets, and intervals.

CHAPTER 7 Using an XML Document to Configure the CSS

Creating XML Code

Provides guidelines for developing XML code for the Content API, including tag usage and special characters.

CHAPTER 8 Using the CSS Scripting Language

Using the Command Scheduler

Details scheduling CLI commands and scripts for periodic execution.

Using Variables

Covers creating, setting, removing, and modifying variables, including types and operations.

Using Logical and Relational Operators and Branch Commands

Explains using 'if' and 'while' commands for structured script logic and operators.

Using socket Commands

Explains socket commands for ASCII/hexadecimal send/receive, connection handling, and inspection.

APPENDIX A Upgrading Your CSS Software

Configuring an FTP Server Record on the CSS

Explains how to create an FTP record file on the CSS to identify the ADI for the upgrade.

Upgrading Your CSS Software

Provides information on upgrading CSS software, including restrictions and methods.

Using the Upgrade Script

Details how to run the upgrade script automatically or interactively.

Manually Upgrading the CSS Software

Explains the CLI commands required to manually upgrade the CSS software version.

APPENDIX B Using the Offline Diagnostic Monitor Menu

Using the Boot Configuration Menu

Illustrates the boot process flowchart and describes menu options for boot configuration.

Configuring Disks in a Two-Disk CSS

Details configuring PCMCIA slots for primary/secondary boot, logging, and core dumps.

Related product manuals