To publish ArcGIS Server web services that access the data in your Oracle database (whether the database contains a geodatabase or not), your ArcGIS Server site must connect to the database. To configure that connection, do the following:
- Install Oracle client software on the ArcGIS Server machines and the ArcGIS Desktop client machines.
- Set variables on the ArcGIS Server machines.
- Connect to the database.
- Grant privileges.
- Register the connection file with your ArcGIS Server site.
Install Oracle client software
Oracle client software must be installed on all ArcGIS client machines that will connect to the database. See Connect to Oracle from ArcGIS for instructions on installation and configuration of the Oracle client software. If you do not have the privileges to install software on the machines where ArcGIS clients are running, you'll need to have your IT department install and configure the Oracle client for you.
Use the following table to determine the appropriate configuration for your site:
Installation combinations | Configuration to use |
---|---|
ArcGIS Server (single machine site) and Oracle are installed on the same server; ArcGIS Pro is installed on different machines. | Install a 64-bit Oracle client on all ArcGIS Pro machines, and set the PATH variable to the Oracle client home directory. You do not need to install an Oracle client on the server because files to connect are installed with the Oracle DBMS. Just be sure the LD_LIBRARY_PATH (Linux server) or PATH (Windows server) system variable is set to the Oracle home directory. If you set a tnsname for the Oracle client, you must use the same name on the ArcGIS Server and ArcGIS Pro machines. |
ArcGIS Server is installed on one or more machines that are separate from the DBMS. ArcGIS Pro is installed on computers separate from both Oracle and ArcGIS Server. | Install a 64-bit Oracle client on all ArcGIS Pro machines, and set the PATH variable to the Oracle client home directory. Install the 64-bit Oracle client on all ArcGIS Server machines and be sure the PATH (Windows) or LD_LIBRARY_PATH (Linux) system variable is set to the Oracle client home directory. If you set a tnsname for the Oracle client, you must use the same name on the ArcGIS Server and ArcGIS Pro machines. |
ArcGIS Server and ArcGIS Pro are installed on the same server; Oracle is installed on a different server. | Install the 64-bit Oracle client on all ArcGIS Server machines. Both ArcGIS Server and ArcGIS Pro will use this client. Set the PATH system variable to the Oracle client home directory. |
ArcGIS Server, ArcGIS Pro, and Oracle are all installed on one machine. | ArcGIS Server and ArcGIS Pro will use the 64-bit client files installed with the Oracle DBMS to connect. Set the PATH variable to the Oracle client home directory. If your ArcGIS Server site includes additional servers, install the 64-bit Oracle client on each of the servers in the site, and set the PATH variable to the Oracle client home directory. |
Set variables
There are variables you must set in the ArcGIS Server init_user_param.sh script to reference the Oracle client libraries when connecting from ArcGIS Server (Linux). Which variables you set depends on the type of Oracle client you install and how you configure it.
See Configure a database connection for ArcGIS Server for more information.
Connect to Oracle
To register an Oracle database with an ArcGIS Server site, you'll need the following information:
- The type of database management system to which you are connecting (in this case, Oracle)
- A valid Oracle connection string
If your Oracle server and client are set up to use Easy Connect, you can provide a valid Easy Connect string. Some examples of this connection type are provided in Database connections in ArcGIS Pro. Or you can provide the Oracle tnsname. See Oracle documentation for a full list of connection types and syntax.
- The type of authentication to be used: database or operating system
If database authentication is used, you must provide a valid database user name and password. You must save this information with the connection file.
If operating system authentication is used, use a domain account for the ArcGIS Server account and add it to the Oracle database. ArcGIS Server will use this account to connect to the database.
Grant privileges
The database user, role, or ArcGIS Server account (if you're using operating system authentication) with which you connect to the database must be granted privileges in the database to access the data to be published. The privileges and the circumstances under which you need to grant them are as follows:
Privilege | Reason |
---|---|
CREATE SESSION | Required to connect to the database. |
CREATE TABLE | Selection sets cause a log file table to be created in the geodatabase. If a user does not have this privilege, log file tables will be created in the sde user's schema. |
SELECT privileges on the datasets to be published | Grant the user or ArcGIS account at least SELECT privileges on the datasets to be published. |
INSERT, UPDATE, or DELETE privileges on data published to editable feature services | To edit data through a feature service, privileges sufficient to edit must be granted on the datasets. |
If you will be registering the geodatabase as a managed database for a stand-alone or federated ArcGIS Server site, the account with which you connect must have privileges to create data in the geodatabase. See Privileges for geodatabases in Oracle or Privileges for using ArcGIS with an Oracle database for more information.
The database administrator must grant the first two privileges listed above. If the data is in a geodatabase, the data owner must grant the required privileges on the datasets. If the data is in a database, the data owner can grant privileges on datasets from ArcGIS or the database administrator can use database tools to grant the required privileges.
Register with ArcGIS Server
You can register the database from ArcGIS Server Manager, the Manage registered data stores pane in ArcGIS Pro. If the ArcGIS Server site is federated with an ArcGIS Enterprise portal, you can register the database by adding a user-managed data store item in the portal.
See the following for an explanation of registration options and how to register the database: