Here's the imaginary setup that'll be referenced in the steps below:
- Windows 2003 x64 R2 SP2 (should be identical for 32bit)
- SQL 2005 x64 (Std or Enterprise) SP2 Cumulative Update 9
- Veritas Storage Foundations HA 4.3 MP2 is used for clustering
- Server is part of a Windows 2003 Domain
- The domain has a properly configured CA and certificate requests are approved automatically. CA is CA01.drew.net
- Domain name is drew.net (drewnet)
- SQL Server service account is a domain account: drewnet\sqlAdminX
- SQL server cluster node hostnames are SQL1.drew.net and SQL2.drew.net
- SQL server cluster virtual name is SQLCluster.drew.net
- Domain account for Veritas Cluster Service is drewnet\sqlCsvc
- drewnet\sqlAdminX is granted NOT an admin on any of the cluster nodes
- You are an admin on all cluster nodes
- SQL has been installed identically on both nodes and the Veritas cluster is working 100% (just without SSL certs for encrypted traffic)
- Only one instance of SQL is installed and it is a default installation on port 1433
- Connect to SQL1.drew.net
- Connect to the CA request page at http://CA01.drew.net/certsrv
- Follow the path to make a custom advanced certificate request. See here for more info.
- Request a "Web Server" certificate with a name field of SQLCluster.drew.net, ensure the private key is exportable, and store the certificate in the local computer store.
- Start->Run: mmc
- Add the Certificate snap-in for the local computer and verify there is a trusted certificate named SQLCluster.drew.net there that has a details tab that indicates "Server Authentication (1.3.6.1.5.5.7.3.1)" in the "Enhanced Usage" section.
- Scroll to the bottom of the details and highlight all the text in the "Thumbprint" section. Copy this (ctrl-c).
- Start->Run: Notepad
- Paste the data you just copied and remove all the spaces. Save this file on your desktop.
- Open the Veritas Cluster Manager GUI and connect to the cluster.
- Freeze the SQL service group you're working on (temporary)
- Download the WinHttpCertCfg.exe utility from Microsoft if you don't already have it.
- Install the utility, open a command prompt and navigate to your installation path.
- Run the following command:
winhttpcertcfg.exe -g -c LOCAL_MACHINE\MY -s "SQLCluster.drew.net" -a "drewnet\sqlAdminX"
- If you got a success message, move on. Otherwise troubleshoot!
- Start->Run: regedit
- Navigate to HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLServer\SuperSocketNetLib and open the "Certificate" entry.
- Copy & Paste the thumbprint value you saved earlier.
- Restart MS SQL Server any way you see fit.
- If your server starts properly that's a very good sign. Connect to SQL and view the current log for the line "The certificate was loaded successfully"- You've done it!!
- You can now configure the various options like "force encryption" via SQL Server Configuration Manager if you want now.
- In the certificates snap in right-click the SQLCluster.drew.net certificate and choose export.
- Follow the wizard- be sure to export the private key and assign a password you can remember for a while. Save the .pfx file somewhere easy to get to.
- Connect to SQL2.drew.net
- Copy the exported .pfx file locally
- Start->Run: mmc
- Add the local computer certificate snap-in again.
- Double-click the certificate copied locally, then choose "Install certificate"
- Enter the password you just used when exporting the key.
- Verify that the certificate shows up in the personal folder of the local system and that it's valid.
- Again, run the winhttpcertcfg command from above on this node.
- Back on SQL1.drew.net in the Veritas Cluster Manager GUI Unfreeze the SQL service group.
- "Switch" the service group from SQL1.drew.net to SQL2.drew.net
- If it starts on the other node you're done! VCS has replicated the registry change you made and the certificate was loaded successfully.
- Delete the exported .pfx file and the copy you made.
No comments:
Post a Comment