How to Configure SQL Server Windows Authentication in Linux CentOS 7 – SQL Server on Linux Tutorial
How to Configure SQL Server Windows Authentication in Linux CentOS 7 video explains all below steps
Create Active Directory Service Account for SQL Server
Setup SPN for SQL Server AG Service Account
Validating Key version Number (kvno)
Create MSSQLScv Keytab
Setting Proper Permission of Keytab
Configure SQL Server Instance to use Keytab file for kerberos Authentication
Restarting SQL server and Testing Using SSMS
Script Used in this Demo:
#Create SQL Server Service Account in Your Active Directory Domain
UserName= mssql
PasswordExpire= never
# Setting ServicePrincipalName (SPN) for SQL Server Service account on Your Domain Conroller
setspn -A MSSQLSvc/TBSLinuxNode1.Techbrothers.local:1433 mssql
# Checking KVNO (Key Version Number) number for AD Account-usually its 2
kinit mssql@TECHBROTHERS.LOCAL
kvno MSSQLSvc/TBSLinuxNode1.Techbrothers.local:1433
# Creating SQL Keytab File (AD Account with password must set this up) using ktutil
sudo ktutil
ktutil: addent -password -p MSSQLSvc/TBSLinuxNode1.Techbrothers.local:1433@TECHBROTHERS.LOCAL -k 3 -e aes256-cts-hmac-sha1-96
ktutil: addent -password -p MSSQLSvc/TBSLinuxNode1.Techbrothers.local:1433@TECHBROTHERS.LOCAL -k 3 -e rc4-hmac
ktutil: wkt /var/opt/mssql/secrets/mssql.keytab
quit
# Setting up Proper permission (ownership)
sudo chown mssql:mssql /var/opt/mssql/secrets/mssql.keytab
sudo chmod 400 /var/opt/mssql/secrets/mssql.keytab
# Configuring SQL Server to Point to KeyTab File
sudo /opt/mssql/bin/mssql-conf set network.kerberoskeytabfile /var/opt/mssql/secrets/mssql.keytab
# Restarting SQL Server Services
sudo systemctl restart mssql-server
# Connecting to SSMS and Testing Windows Authentication
centos 7