ArcGIS Server Banner

Using multiple geodatabases in PostgreSQL

Using multiple geodatabases in PostgreSQL

Release 9.3 E-mail This TopicPrintable VersionGive Us feedback
For PostgreSQL, you store one geodatabase per database. You can create multiple databases on the same PostgreSQL database cluster, but clients connect to one database at a time.

Two geodatabases (one per database) in one instance of PostgreSQL

If you are using an ArcSDE service for connection, each database needs its own ArcSDE service. These different ArcSDE services can be running on the same server machine but do not have to be. Each connection to the ArcSDE service or direct connection to a database will access and use only one database.

To set up multiple geodatabases in PostgreSQL, follow the instructions specific to your operating system below.

For Linux

  1. Create an additional database on the PostgreSQL database cluster and create an sde schema in the new database.
  2. Add a new ArcSDE service name, port number, and network protocol to the services.sde file in your SDEHOME/etc directory (if you will be using an ArcSDE service for connections).
  3. If you plan to set variables in the dbinit.sde file to connect to the second geodatabase, make a copy of your dbinit.sde file, giving it a new name. This name must include the name of the new ArcSDE service. For example, if the new service name is sdepgsql2, name the dbinit file dbinit_sdepgsql2.sde.
  4. Set the appropriate variables in the new dbinit file.
  5. If you will be using different configuration parameters in your second geodatabase, make a backup copy of your existing giomgr.defs and dbtune.sde files in your SDEHOME/etc directory, then alter the giomgr.defs and dbtune.sde files to contain the parameters and values you desire for the new geodatabase.
  6. Run sdesetup –o install to create the geodatabase repository in your second database.
  7. sdesetup –o install –d POSTGRESQL –D <name_of_second_database> –u
    sde –p <sde_user_password> –l <license_key>

  8. If using one, start the second ArcSDE service with the sdemon command.
  9. sdemon –o start –i <service_name> –s <server_name> –p <sde_user_password>

For Windows

You can use the ArcSDE for PostgreSQL Post Installation wizard to create additional databases and geodatabases. If clients only use direct connections to each separate geodatabase, you do not need to create an ArcSDE service. However, if clients will connect using an ArcSDE service, you need to create an additional service for each additional geodatabase. This can be done through the Post Installation wizard; just be sure to specify a different service name, port number, and the correct database name on the ArcSDE service information dialog box. The Post Installation wizard will add the new service information to the services.sde file and the Windows services file.

If you plan to use different settings in the dbtune.sde, giomgr.defs, or dbinit.sde files, these changes must be made before running the Post Installation wizard.

See Also

  • Using multiple geodatabases within a DBMS