Open topic with navigation
nuodb.config file is a standard configuration file, which one could optionally supply to the NuoDB
config database option. It contains a list of database options, presented as key/value pairs, where the key is separated from its value by whitespace, and each key/value pair is on its own line.
nuodb.config file is installed in
. Both the Automation Console and NuoDB Manager will search for
Caution: Stopping and starting a database is required to cause changes in
nuodb.config to be read.
By default, when NuoDB is installed,
nuodb.config contains the following:
By default, any NuoDB database process will read database options specified in
These can be overwritten by specifying the
config database option and pointing at an alternate configuration file.
Furthermore, these can all be overwritten, by specifying database options in any of the Management clients (for example, the Automation Console or NuoDB Manager). For more information see Precedence for Database Process Options.
There is only one
nuodb.config file per host. This means that you need to specify database options that might only apply to a storage manager (for example, all the
journal-* options) in addition to database options that might only apply to a transaction engine (for example,
jvm-lib). This is fine because storage managers ignore options for transaction engines and transaction engines ignore options for storage managers. In other words, you can specify all options in the one
nuodb.config file is most useful for setting database options that are specific to the particular host where a TE or SM is running. There are some common cases where this would be helpful.
The transaction engine needs to know the location of the JVM in order to run Java stored procedures. The
jvm-lib argument is used to force the TE to load a specific instance of a JVM. If
jvm-lib is not specified, the TE will use a search algorithm that on Windows will end up choosing the default JVM as specified in the registry, and on Unix will search for the JVM as specified by the
JAVA_HOME environment variable first and then in well-known locations (
/opt/java, etc...). If on a physical host in the domain, the JVM is installed in a non-default location, not pointed to by the
JAVA_HOME environment variable, then specifying
jvm-lib in the
nuodb.config file is useful.
jvm-lib setting in
See the options beginning with
journal- at Database Options. It might be ideal to set these per physical host in the domain. In particular,
journal-sync-method specifies the filesystem synchronization mechanism when the journal needs to ensure the durability of a commit. The sync mechanism has been specifically tuned for each supported OS. The
kernel sync method is the fastest but requires a battery backed disk controller. The
kernel method on Linux also requires the filesystem to support
fallocate, that is,
disk sync method is the most durable but slowest method. The
osync method is available for copy-on-write filesystems, a.k.a. ZFS.
journal setting in
You can verify changes to process options in NuoDB Manager. Let's say for example, we have a
file that looks as follows:
jvm-lib /home/joey/myjvm journal-sync-method osync max-http-connections 150
Assume these changes were made on a host with the IP address 126.96.36.199 and the process we want to check is a TE with pid 362. In NuoDB Manager, use the following steps:
nuodb [domain] >
show database processesDatabase:
testInclude options (optional): journal-sync-method max-http-connections [SM] ip-172-31-46-122/188.8.131.52:48005 (us-east-1) [ pid = 5779 ] [ db = test ] [ nodeId = 1 ] [ journal-sync-method osync ] [ max-http-connections = 150 ] RUNNING [TE] ip-172-31-46-122/184.108.40.206:48006 (us-east-1) [ pid = 5834 ] [ db = test ] [ nodeId = 3 ] [ journal-sync-method osync ] [ max-http-connections = 150 ] RUNNING [SM] ip-172-31-40-24/220.127.116.11:48005 (us-east-1) [ pid = 340 ] [ db = test ] [ nodeId = 2 ] [ journal-sync-method osync ] [ max-http-connections = 150 ] RUNNING [TE] ip-172-31-40-24/18.104.22.168:48006 (us-east-1) [ pid = 362 ] [ db = test ] [ nodeId = 4 ] [ journal-sync-method osync ] [ max-http-connections = 150 ] RUNNING nuodb [domain] >
show process configHost:
362Configuration for ip-172-31-40-24/22.214.171.124:48006 agent-port = 48004 allow-non-durable = false commit = remote:1 config = /opt/nuodb/etc/nuodb.config database = test enabled-ciphers = RC4 help = false initialize = false journal = enable journal-buffer-size-bytes = 1000000 journal-max-directory-entries = 1000 journal-max-file-size-bytes = 1000000 journal-sleep-interval-ms = 10 journal-sync-method = osync jvm-lib = /home/joey/jvm/lib/libjvm.so max-http-connections = 150 mem = 2147483648 node-port = 48005 show-archive-history = false version = false