Using the remote index search
You can perform a search on remote RSE filters or folders using a preexisting index.
Before you begin
Before you perform a remote index search, you must first specify the remote location in which to generate indexes when you perform a remote index search on filters or folders, and then generate the index. Although the initial generation of these indexes might be time-consuming, the indexes will provide substantially faster search results compared to traditional search methods.
Specifying the remote location for indexes
Procedure
To specify the remote location in which to generate indexes, complete the following steps:
- Switch to the Remote System Explorer (RSE) perspective.
- In the Remote Systems view, right-click the MVS Files subsystem or the z/OS® UNIX Files subsystem that contains the filter or folder on which you want to perform a search.
- From the pop-up menu, select Properties to open the Properties dialog box.
- In the left navigation pane, click Remote Index Search to open the Remote Index Search properties page.
- In the Location field, specify an existing location on the selected remote system to generate indexes into when using the remote index search, or click Browse to browse for the location.
- Click OK. Indices are generated into this location when you perform a remote index search on filters or folders that reside on this remote system.
Generating indexes
About this task
Procedure
To generate an index, complete one of the following steps:
Results
What to do next
Performing a remote index search
Procedure
To perform a remote index search on remote filters or folders, complete the following steps:
Results
Disabling remote search
About this task
A guide to using remote index search
The remote index search provides the user with an alternate means of searching z/OS UNIX files and MVS data set members.
To use the remote index search, an index is first created for the container, and then this index is used to rapidly search for requested strings.
When deciding to use remote index search, you must consider where the index generation would best occur, how much disk space is available, how often the index needs to be generated, how many files will be indexed, and where the index files will reside.
Benefits of using remote index search
Remote index search is considerably faster than a traditional search, in particular as you increase the number of files being searched, because it does not require reading all the searched files. Rather, it uses the produced index to quickly determine matching files, line numbers and positions of search terms within the file.
Concessions of using remote index search
Unlike a traditional search, remote index search requires a certain amount of disk space to store the index files. The amount of disk space can vary greatly and is largely dependent on the number and types of files being indexed. For example, indexing a 1MB binary file will generate a much larger index than indexing a 1MB text file. Files that contain many repeated terms will generate smaller index files than those that contain largely unique terms. Also, using a compact index, instead of a full index will result in requiring less disk space. A standard index provides previews of the search results in the Remote Index Search view, while a compact index does not.
The following table provides a sample of some index sizes:
Items Indexed | Size | Size of Compact Index | Size of Standard Index |
---|---|---|---|
/usr/include/ | 12MB | 18MB | 48MB |
/samples | 1.8MB | 1.5MB | 3.9MB |
CEE.SCEEH.H(*) | 7.8MB | 5.8MB | 13.7MB |
CEE.SCEEH.SYS.H(*) | 1.7MB | 1.5MB | 3.1MB |
SYS1.MACLIB(*) | 166MB | 179MB | 251MB |
Since you are searching an index, rather than a file directly, changes that are made to the indexed files are not reflected until the next time the index is generated. This means that sometimes searches can be inaccurate if the index files have not been updated after a file has changed. Files that are frequently updated are not good candidates for remote index search because they will require frequent regeneration of the index files, negating and performance gain achieved by using the remote index search.
How, when, and where to generate indexes
- Performing a remote index search. When a remote index search is requested for files that are not in the index, an index is automatically generated for the user.
- Explicitly requesting an index from the client. Right-click on a filter, directory or MVS dataset and select .
- Running the remote index search script on the host.Note: The remote index search script can only generate indexes for z/OS UNIX locations.
For files that are not updated often or next to never, say for example, the C/C++ system header files, you might consider using the menu to generate the index. For files that are updated more often, you should consider using the command script to generate the index in a nightly job (or perhaps a job that runs more often).
Index files are generated by default in the user's ~/.eclipse/RSE/INDEX directory. If you have many users who access the same files, you should consider changing the default location for the indexes to a common directory. When doing this you should also take into account security issues, so that only users who are authorized to the files being indexed are given permission to the index location. Using a personal index can be useful for a single user if the user deals with a large number of files that are unique to them, and they have sufficient resources to generate and store the index files.
Multiple index locations can be specified for searching. This allows users to have both a centralized, and personalized index, and also allows the possibility of different index locations for different projects, etc.
Location and type of search index
You can specify the location where the index is placed and the type of index created.
- The standard index provides records of the number of results for each file and of the line number and contents for each line with a search result.
- The compact index needs about one-third of the storage of the standard index but it only provides the number of results for each file but not individual line results. These individual line results display when the editor opens the file.