Database Access Key and Connections
On this page
- Where the key is needed
- When a new key is issued
- Manage the key in the Database Management wizard
- Distribute the key
- Import the key
- Manage connections in the Settings App and the Import Wizard
- Import the key in other tools
- Connection errors
- Diagnose a computer that cannot connect to the SQL Server
- Related topics
The Windows administrative tools of Alloy Navigator, such as the Settings App and the Automation Server Manager, open their SQL Server connection with the credential of a Database Access Key. A key holds the SQL Server name, the database name, and the Database Account credential: an authentication mode (Windows Authentication or SQL Server Authentication), a login, and a password.
When it creates a database, the Database Management wizard generates a key for
it. It writes the key to the registry, saves a copy into the database itself,
and exports it to a .reg file.
A connection is a named profile, stored for one Windows user, that names a key, a SQL Server, and a database, and holds the technician's own sign-in for that connection. The technician's sign-in is not the key's credential: a connection offers Windows Authentication or Standard Authentication for signing in, while a key's mode reads Windows Authentication or SQL Server Authentication.
The Administrative Tools package that the Alloy Navigator Cloud installer names holds five Windows tools: the Settings App, the Import tool, Active Directory Import, the Scheduled Task Agent, and the Alloy Control Panel. These tools connect through a Database Access Key kept in the registry; see Get Started with Alloy Navigator Cloud and Administering Alloy Navigator Cloud.
Where the key is needed
Every computer that must reach the database needs its own registered copy of the key: the Automation Server host, each web server, and each technician workstation running the Settings App. These readers of the key look for it in the registry of the computer they run on:
- The Log in window and the Connection Manager of the Settings App and the Import Wizard.
- The Automation Server's service connection.
- The Web Configuration tool, which lists only the keys made for its own product.
A registered key is kept under
HKEY_LOCAL_MACHINE\SOFTWARE\Alloy Software\Access Keys\<key name>. A key is
named <SQL Server> : <Database> after the values it was made with. A
backslash in the server name is stored as a slash, and the Connection
Manager's Key Name: list shows it as a backslash again.
Two keys come from the database instead of a distributed copy: the key a tool reads from the database and registers at the first sign-in over a legacy connection (see Other ways a tool gets its key), and the key the Alloy Discovery Synchronization connector uses for the Alloy Discovery database, which is saved with its job in the Alloy Navigator database and read from there.
When a new key is issued
- An in-place upgrade from version 8.2.0 or later writes no new key. The server, the database, and the Database Account that every registered copy names stay as they were, so the copies already registered on the computers need no new import.
- An in-place upgrade from a version below 8.2.0 shows the Database Account and Database Access Key pages and writes a new key.
- Create Pilot Database writes a new key for the pilot database.
- Switch to Production with Switch and Flip writes a key for the pilot database that takes the production database's name: a key stored in the database, re-addressed to the production database's name, or a new key when the database stores none. The run shows the Database Access Key page but no Database Account page.
- Switch to Production with Switch writes no key.
Manage the key in the Database Management wizard
The Manage your Database Access Key action of the Database Management wizard works on the access key of an existing database only. It reloads the key that the database stores, and makes a new key only when the database stores none. The wizard never starts this action by itself, and it does not detect a renamed or moved database or a changed Database Account.
When it reloads the stored key, the action points the key at the SQL Server
and database you choose in the wizard, names it <SQL Server> : <Database>
after them, and gives it the Database Account as you leave it on the
Database Account page. After you rename or move the database, or change
the Database Account or its password, run this action to issue a key that
holds the current values, and then
distribute the key. When none of these values has
changed, the action issues the same key again.
Before you begin
- The SQL Server login you use must be a member of the
sysadminfixed server role. Otherwise the wizard refuses with "You must be a member of the sysadmin role on the specified SQL Server instance. Please contact your system administrator."
Make or reload the key
- Start Database Management from the Start menu: Alloy Software > Alloy Navigator 2026 > Tools > Database Management.
- On the Task page, click Manage your Database Access Key.
- On the Database Server and Database page ("Specify the SQL server hosting the Alloy Navigator database for which you want to manage the Database Access Key. Then choose the database and click Next."), specify the SQL Server, choose the database, and click Next. The list offers the Alloy Navigator databases of the wizard's own version that your login can access.
- On the Database Account page, review the Database Account. When the database stores a key, the page is filled in from that key. The key takes the account as you leave it on this page.
- On the Database Access Key page, copy the key with
Copy to Clipboard, or click the ellipsis next to Export Key to file:
to choose where the
.regfile is saved. - Click Finish. The wizard makes the key straight away. No Ready to Proceed, progress, or Summary page follows.
Finish saves the key in the database, writes it to the registry, and
exports the .reg file. It then creates the key's SQL Server login and grants
its rights, and writes the connection for the logged-on Windows users and the
service connection. Last, it grants the key's login the service rights on
every archive database on the server.
The Database Access Key page
The page reads "View your Database Access Key and export it to a .reg file. A registered Database Access Key must exist on each computer that requires access to the database." Every field on it is read-only:
| Field | What it shows |
|---|---|
| Key name: | The key's name, <SQL Server> : <Database>. |
| Access Key Content | The encoded key. |
| Copy to Clipboard | Selects the whole content and copies it. |
| Export Key to file: | The path of the .reg file. You cannot type into it. The ellipsis opens the Enter the file name to save dialog, which offers Registration Files (*.reg) or All files (*.*), in the folder the field already names. |
The export path is filled in for you: your Desktop folder and the file name
AlloyDBAccessKey_<SQL Server>_<Database>.reg. In the server and database
names, spaces and the characters \ / : * ? " < > | are replaced with
underscores. A note under the export path reads "Use this .reg file to
distribute the Database Access Key to all computers that have Alloy Navigator
installed and require access to the database. For example, send this file via
e-mail or deploy it through Group Policy."
The ellipsis stays unavailable until the key carries a login, and also a password unless the login is a Windows login.
On the other runs of the wizard that show the page, its button is Next:
- Next stays unavailable under the same condition as the ellipsis.
- An empty export path is refused with "The "Export Key to file:" field is mandatory, it can't be left blank."
- If the computer's key store cannot be written, Next is refused with "Failed to store the Database Access Key. To fix the issue, run the Database Management under a local Administrator account."
On the Manage your Database Access Key action the button is Finish instead, and these rules do not apply to it.
Choosing a path writes nothing. The run writes the key to the database, to the registry, and to the export file, in that order, and only then creates the key's SQL Server login and the user and service connection records.
Distribute the key
Distribute the key to each computer that needs it as the exported .reg file
or as the encoded string. The Database Access Key page suggests sending the
file by email or deploying it through Group Policy.
The .reg file holds two registry entries:
- The key itself, registered for the computer under
HKEY_LOCAL_MACHINE\SOFTWARE\Alloy Software\Access Keys\<key name>, with itsProduct,Version, andCreation Datevalues. - A connection that names the key, registered for the Windows user who merges the file.
Merging the file registers both entries. The Access Key Import window keeps only the key.
The key entry is what the Settings App and the Import Wizard need. They skip
every connection whose key is not registered on their computer, so the
connection entry alone has no effect. When no usable connection is left, they
create a connection from the registered key (see the next section). The connection entry of the .reg
file only creates that connection in advance for the user who merged the
file.
Other ways a tool gets its key
- When the Settings App or the Import Wizard finds no connection for the Windows user, it takes the registered key of its own product with the latest creation date and creates that key's default connection.
- When no key is registered either, it looks for the start-up settings of an older client, version 8.0, 7.0, 6.0, or 5.0, newest first. From them it builds a temporary legacy connection with their server, database, authentication, last user, and saved password, so the connection's credential is the technician's own sign-in, and the Log in window lists it. After a sign-in over this connection succeeds, it registers the key that the database stores, with its default connection, and reconnects with the key's credential. If the database stores no key, nothing is registered, and the next start builds the legacy connection again.
- The Automation Server Manager builds the same kind of legacy connection from the service's earlier settings and asks for an import when that connection does not open.
Import the key
The Access Key Import window opens from:
- Import... in the Connection Manager's Access Key group.
- Import Key... in the Automation Server Manager's Connection group.
- Import Key... in the Inventory Server Manager's Connection group.
- Import Key... in the Settings App's Alloy Discovery Synchronization window.
The Web Configuration tool's Import Key... opens the tool's own copy of the window; see In the Web Configuration tool.
Each tool opens the window filled with the key it already uses, or empty for a first import.
- Load the key: click Load from File... and choose the
.regfile (the dialog offers Access Key File (*.reg) or any file), or paste the encoded key into the text box. Load from File... reads the key value of a.regexport, or the whole text of a file that has no such value, so a file holding a bare encoded string also loads. - Check Access Key Details. It is updated on every change of the content and lists Name:, Authentication: (Windows Authentication or SQL Server Authentication), Login:, SQL Server:, Database:, and Creation Date:.
- Click Import. Import is available whatever the box holds. The window hands the key back to the tool that opened it, and that tool registers or saves it.
The window does not check which product a key was made for, so it imports a key of any product.
Manage connections in the Settings App and the Import Wizard
The Settings App and the Import Wizard sign in through the Log in window, which opens the Connection Manager.
The Log in window
The window's title begins "Log in to", and the window reads "Please type in your username and password". It holds Connection:, Authentication:, Username:, Password:, Save password, and Database:, with OK, Cancel, and Manage Connections....
- Connection: is shown when more than one connection exists or none is selected.
- Database: and Authentication: are shown only for a connection with Advanced Login Screen selected, or for the connection designated as the tool's advanced connection. Either way, the connection's own authentication is preselected.
- Windows Authentication fills Username: with the current Windows user, shows eight asterisks as the password, and makes Username:, Password:, and Save password unavailable.
- OK needs a connection, and for Standard Authentication a user name. It then checks the account behind the user name: it must be an active technician account with an account policy that the check accepts, and its person must not be inactive. A refused sign-in shows "Login failed for user '<login>'."
- With Save password selected, a successful Standard Authentication sign-in saves the user name and password with the connection, and the window fills them in at the next start. With Save password cleared, a successful Standard Authentication sign-in removes the stored password.
When there is no connection to offer and none is named at start-up, the window opens the Connection Manager by itself.
Open the Connection Manager
In the Log in window, click Manage Connections....
The Connection Manager lists by name the connections stored for the current Windows user, including connections whose key is missing, which the Log in window leaves out. When the Log in window opens the manager by itself and the manager's own list is empty too, the manager adds a new connection and opens the Access Key Import window at once.
Create or edit a connection
- Under the list, click Create new connection, or right-click the list and choose New, or press Insert. A connection named <New connection> is added. While such a connection exists, New selects it instead of adding another. To edit a connection, select it in the list.
- Enter the Name:. A name that another connection uses is refused with "Another Connection with this name already exists. Enter a different name."
- In the Access Key group, pick the key in Key Name:, or click Import... to import one. Import... is available whenever a connection is selected, and opens the window filled with the connection's current key. An imported key is registered, added to the list, and selected. SQL Server: and Database: in this group show the key's own values and cannot be edited. Picking a key for a connection that had none also sets the connection's Authentication: to the key's mode.
- In the Database Connection group, set SQL Server: and
Database::
- SQL Server: takes a typed name, a server from the list of servers
used before, or one found through <Browse for more....>. The name is used as typed, so an
instance name or a
,portsuffix is kept. For an Azure SQL host whose name contains.public., port3342is added. - Database: lists the server's Alloy Navigator databases of this tool's version, read with the key's credential.
- Left empty, either field takes the key's value.
- SQL Server: takes a typed name, a server from the list of servers
used before, or one found through <Browse for more....>. The name is used as typed, so an
instance name or a
- Select or clear Enable TLS 1.2 support; see TLS 1.2 support.
- In the Technician Account group, choose the Authentication: for your own sign-in. Windows Authentication fills Username: with the current Windows user and shows eight asterisks in Password:; Standard Authentication empties both fields for you to fill in. Select Advanced Login Screen to show Database: and Authentication: in the Log in window for this connection.
- To check the connection, click Test Connection.
- Click OK.
A new connection starts on Windows Authentication until a key sets its mode. The mode, user name, and password are saved with the connection, blank for Windows Authentication, and the Log in window fills them in for it.
Name: and Key Name: are required. New, Copy, moving to another connection, and OK are refused while one of them is empty, with "The "<field>" field is mandatory, it can't be left blank." OK saves every changed connection; Cancel discards the unsaved changes.
Test Connection is available once the connection has a key. It opens the server and database with the key's login and password, or as the key's Windows account when the key uses Windows authentication, with a 10-second timeout. It reports "Test connection succeeded." or "Test connection failed." with the server's error.
Copy or delete a connection
- To copy, click Copy Connection under the list, or right-click and choose Copy. The copy is named after the connection followed by " (Copy)" and is made from the connection as last saved, so changes not yet saved with OK are not copied.
- To delete, click Delete Connection, or right-click and choose Delete, or press Delete, and confirm "Are you sure you want to delete the selected item?". The connection is removed at once; Cancel does not bring it back.
TLS 1.2 support
Enable TLS 1.2 support sets the OLE DB provider that the connection uses:
| Check box | Provider |
|---|---|
| Selected | MSOLEDBSQL19 when that provider is registered on the computer, otherwise MSOLEDBSQL |
| Cleared | SQLOLEDB |
The provider saved with a connection takes precedence over the computer's
default provider, which is the DataProvider value under
HKEY_LOCAL_MACHINE\SOFTWARE\Alloy Software\DatabaseConnectivity. A default
of MSOLEDBSQL is used as MSOLEDBSQL19 when that provider is registered on
the computer. For a connection that stores no provider of its own, the check
box shows the computer's default provider.
When the computer has no DataProvider value, the Settings App, the Import
Wizard, the report tools, and some other desktop tools use SQLOLEDB. In the
Connection Manager of the Settings App and the Import Wizard, Enable TLS 1.2
support is then cleared for a connection that stores no provider until you
select it. The rest of the product's components use MSOLEDBSQL19 when that
provider is registered on the computer, otherwise MSOLEDBSQL.
With the MSOLEDBSQL19 provider, the product adds
Use Encryption for Data=False to the connection string unless the
ConnectionStringParams value under the same registry key sets that
parameter.
The product installers install Microsoft OLE DB Driver 19 for SQL Server,
version 19.2, silently after the main installation when neither version 18
nor version 19 of the driver is installed and the MSOLEDBSQL provider is not
registered on the computer. The Microsoft OLE DB Driver
for SQL Server, msoledbsql_19.2.0.0_x64.msi, is in the Redist folder of
the installation package, and you can also install it from there by hand.
Import the key in other tools
In the Automation Server Manager
The Automation Server Manager opens from the Alloy Control Panel. Its Connection group, "Specify how the Automation Server connects to the database.", shows Key: (the key name, or N/A), Import Key..., SQL Server:, and Database:.
- In the Connection group, click Import Key....
- Import the key in the Access Key Import window. The manager registers the key and sets it on the service connection. SQL Server: and Database: are set from the key.
The Database: list offers the server's databases of the current version. SQL Server: is unavailable while no key is stored, and Database: also while the server is blank. When no key is stored at start-up, or a legacy connection does not open, the manager shows "Unable to find a valid Database Access Key. Please import your Database Access Key before configuring the Automation Server." and opens the import.
In the Inventory Server Manager
The Inventory Server Manager opens from the Alloy Control Panel. The key it takes must carry a credential that reaches an Alloy Discovery database, not the Alloy Navigator one. Its Connection group shows Key:, SQL Server:, and Database:, with Import Key... and Test Connection. The form has no user name or password field.
- In the Connection group, click Import Key....
- Import the key in the Access Key Import window. The manager registers the key at once and makes it the service connection's key in the form.
- In Database:, pick the Alloy Discovery database. The list offers only the Alloy Discovery databases on the server whose version is the manager's own, read with the key's credential.
- Click Apply or OK. Test Connection, Start, and Restart also save the settings. The service connection names the key only once the settings are saved.
At start-up the manager shows "Unable to find a valid Database Access Key. Please import your Database Access Key before configuring the Inventory Server." and opens the Access Key Import window in two cases: the registry holds neither a key for the service connection nor a legacy connection of an earlier version, or it holds only a legacy connection and that connection does not open. A connection that names a key and does not open gets no such prompt.
To set a key that is already registered without opening the window, run:
DataCollectorMngr.exe init key:<key name>
The command exits with code 3 when no key results.
In the Web Configuration tool
To point an existing web instance at a database, choose Configure > Database in the instance's context menu. The run opens on the Database page, ends on Ready to Apply Settings, and restarts the web application when it applies the settings. Configure > Full also shows the web pages; Configure > Web leaves the Database page out.
The Database page reads "Specify how the web application connects to the database." and holds Key:, SQL Server:, Database:, and Import Key...:
- Key: lists the registered keys of the tool's own product. Choosing a key fills SQL Server: and Database: from it, and the connection also takes the key's credential.
- SQL Server: and Database: stay editable, so you can type a network address that differs from the key's. Typing a different server clears Database:.
- Next is available only when all three fields are filled, and it opens the connection. The tool selects the key you used last time when you run it again.
- Import Key... opens the tool's own copy of the Access Key Import window. The tool registers an imported key the same way and selects it in Key:.
The tool's Access Key Import window differs in two ways:
- Import stays unavailable until the content decodes to a name, a server, and a database.
- Load from file... reads only the key line of a
.regfile, and refuses a key made for another product with "The Database Access Key you are attempting to import is for <product A> only. Select a key for <product B>."
In the Alloy Discovery Synchronization window of the Settings App
In the Settings App's Alloy Discovery Synchronization window, the Alloy Discovery database group holds This access key: and Import Key.... A key imported there is not registered on the computer: it is saved with the synchronization job in the Alloy Navigator database.
Connection errors
These messages appear in the administrative tools, such as the Settings App, when a connection does not open:
- "Cannot open the database connection." over "The OLE DB provider <provider>
is missing or installed incorrectly.": the OLE DB provider that the
connection asks for is missing or not registered on the computer. The message offers OK and
Ignore, and Help where help is available. Ignore switches the
rest of the session to the
SQLOLEDBprovider, whatever provider the connection stores. When the missing provider isMSOLEDBSQL19, the provider of Microsoft OLE DB Driver 19 for SQL Server, install the driver from theRedistfolder of the installation package; see TLS 1.2 support. - "Database connection failed. Please check with your <product> administrator that your Database Access Key is valid.": a connection opened through a Database Access Key failed with an error from SQL Server. Click Details to see the underlying error.
- When the Windows account that opens the connection lacks the right to log on using the network logon type, and the tool's help is available, the error shows OK and Help. In a tool that signed in through the Log in window, and for the service connection, the message then begins "Cannot log in to" and says that the Windows account used in the Database Access Key lacks the right to log on using the network logon type. Otherwise, it shows the error's own text. To fix it, see Allow the Database Account to log on over the network.
The Settings App, the Automation Server Manager, and the Import Wizard also check the database version at sign-in, and show an error when the database's version is not their own. In the Settings App and the Automation Server Manager, the error names both versions and the connection is not opened. The check's messages:
- A database of a lower version gives a message that begins "Your database needs to be updated to be compatible with this version of Alloy Navigator."
- A database of a higher version gives a message that begins "Your Alloy Navigator installation needs to be updated for compatibility with this database."
- A database marked as under upgrade gives the upgrade error recorded for it, which begins "The database '<database>' has been corrupted due to an upgrade failure.", or, when no error was recorded, a message that begins "The database you are connecting to is under upgrade."
Allow the Database Account to log on over the network
The network logon error appears when a Database Access Key uses Windows Authentication and the Windows account it names, the Database Account, does not have the right to access, from the network, the computer that opens the connection. The error message names the account. Granting the right is a Windows setting made outside Alloy Navigator. A Database Account with Windows Authentication needs this right on every computer that works with Alloy Navigator.
On the computer where the error appears:
- In the Run dialog box, type
gpedit.mscto open the Local Group Policy Editor. - Go to Computer Configuration > Windows Settings > Security Settings > Local Policies > User Rights Assignment.
- Double-click Deny access to this computer from the network, and make sure that the Database Account is not on the list, either by itself or through a group. If it is, remove the account from the list, or from the group that puts it there. This policy takes precedence over Access this computer from the network for an account that both policies cover.
- If the error persists, double-click Access this computer from the network and add the Database Account to the list.
The change needs no restart of the computer. When a policy's setting is unavailable in the Local Group Policy Editor, a Group Policy Object controls it: make the change in that Group Policy Object, whose settings overwrite the local ones at the next Group Policy update. To avoid changing the policy on every computer, you can add the Database Account to a group that already has the Access this computer from the network right.
For more information, see the Microsoft articles Access this computer from the network and Deny access to this computer from the network.
Diagnose a computer that cannot connect to the SQL Server
When a computer cannot reach the SQL Server instance that hosts the Alloy Navigator database, the connection fails with SQL Server errors such as "SQL Server does not exist" or "Error Locating Server/Instance Specified". The cause lies between the computer and the instance. These checks, made in Windows and SQL Server outside Alloy Navigator, resolve most such problems.
On the computer that hosts SQL Server:
- In SQL Server Configuration Manager, select SQL Server Services and
find the instance. SQL Server (MSSQLSERVER) is a default instance,
reached by the computer name. SQL Server (<instance name>) is a
named instance, reached as
<computer name>\<instance name>. Note the computer's IPv4 address as well. - Under SQL Server Network Configuration, select the instance and make sure that TCP/IP is enabled. If you enable it, restart the instance under SQL Server Services. See Enable or disable a server network protocol.
- In Windows Defender Firewall with Advanced Security, add an inbound rule that allows TCP connections to the instance's port: 1433 for a default instance, or the port the instance listens on. Named instances and SQL Server Express use dynamic ports: either set a static port for the instance in SQL Server Configuration Manager, or allow the SQL Server program instead of a port. See Configure Windows Firewall for Database Engine access.
- For a named instance, make sure that the SQL Server Browser service is running and that UDP port 1434 is open in the firewall. A default instance does not need SQL Server Browser. See SQL Server Browser service.
On the computer that cannot connect:
- Ping the SQL Server computer by its name and by its IPv4 address. If ping returns "Destination host unreachable" or "Request timed out", work with your network administrator to fix the network.
- Test the instance's TCP port with PowerShell, for example
Test-NetConnection -ComputerName sqlserver.example.com -Port 1433. Replace the server and port with your instance's values, and checkTcpTestSucceededin the result. If it is false, check the SQL Server protocol, listening port, and firewall settings again. See Microsoft's Test-NetConnection reference. - Check the connection in Alloy Navigator: in the Log in window of the Settings App or the Import Wizard, click Manage Connections..., review the connection's key, SQL Server, database, and technician account, and click Test Connection; see Create or edit a connection. The Database Account of the key must have a login in the SQL Server instance with access to the database.
- If the problem persists, connect with SQL Server Management Studio, in
this order:
<IP address>,<port>; the IP address alone for a default instance, or<IP address>\<instance name>for a named one;tcp:<computer name>ortcp:<computer name>\<instance name>; and finally the name withouttcp:. The first form that fails points to the cause, in the same order: the port, TCP/IP, or the firewall; SQL Server Browser or UDP port 1434 for a named instance, or, for a default instance, a port other than 1433, which must then be given as<server>,<port>; name resolution; or a client that tries another protocol, such as named pipes, before TCP/IP. See Fix network-related or instance-specific errors in SQL Server.
If the configuration is correct and the problem persists, contact Alloy Software support; see Before you escalate to support.