Configuring the KDC
On this page
To authenticate users with the Kerberos tickets, SingleStore must be provided with a service principal name (SPN) stored in a keytab file.
Your SingleStore deployment environment may affect the way your SPNs and keytab files are generated.
The following sections describe how to create an SPN and keytab file for KDC servers running on Linux/Unix and Windows.
Creating a Service Principal Name and Keytab File
To create an SPN for SingleStore, you must have sufficient permissions to access the KDC server’s terminal and to create new SPNs.
Note
A keytab file is a credential that must be handled in a secure manner.
Unix Kerberos KDC (MIT or Heimdal)
The following steps use the kadmin
command-line interface to create an SPN and keytab file on a Linux/Unix-based KDC server.
Run the following command to create the SPN for SingleStore, replacing host.
with the fully-qualified domain name for the host.
kadmin -q "addprinc -randkey memsql/host.domain.com"
You can verify that the SPN was created successfully by running the following getprinc
command.
kadmin -q "getprinc memsql/host.domain.com"
After the SingleStore SPN has been created, create the keytab file./path/to/memsql.
with the desired output path, and host.
with the fully-qualified domain name for the host.
kadmin -q "ktadd -k /path/to/memsql.keytab memsql/host.domain.com"
Note the output path for the keytab file, as you will need to copy it to SingleStore aggregator nodes in future steps.
You can verify that the keytab file was created successfully by running the ktutil
command.
ktutil
At the ktutil
prompt, enter the path to the keytab file you just created and list its contents.
ktutil: read_kt /path/to/memsql.keytab
ktutil: list
If the keytab file was successfully added, output similar to the following will be displayed.
slot KVNO Principal
---- ---- ---------------------------------------------------------------------
1 3 memsql/host.domain.com@DOMAIN.COM
2 3 memsql/host.domain.com@DOMAIN.COM
Note the Key Version Number (KVNO
) value.
Windows Active Directory KDC
The following steps use ktpass.
Run the following command in a new command-line window with Administrator permissions, replacing any placeholder values with your own.
ktpass.
where:
-
host.
is the fully-qualified domain name for the hostdomain. com@DOMAIN. com -
memsqluser
is the name of the Active Directory user object to bind with the SingleStore SPN
Last modified: April 26, 2023