Forum Discussion
UnknownSQLDBA
May 08, 2024Copper Contributor
Registering SQLServers in SSMS v20 using Powershell
Hello I have a new VM - Windows 11, Installed SSMS V20.1 today Installed SQLServer Powershell Module. SQLServer Module version is 22.2.0 . Only 1 version installed. (Install-Module -Name SqlServe...
- May 09, 2024I have the same issue. The reason that this is happening is that SSMS v20 creates the file RegSrvr17.xml for storing the registered server groups and the cmdlet created the file RegSrvr16.xml. You can find these files at the path C:\Users\m.ntallaris(user name)\AppData\Roaming\Microsoft\SQL Server Management Studio. Unfortunately I have not find a solution to this, still searching though. An interesting fact if you install and use SSMS 19 will work perfectly, but if you install and use SSMS 18 no because this uses RegSrvr.xml. Another interesting fact is that if you search the release logs of SSMS 18 Microsoft point out that it has now this file in the AppData folder and not as a .bin (as the previous versions had) in order to all versions to have easy access to the registered servers, but in very next version Microsoft chose to rename the file...
olafhelper
May 08, 2024Bronze Contributor
UnknownSQLDBA It's easier to use "DbaTools" PowerShell CmdLet, see
- UnknownSQLDBAMay 08, 2024Copper Contributor
I tried that as well.
Add-DbaRegServer -ServerName SQLName1
Get-DbaRegisteredServer -- shows me that it is added
But when i go into SSMS, its not in the registered list. (restarted and refreshed ssms as well)