ERROR: Create Enterprise Geodatabase for PostgreSQL 9.1 on Linux Server

2372
4
09-13-2013 01:27 PM
ShinKobara1
New Contributor
Hi all,

I know that several users have similar issue and post it before.
I was really looking for the answer but none of them work for me. Can someone please give me some advice?

Here is a dialog message on ArcToolbox
Executing: CreateEnterpriseGeodatabase PostgreSQL xxx.xxx.com arcgisdb DATABASE_AUTH postgres ***** SDE_SCHEMA sde ***** # "C:\Program Files (x86)\ESRI\License10.1\sysgen\keycodes"
Start Time: Fri Sep 13 15:30:44 2013
User has privileges required to create database objects.
Geodatabase admin user already exists.
Database already exists.
Validated authorization file.
User has required privileges for geodatabase setup.
XML support is enabled for the database instance.
You must copy the latest ST_GEOMETRY and dependent libraries to the PostgreSQL software location. Refer to the ArcGIS help topics for more details.

Connected RDBMS instance is not setup for Esri spatial type configuration.
Failed to execute (CreateEnterpriseGeodatabase)
.


Here is my current environment.
Client/ArcGIS
ArcGIS for Desktop 10.1 Advanced on Win2008 R2 (64bit)
ArcGIS for Server 10.1 for Windows and SQL Server are installed on the same machine, but I'm transferring all data to Linux server.

Server
Linux Server: 64-bit CentOS5 (Red hat base)
ArcGIS for Server 10.1 Advanced for Linux
PostgreSQL 9.1.5

Note that since our linux server is located different place, pg_hda.conf is already edited. I can see databases (Postgresql on Linux) via pgAdminIII (on Windows).

by using pg_config, I made sure the PKGLIBDIR = /usr/lib/postgresql
I've also set up $SDEHOME = /home/xxx/arcgis/server
$PG_HOME = /usr/pgsql-9.1
Then, $LD_LIBRARY_PATH = /usr/lib/postgresql:/usr/pgsql-9.1/lib:/home/xxx/arcgis/server/lib:/usr/lib64/postgresql/
(Just in case, I added /usr/lib64/postgresql as well)

After this, I copy st_geometry.so and post it to /usr/lib/postgresql (see attached)
I also save it to /usr/pgsql-9.1/lib and /usr/lib64/postgresql just in case.
I copied and pasted by root user and set the access permission 755.

and I even restarted postgresql.
But the same result.

I also tested st_geometry.so from both ArcGIS Desktop machine and ArcGIS Server for Linux
C:\Program Files (x86)\ArcGIS\Desktop10.1\DatabaseSupport\PostgreSQL\9.1\Linux64\st_geometry.so
and
/home/xxx/arcgis/server/DatabaseSupport/PostgreSQL/9.1/Linux64/st_geometry.so

They didn't work.

What else should I try to figure out? Can someone give me some advice?
0 Kudos
4 Replies
VinceAngelo
Esri Esteemed Contributor
I'm a firm believer that application software should be installed as application
software, not as part of the OS.  If you download and extract the latest stable
binary release of PostgreSQL, you wouldn't be subject to strange operating
system behavior (or subject to unplanned database upgrades).

It's quite possible that your PG install is 32-bit; using 'file' on one of the
other DLLs and/or the running version of 'postgres' would tell for sure.

I strongly recommend applying 10.1 SP1 *before* doing an initial geodatabase
install.

- V
0 Kudos
ShinKobara1
New Contributor
Vince, thank you for your comment.

ArcGIS Server for Linux is actually 10.1 SP1. Sorry, I should have written it accurately.
and I've checked postgresql version.
It is said:
psql (9.1.5, server 9.1.9)
# select version();
version
--------------------------------------------------------------------------------------------------------------
PostgreSQL 9.1.9 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54), 64-bit

ArcGIS Server 10.1 SP1 was installed and then PostgreSQL 9.1 was installed. But 9.0 was running so our colleague switched to 9.1 as a main database.
ArcGIS for Desktop is also 10.1 SP1 by the way.

re-installing postgresql-9.1 is only option?
0 Kudos
VinceAngelo
Esri Esteemed Contributor
You appear to be using two different sets of binaries ("psql (9.1.5, server 9.1.9)") with a
lower client accessing a higher server.  The client should always be at or higher than the
server release.

Try explicitly setting the PATH so that the 9.1.9 binaries come first before staring the PG
service ('pg_ctl start').  ArcGIS isn't going to raise the "You must copy the latest
ST_GEOMETRY.."
error if the DLL is installed in the correct directory.

- V
0 Kudos
ShinKobara1
New Contributor
We've upgraded a client version same as server (9.1.9) and set PATH as follows.

bash-3.2$ echo $PATH
/usr/java/jdk1.7.0_02/bin:/usr/kerberos/sbin:/usr/lib64/qt-3.3/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin://usr/java/jdk1.7.0_02/bin:/usr/pgsql-9.1/bin:/home/ags/arcgis/server/bin
bash-3.2$ echo $LD_LIBRARY_PATH
:/usr/lib/postgresql:/usr/pgsql-9.1/lib:/home/ags/arcgis/server/lib

But it didn't work.

System admin and I checked all pg_config folders and realized that sysconfdir=/usr/etc/postgresql doesn't exist. It's located at var/lib/pgsql/9.1/data. So the error might be due to our configuration.

but thank you for your suggestion. I appreciate it.
0 Kudos