SQL Server name error when installing SCCM 1902

Scenario:
Recently I was building SCCM Current Branch 1902 in my lab and while installing Primary Site server I ran into below error at SQL database configuration step. This error indicates that SQL Server hostname is different than it has in the SQL server’s master database. Later I realized that this error is occurring because I changed hostname of the machine after installing SQL Server 2017 on this machine, so I went ahead and updated correct hostname in the master database.



Troubleshooting and Resolution:
1. Reviewed the SCCM installation log file (ConfigMgrSetup.log) for more information and it had the following error logs.

——————————————————————————————————————–
INFO: Starting InstallDatabase()  $$<Configuration Manager Setup><05-31-2019 11:02:39.394+00><thread=7892 (0x1ED4)>
INFO: SQL Connection succeeded. Connection: SCCMSRV.CLOUDMEGH.IN MASTER, Type: Secure  $$<Configuration Manager Setup><05-31-2019 11:02:39.407+00><thread=7892
INFO: Getting SQL’s server name from sys.servers on SCCMSRV.cloudmegh.in.  $$<Configuration Manager Setup><05-31-2019 11:02:39.421+00><thread=7892 (0x1ED4)>
ERROR: SQL server’s Name ‘[EC2AMAZ-8CC58VA]’ in sys.servers does not match with the SQL server name ‘[SCCMSRV]’ specified during setup. Please rename the SQL server name using sp_dropserver and sp_addserver and rerun setup.  $$<Configuration Manager Setup><05-31-2019 11:02:39.487+00><thread=7892 (0x1ED4)>
ERROR: The SQL Server name verification with Name in sys.servers failed, exiting Configuration Manager setup  $$<Configuration Manager Setup><05-31-2019 11:02:39.500+00>
——————————————————————————————————————–

2. Verified from SQL Server, and indeed it was different hostname than actual hostname of that server.



3. Removed that server name running “sp_dropserver”.



4. Then added correct server name by running “sp_addserver” and restarted SQL services.



5. Now I had to run SCCM setup to first uninstall the partially installed SCCM site.






6. Then I ran the SCCM setup again and I was able to install SCCM CB 1902 in my lab successfully.

Note: This issue happened in my lab because I used prebaked Windows Amazon Machine Image (AMI) that had SQL 2017 installed and I launched an EC2 Windows instance using that AMI so my machine got default hostname assigned by AWS during instance launch.

2 thoughts on “SQL Server name error when installing SCCM 1902”

Leave a Reply

Your email address will not be published. Required fields are marked *