How to disable a remote server setup (Transact-SQL)
To disable a remote server setup
- Run the following code on the second server running Microsoft® SQL Server™.
EXEC sp_remoteoption ServerName1,sa, sa, trusted, false EXEC sp_dropremotelogin ServerName1, sa, sa RECONFIGURE GO EXEC sp_configure 'remote access', 0 EXEC sp_dropserver ServerName1 EXEC sp_dropserver ServerName2 RECONFIGURE GO
- Stop and restart the second SQL Server.
- Run the following code on the first SQL Server:
EXEC sp_configure 'remote access', 0 EXEC sp_dropserver ServerName2 EXEC sp_dropserver ServerName1 RECONFIGURE GO
- Stop and restart the first SQL Server.