infx-config.inst
This is the default instance config file use to create new infx instances.
Only make changes to a a local copy of this file.
Instance config files define the actions taken when you create a new instance with infx.
instance creation
The steps to create a new instance are:
- create directories for the new instance e.g. /infx/inst/${inst}/logs
- create files for the new instance e.g. an empty root chunk file
- create links for the new instance e.g. to informix software, to other file system locations
- if defined, create sqlhosts entries for the new instance
- if one does not exist, generate an onconfig file for the instance
- if settings supplied, create an instance config.ini
directories, files and links
Specify the directories, files and links that need to be created.
A relative path is expanded to /infx/inst/${inst}/.
Items are created in the order they appear in the config file.
Items are skipped if they already exist.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
[[ new type="dir" path="chks" mode="755" note="where to store chunk files" ]] [[ new type="dir" path="backup" mode="755" note="backup files" ]] [[ new type="dir" path="backup/db" mode="775" note="dbspace backup files" ]] [[ new type="dir" path="backup/logs" mode="775" note="logical log backup files" ]] [[ new type="dir" path="logs" mode="755" note="instance, command and service log files" ]] [[ new type="dir" path="etc" mode="755" note="instance specific config files" ]] [[ new type="dir" path="tmp" mode="755" note="temporary file location" ]] [[ new type="dir" path="dump" mode="755" note="instance diagnostic dumps, can be large" ]] [[ new type="dir" path="sql" mode="755" note="sql files" ]] [[ new type="dir" path="exports" mode="755" note="location for unloads" ]] [[ new type="file" path="chks/root.001" mode="660" note="create file for root chunk" ]] [[ new type="file" path="informixdir/etc/sysadmin/stop" mode="660" note="stop dbworker/dbscheduler" ]] [[ new type="file" path="etc/allow-autostart" mode="660" note="start instance when server starts" ]] [[ new type="file" path="etc/allow-autobackup" mode="660" note="include instance in auto backups" ]] [[ new type="link" path="informixdir" source="/infx/sw/latest" note="informix product binaries" ]] |
sqlhosts
Define the sqlhosts entries that are needed for this instance. infx supplies some parameters to make automating this easier.
In order to create multiple instances with network connections, they each need a unique port number.
infx allows you to supply a base port number as a parameter. infx then adds the new instances server number to the base port number to automatically determine the port number for this instance.
Here is an example from the defaults:
1 2 3 4 5 6 7 8 |
[[sqlhosts]] server=${newinst} tcpprotocol=onsoctcp host=${host} baseport=62000 service=${port} options= note=connect via tcp |
An instance with server number 0 will get ${port} = 62000. Instance with server number 55 will get ${port} = 62055.
Default shared memory connection:
1 2 3 4 5 6 7 |
[[sqlhosts]] server=${newinst} protocol=onipcshm host=${host} service=${newinst} options= note=local shared memory connection |
onconfig
When you create an instance, you specify the name of an onconfig template to use. When the instance is created, if there is not already an onconfig file, and new one is created from this template.
The following variables can be used in the template:
variable | description | example |
---|---|---|
[[INST]] | the name of the new instance | DBSERVERNAME [[INST]] |
[[SERVERNUM]] | the new server number | SERVERNUM [[SERVERNUM]] |
Example from default onconfig.
1 2 3 |
SERVERNUM [[SERVERNUM]] DBSERVERNAME [[INST]] DBSERVERALIASES [[INST]]tcp |
See the whole template here: onconfig template.
infxenv
Use this to add settings to the new config.ini file for the instance. Specify what parameters you want to put in the infxenv section here.
Example:
1 2 |
[infxenv] TMPDIR=/scratch/tmp |
When you create the instance, it will place its temp files in /scratch/tmp instead of under /infx/inst.
env
Use this section to set what goes in the env section of the new instance config.ini
1 2 |
[env] DBDATE=DMY4/ |
template
Use this section to set what goes in the template section of the new instance config.ini
1 2 |
[template] COMPANY_NAME = other company system |