Splunk® DB Connect

Deploy and Use Splunk DB Connect

Acrobat logo Download manual as PDF


This documentation does not apply to the most recent version of Splunk® DB Connect. For documentation on the most recent version, go to the latest release.
Acrobat logo Download topic as PDF

db_connections.conf.spec

The db_connections.conf file stores all configuration necessary for connecting to a specific database, unless overridden by parameters from identities.conf.

Compared to DB Connect 2, in DB Connect 3, the fields

  • username and password have been removed.
  • cwallet_location, sslConnectionType and oracle_cipher_suites have been removed, configure these fields in connection_properties.
# @copyright@
# The file contains the specification for database connections

[<name>]

serviceClass = <string>
# optional
# inherits from db_connection_types.conf if not configured
# java class that serves the jdbc service for this type.


customizedJdbcUrl = <string>
# optional
# the user customized jdbc url used to connect to database, empty or missing means use template to generate jdbc url.
# see jdbcUrlFormat and jdbcUrlSSLFormat defined in db_connection_types.conf.spec


jdbcUseSSL = true | false
# optional
# inherits from db_connection_types.conf if not configured
# default is false, whether this type of connection will support SSL connection.



jdbcDriverClass = <string>
# optional
# inherits from db_connection_types.conf if not configured
# java jdbc vendor driver class.



testQuery = <string>
# optional
# inherits from db_connection_types.conf if not configured
# simple SQL to test validation for this database type.



database = <string>
# required only when other parameters refer to.
# inherits from db_connection_types.conf if not configured
# The default database that the connection will use



connection_type = <string>
# required
# The type of connection configured in db_connection_types.conf that the connection refer to



identity = <string>
# required
# The database identity that the connection will use when connecting to the database
# an identity provides username and password for database connection.



isolation_level = <string>
# optional
# The transaction isolation level that the connection should use
# valid values are: TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE and DATABASE_DEFAULT_SETTING
# default: DATABASE_DEFAULT_SETTING.



readonly = true|false
# optional
# Whether the database connection is read-only. If it is readonly, any modifying SQL statement will be blocked



host = <string>
# required only when other parameters refer to.
# The host name or IP of the database server for the connection
# Possible variable from jdbcUrlFormat.



port = <int>
# required only when other parameters refer to.
# inherits from db_connection_types.conf if not configured
# The TCP port number that the host database server is listening to for connections
# Possible variable from jdbcUrlFormat.


informixserver = <string>
# optional
# Required option for informix server to compose proper jdbc connection url.
# This attribute is used for informix server connection setup only.


useConnectionPool = true|false
# optional
# boolean to make connection use a connection pool
# defaults to true



connection_properties = <string>
# optional, differs via different databases.


fetch_size = <int>
# optional, default is 100, the number of rows retrieved with each trip to the database.


maxConnLifetimeMillis = <value>
# optional, default is 120000 = 120 seconds
# valid when useConnectionPool = true
# The maximum lifetime in milliseconds of a connection. After this time is exceeded the connection will fail the next activation, passivation or validation test.
# A value of zero or less means the connection has an infinite lifetime.


maxWaitMillis = <value>
# optional, default is 30000 = 30 seconds
# valid when useConnectionPool = true
# The maximum number of milliseconds that the pool will wait (when there are no available connections) for a connection to be returned before throwing an exception.
# [250, 300000] milliseconds is a reasonable value to wait to establish a connection.  The max wait time is 300000 millisenconds (300 seconds).



maxTotalConn = <value>
# optional, default is 8 connections
# valid when useConnectionPool = true
# The maximum number of active connections that can be allocated from this pool at the same time, or negative for no limit.

Example:

[oracle_example]
connection_type = oracle
database = orcl
disabled = 0
host = oracle.host.com
identity = oracle_identity
jdbcUseSSL = true
port = 2484
readonly = false
customizedJdbcUrl = jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=oracle.host.com)(PORT=2484))(CONNECT_DATA=(SERVICE_NAME=orcl)))
connection_properties = {"oracle.net.authentication_services": "(TCPS)", "oracle.net.ssl_cipher_suites": "(SSL_DH_anon_WITH_3DES_EDE_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA)", "javax.net.ssl.trustStore": "/opt/splunk/cwallet/cwallet.sso", "javax.net.ssl.trustStoreType": "SSO", "javax.net.ssl.keyStore": "/opt/splunk/cwallet/cwallet.sso", "javax.net.ssl.keyStoreType": "SSO"}

[informix_example]
connection_type = informix
database = test
disabled = 0
host = informix-demo.host.com
identity = informix_win
informixserver = demo_on
jdbcUseSSL = false
port = 9088
readonly = false
customizedJdbcUrl = jdbc:informix-sqli://informix-demo.host.com:9876/test:informixserver=demo_on;DELIMIDENT=Y
Last modified on 19 June, 2017
PREVIOUS
db_connection_types.conf.spec
  NEXT
db_inputs.conf.spec

This documentation applies to the following versions of Splunk® DB Connect: 3.0.0, 3.0.1, 3.0.2, 3.0.3


Was this documentation topic helpful?


You must be logged into splunk.com in order to post comments. Log in now.

Please try to keep this discussion focused on the content covered in this documentation topic. If you have a more general question about Splunk functionality or are experiencing a difficulty with Splunk, consider posting a question to Splunkbase Answers.

0 out of 1000 Characters