HP Model 755/125cL System Configuration Repository User's Reference: HP-UX/HP - Page 27

Applying a Filter, Definition, filterName fileName, fileName.

Page 27 highlights

SCR Overview Using Filters Applying a Filter To filter the report so this component information will not appear, perform the following steps: 1. Use scrfilter to create your own view filter named "NoSoftware": # scrfilter -c Template NoSoftware This command, makes a copy of the standard filter, Template, and names it NoSoftware. Template is one of the standard filters described under the next heading. 2. Use scrfilter to set the filter extension flag to keep the component's attributes out of the report. # scrfilter -s NoSoftware "HP-UX Installed Software Definition" off The -s option sets the filter for the component to off, as specified after the component name. 3. Use the NoSoftware filter with the scrviewer command, as shown below: # scrviewer -f NoSoftware elsa:199904181305 The -f option tells scrviewer to use the filter that follows it. The HP-UX Installed Software component is excluded from the report. You will see none of the information shown in the example. Suppose you only wanted to filter out a group from the HP-UX Installed Software Definition component and not the entire component. You could filter the Subproducts group from the report with the following command: # scrfilter -p NoSoftware "HP-UX Installed Software Definition" \ "Subproducts" off Since the example showed subproducts information, you would see none of the information shown above. You would, however, see a report about bundles and products and all the other information associated with the HP-UX Installed Software Definition component. Editing a Filter Definition You can modify a filter by sending the definition to a file, editing the file and then loading the modified filter definition. This method is recommended for changing more than one value. See "scrfilter (1M)" on page 53 for details. 1. Dump a filter definition to a file by executing: # scrfilter -o filterName fileName 2. Edit the filter definition now contained in fileName. 3. Input the modified filter definition by executing: # scrfilter -i fileName Chapter 2 27

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84

Chapter 2
27
SCR Overview
Using Filters
Applying a Filter
To filter the report so this component information will not appear,
perform the following steps:
1. Use
scrfilter
to create your own view filter named “NoSoftware”:
# scrfilter –c Template NoSoftware
This command, makes a copy of the standard filter, Template, and
names it
NoSoftware
. Template is one of the standard filters
described under the next heading.
2.
Use scrfilter to set the filter extension flag to keep the component’s
attributes out of the report.
# scrfilter –s NoSoftware ”HP-UX Installed Software Definition” off
The
-s
option sets the filter for the component to off, as specified
after the component name.
3.
Use the
NoSoftware
filter with the scrviewer command, as shown
below:
# scrviewer –f NoSoftware elsa:199904181305
The
-f
option tells scrviewer to use the filter that follows it. The
HP-UX Installed Software component is excluded from the report.
You will see none of the information shown in the example.
Suppose you only wanted to filter out a group from the HP-UX Installed
Software Definition component and not the entire component. You could
filter the Subproducts group from the report with the following
command:
# scrfilter –p NoSoftware ”HP-UX Installed Software Definition” \
“Subproducts” off
Since the example showed subproducts information, you would see
none of the information shown above. You would, however, see a report
about bundles and products and all the other information associated
with the HP-UX Installed Software Definition component.
Editing a Filter
Definition
You can modify a filter by sending the definition to a file, editing the file
and then loading the modified filter definition. This method is
recommended for changing more than one value. See “scrfilter (1M)” on
page 53 for details.
1.
Dump a filter definition to a file by executing:
# scrfilter -o
filterName fileName
2.
Edit the filter definition now contained in
fileName.
3.
Input the modified filter definition by executing:
# scrfilter -i
fileName