Skip Headers
Oracle® Secure Enterprise Search Administration API Guide
11g Release 1 (

Go to Documentation Home
Go to Book List
Book List
Go to Table of Contents
Go to Feedback page
Contact Us

Go to previous page
Go to next page
PDF · Mobi · ePub

Command Interface

The searchadmin command provides a command-line interface to the Administration API. You can open an interactive session, or you can issue individual commands to the operating system.

You must supply the administrator password each time you issue the searchadmin command. You can include the password in the command or wait for the prompt to enter it.

Opening an Interactive Session

To open an interactive session, enter the searchadmin command at the operating system prompt. After providing the administrator password, you get the SES prompt. You can start entering commands to the Oracle SES Administration API. This type of connection is called session mode.

Example 1-1 shows a brief interactive session, which ends with a quit command.

Example 1-1 Issuing Commands at the SES Prompt

$ searchadmin

Search Admin Command Line - Release
Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.

SES>export index
<?xml version="1.0" encoding="UTF-8"?>
<search:config productVersion="" xmlns:search="">

Issuing Individual Commands

You can issue commands individually at the operating system prompt. You can also use this command format to create scripts and batch files, thus simplifying routine tasks. This type of connection is called single job mode.

Example 1-2 shows two commands entered at the operating system prompt. One includes the password in the command, and the other responds to the Password prompt. In a script or batch file, include the password in each command.

Example 1-2 Issuing Commands at the Operating System Prompt

$ searchadmin getAPIVersion

Search Admin Command Line - Release
Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.

$ searchadmin --PASSWORD password export index

Search Admin Command Line - Release
Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.

<?xml version="1.0" encoding="UTF-8"?>
<search:config productVersion="" xmlns:search="">

Issuing Commands to Remote Oracle SES Instances

The searchadmin command connects to the local search instance defined by Oracle home. However, you can issue commands to one or more remote Oracle SES instances by supplying the connection information in the searchadmin command.

To connect to a single remote instance, use the --CONNECTION option with an HTTP connection string, like the one shown here. You can obtain the port number from the Oracle SES properties file at ORACLE_HOME/search/webapp/config/

$ searchadmin --CONNECTION=http://myhost:7777/search/api/admin/AdminService

To connect to multiple instances, create a file with the connection information, then reference the file using the --CONNECTION_LIST option. Each command is executed across all instances.

This is the file format:

--USERNAME=eqsys --CONNECTION=http://myhost:7777/search/api/admin/AdminService

This command opens connections using a file named remotehosts.lst:

$ searchadmin --CONNECTION_LIST=remotehosts.lst

Using the Help Command

The Help command provides the basic command syntax and descriptions of administrative objects. You can enter the help command in an interactive session or as an individual command, as shown here:

$ searchadmin help

Search Admin Command Line - Release
Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.

Usage: searchadmin [<connectionArgs>] [<operation>] [<operationArgs>]

Table 1-1 describes the searchadmin help commands.

Table 1-1 Help Syntax

Command Description


Provides the searchadmin command syntax, and lists the administrative object types and operations.

help object_type

Describes object_type.

help operation

Provides the command syntax for operation.

help statusCodes

Describes the status codes that are displayed after an operation is performed on multiple objects by createAll, deleteAll, deleteList, or updateAll.

help duplicateMethod

Describes the settings of the --DUPE_METHOD parameter in the createAll command.

help updateMethod

Describes the settings of the --UPDATE_METHOD parameter in the update and updateAll commands.

help notFoundMethod

Describes the settings of the --NOT_FOUND_METHOD parameter in the updateAll command.

Command Syntax

The following is a summary of the searchadmin command syntax.

searchadmin [--USERNAME=admin] [--PASSWORD=password] [{--CONNECTION=connection] | --CONNECTION_LIST=filename}] [operation] 


searchadmin [-u admin] [-p password] [{-c connection | -m filename}] [operation]

Administrator user name, which is eqsys by default.


Password for the administrator. You are prompted for the password if you omit it from the command. If you are connecting to multiple instances, the password is used for authentication on all of them; omit this argument if they do not use the same password.


Connection to a remote Oracle SES instance. The connection is to the local instance identified by Oracle home. You can connect using HTTP, using the following syntax:


For HTTP, the port number is the same as connecting to the Administration GUI.


The name of the connection file. The path can be absolute or relative to the current directory.


An administrative operation, as described in Chapter 3, "searchadmin Commands." Omit this argument to open an interactive session. Like the searchadmin command, the operations have a short form and a long form for many arguments.