The database server can be configured to listen for more than one server name for a particular database server. Server names
other than the real server name are called alternate server names, and are specific to a particular database running on the
database server. Clients can specify the alternate server name using the ServerName parameter to connect to that database.
Alternate server names must be unique on the network; otherwise, the database fails to start. If the database is started in
the server command and the alternate server name is not unique, the server fails to start. You can also provide an alternate
server name using the START DATABASE statement.
Clients that specify an alternate server name can only connect to the database that specified the alternate server name. They
cannot connect to, create, stop, and drop other databases on the same database server. If the DBN or DBF connection parameter
is specified, it must match the database name or database file, respectively. If the DBN or DBF connection parameter is not
specified, then the database acts as the default database for that server.
The Server Enumeration utility (dblocate) detects alternate server names.
Using alternate server names for database mirroring
When using database mirroring, an alternate server name must be specified for client applications to be able to connect to
the current primary server without knowing in advance which server is the primary server and which is the mirror server. Both
operational servers must use the same name for the alternate server name.
The -sn database option must be specified after the database-file, and applies only to that database.
The following command starts the databases satest.db and sample.db on a database server named myserver. The -sn option instructs the database server to use mysample as an alternate server
name when connecting to sample.db.