Wednesday 12 August 2015

$SDEHOME/etc – Understanding SDEHOME and its components

Whether it’s $SDEHOME or %SDEHOME% the “etc” folder contains a wealth of information that, when encountering an error,  may point out something silly and easy to fix or at least lead you in the right direction.

dbinit.sde

The dbinit.sde file is read each time the ArcSDE instance starts.  This file can be used to set environment variables for error logging, location paths, user names, passwords and more.  Here are two environment variables to enable a client intercept log.

set SDEINTERCEPT=TRUE

set SDEINTERCEPTLOC= “C:\Temp\client_intercept”

Environment variables

dbtune.sde

This file contains the configuration keywords and their specified values.  Typically, the default parameters are acceptable but it’s possible to create new keywords or change the default values. This is a topic unto itself so I’ll leave it be for now.   Have a look at these links for more details:

What is the DBTUNE table?

What are DBTUNE configuration keywords and parameters?

giomgr.defs

This file updates the sde.server_config table in the database.  Most of the initialization parameters in this table should not need to be altered from their default settings, except possibly the TEMP location on Windows installations and MINBUFFSIZE and MAXBUFFSIZE, which can be adjusted to improve data loading performance.

The TCPKEEPALIVE parameter is the value I seem to change the most.  Setting this to TRUE can help avoid orphaned gsvr processes which can hog network resources and prevent additional connections.  Here’s an example to change the TCPKEEPALIVE parameter to true with the sdeconifg command:

C:\> sdeconfig -o alter -v TCPKEEPALIVE=TRUE -i <service> -D <database_name>


ArcSDE Command Reference

services.sde

This file stores the name and TCP/IP port number for the ArcSDE service.  Unix machines will always pull information from this file to connect.  Windows machines will only use this file when starting a service with the sdemon command.  The Windows services file can be found in the %windir%\System32\drivers\etc directory.
#
# ESRI ArcSDE Remote Protocol
#
#esri_sde 5151/tcp

sde_<service_name>.log,  goimgr_<service_name>.log

The giomgr listens for requests to connect to the database.  When the request is received, the giomgr spawns a gsrvr process for that client.  When a service fails to start or if the giomgr fails to cough up a gsrvr, a brief description of the problem and an error code will appear in this file.  Have a look at this link describing ArcSDE error return codes.

Return codes

sdedc_<database_name>.log

This contains connection information and info on specific commands and reports errors in connection initialization.  Much like the service log, this will report back what’s happening during a direct connection.

    Tip:  If you have an etc directory in your ArcGIS installation location, the file is written there. If you have neither an SDEHOME variable or etc directory, the log files are written to the temp directory.


Thanks.
NJ

No comments:

Post a Comment