Which instance configuration file is used by an instance of the Application Server can be specified by using a command line argument. The Windows service installed with the Application Server Setup Program or the Application Server Instance Setup program will automatically be configured to point to the right configuration file.
Following information is only needed if you change the location of your instance configuration file.
If this command line argument is not given the Application Server tries to locate the instance configuration file automatically.
If the instance configuration file is erroneous (e.g. due to manual editing) the Application Server will not start. The instance configuration file is loaded at the very beginning of the Application Server startup even before logging is initialized. Therefore the Application Server will log errors with instance configuration files to the Windows event log.
Changes to instance configuration files will only take effect after a restart of the Application Server instance. The instance configuration files must be readable by the user who executes the Application Server. Instance configuration files might include sensitive data, therefore you should carefully plan who can read those files.
Command line
The command line argument for specifying the used instance configuration file is --InstanceConfiguration or -i. You can specify the instance configuration either as relative or as absolute path. Relative paths are interpreted relative to the Application directory. If the specified instance configuration file is not found the Application Server will fail to start.
Note: The user who will actually execute the Application Server (as windows service) must have access to the specified instance configuration file.
Examples:
In the following example the instance configuration file is specified as absolute path
ApplicationServer.exe --InstanceConfiguration="d:\redbex\instanceconfigurations\A254.icfg"
In the following example the instance configuration file is specified as relative path. If the Application Server is installed in c:\program files\redbex\Application Server\ this relative path would be expanded to c:\program files\redbex\Application Server\A252.icfg.
ApplicationServer.exe -i="A252.icfg"
Automatic detection
If the instance configuration file is not specified on the command line the Application Server tries to locate the configuration file automatically. For this the Application Server will search for all files with extension .icfg in the Application directory and will then take the alphabetically first of these files. If the instance configuration file is not specified on the command line and no .icfg files are found in the Application directory the Application server will not start.