The following list summarizes the steps required to connect from ArcGIS to a Dameng database:
- Install and configure the DM client on your ArcGIS client machines.
- Once the DM client is configured on all ArcGIS client machines, create a database connection.
- If you connect from ArcGIS Server on Linux, edit the init_user_param.sh script on each ArcGIS Server machine to include information about the DM client and restart ArcGIS Server on each machine.
- To publish ArcGIS Server web services that reference the data in the Dameng database, register the database connection file with your ArcGIS Server sites.
Install the DM client
A DM client is needed on all ArcGIS client machines that will connect to Dameng.
You can download the DM client from Dameng Customer Support. Follow the instructions provided by Dameng to install the DM client. 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 the DM client for you.
When you configure the DM client on ArcGIS Server Linux machines and the operating system contains a version of the libodbcinst.so library, create a soft link to libodbcinst.so. In the following example, a link is made to libodbcinst.so from libodbcinst.so.2.0.0:
ln -s libodbcinst.so /usr/lib64/libodbcinst.so.2.0.0
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 DM client for you.
Connect to the database
You can use the Database Connection dialog box in ArcGIS Pro to connect to the database, as described below.
Alternatively, you can run the Create Database Connection tool in ArcGIS Pro or use Python to run the Create Database Connection command from an ArcGIS Server machine to create a database connection file (.sde) that connects to the database.
To use the database connection file with ArcGIS Server, you must save user information with the connection file.
Tip:
Ensure the account used for the connection has the appropriate privileges in the database and on the data that the account needs to access. See Privileges for using ArcGIS with Dameng for more information.
The following steps describe using the Database Connection dialog box in ArcGIS Pro to connect to a Dameng database:
- Open the Catalog pane in ArcGIS Pro.
- Right-click Databases and click New Database Connection.
- Choose Dameng from the Database Platform drop-down list.
- In the Data source text box, type the name of the server where Dameng is installed.
- Choose Database authentication for the Authentication Type.
Operating system authentication is not supported.
- Provide a valid username and password in the User name and Password text boxes, respectively.
- Uncheck Save user name and password if you prefer not to save your login information as part of the connection; doing this can help maintain the security of the database. However, if you do this, you will be prompted to provide a username and password every time you connect.
Note:
Save user name and password must be checked for connection files that you register with an ArcGIS Server site, or if you want to search ArcGIS Pro to locate data accessed through this connection file.
- Click OK to create the connection file.
A database connection appears under Databases in the Catalog pane, and a connection file (.sde) is created in the ArcGIS Pro project directory.
You can rename the file by typing a new name in the Catalog pane and pressing Enter.
Alter the init_user_param.sh script (ArcGIS Server on Linux only)
After you install the database client files, alter the init_user_param.sh script installed with ArcGIS Server to reference the client files. You can access this script by browsing to the <ArcGIS Server installation directory>/arcgis/server/usr directory.
You must update the init_user_param.sh on every machine in the ArcGIS Server site.
On most Linux operating systems, you must also create a link from the libodbcinst.so library version on your machine to libodbcinst.so.
- Ensure that the ArcGIS Server installation owner on each machine has at least read and execute permissions on the database client libraries.
- Open the init_user_param.sh script in a text editor.
- Remove the comment marks (#) from the lines beginning with export and replace <Dameng_InstallDir> with the path to your DM client installation.
# Modify this section to configure a connection to Dameng. export DAMENGDIR=<Dameng_InstallDir> export LD_LIBRARY_PATH=$DAMENGDIR/bin:$LD_LIBRARY_PATH
- Save and close the script.
- The DM client requires the libodbcinst.so library. If you have a different version of the library, you must create a soft link to reference libodbcinst.so.
In this example, a link is created between libodbcinst.so.2.0.0 and libodbcinst.so.
ln -s libodbcinst.so /usr/lib64/libodbcinst.so.2.0.0
- For the changes you made in the init_user_param.sh file to take effect, you must restart ArcGIS Server.
To do this, run the stopserver.sh script, then run the startserver.sh script on each machine in the ArcGIS Server site.
./stopserver.sh
./startserver.sh
Register the database with ArcGIS Server
If you want web services to use the data in the Dameng database, register the database with your ArcGIS Server sites.
You can use the database connection file you created to register the database with ArcGIS Server from the Manage registered data stores pane in ArcGIS Pro or from ArcGIS Server Manager.