BUG

ORA-06522: (path)\st_shapelib.dll: cannot open shared object file: No such file or directory

Last Published: April 25, 2020

Description

When accessing the Spatial Type for Oracle using SQL, the following error message is displayed:

"ERROR:
ORA-06520: PL/SQL: Error loading external library
ORA-06522: (path)\st_shapelib.dll: cannot open shared object file: No such file or directory
ORA-06512: at "SDE.ST_GEOMETRY_SHAPELIB_PKG", line 12
ORA-06512: at "SDE.ST_GEOMETRY", line 56"

The path and name of the ST_Geometry shape library was not created correctly in the Oracle data
dictionary view USER_LIBRARIES. Check this by using this SQL statement when logged into Oracle as the SDE user:

Code:
SQL> select file_spec from user_libraries where library_name = 'ST_SHAPELIB';

FILE_SPEC
--------------------------------------------------------------------------------
c:\arcgis\arcsde\ora10gexe\bin\st_shapelib.dll

The path returned from this query does not exist on the Oracle server.

Cause

This is a known issue.

This can happen when running sdesetup on an Oracle instance from a remote system, and the remote system has a different operating system or a different location for SDEHOME.

The sdesetup uses the string specified in the '-H' option of sdesetup used to create a path to the location of ArcSDE libraries. The path is constructed as <specified_path>\bin on Windows, or <specified_path>/lib on Unix and Linux. The path must be valid and contain the direct connect libraries in order for sdesetup to work. This path is used for at least two things:

· The location of the direct connect libraries needed for sdesetup to connect to the database to do its work.

· The location of the library that is used in the CREATE LIBRARY command. This is the command that inserts into ALL_LIBRARIES for later use by the EXTPROC.

When Oracle and ArcSDE are on the same system, these two uses are compatible. Both point to the local SDEHOME/lib or SDEHOME/bin. But when sdesetup is run on one system to set up another, the uses of this path are probably not compatible.

Workaround

Recreate the library reference on the remote Oracle server as the Oracle user 'SDE':

Code:
SQL> create or replace library ST_SHAPELIB
2 as '/opus1/sde/sdeexe93/lib/libst_shapelib.so';
3 /

Library created.

SQL> alter package sde.st_geometry_shapelib_pkg compile reuse settings;

Package altered.


Note:
Keep in mind that replacing the definition for ST_SHAPELIB invalidates some database objects. This is usually not a problem because Oracle attempts to recompile invalid packages when it encounters them.

One complication of remote ArcSDE/Oracle installations is that the libraries needed by the EXTPROC must be installed on the remote Oracle server. A simple copy from the SDE server is not possible if the OS is different.

    Article ID: 000009389

    Software:
    • ArcMap 9 x
    • Legacy Products

    Receive notifications and find solutions for new or common issues

    Get summarized answers and video solutions from our new AI chatbot.

    Download the Esri Support App

    Discover more on this topic

    Get help from ArcGIS experts

    Contact technical support

    Download the Esri Support App

    Go to download options