RDS 2012 R2 – Renaming RD Connection Broker – Part III

Hello World,

In our Part I of this post series, we have decided to check what happens when you rename the Connection Broker server.  As expected, renaming the server is not really recommended. Renaming the connection broker brings the RDS Topology down.

In part II, we have described the standard approach to restore your RDS Topology.  Basically, you need to perform a remove/re-install operation and re-configure your infrastructure.

In this part, we want to investigate a different approach to restore the RDS Topology. As you know, the RDS topology is stored in a SQL Database.  In this post, we will see if updating the database with the new server name can allow us to restore the RDS topology and have full functionality back after the rename operation…

Disclaimer :  

This post series is based on some experimental and (possibly)  non supported actions so please use the following information at your own risk !!!!  We will not be liable for any errors,omissions,problems,damages‚Ķarising from using this information.  All information here is provided AS-IS.

Connecting to the RDS SQL Database

Again, let’s assume that you have installed all the roles on a single Server (RDWeb,RDHost and RD Connection broker).  Let’s assume also that we have changed the name of the server (from NEWQRDS to DBRDS).  After the name change, if you try to open the RDMS console, you will end up with the known error now, “old” server name must be added to the pool…..

REname_Broker_18

Click on Picture for Better Resolution

Now, instead of re-installing the roles, we will try to access the sql database hosting the rds topology and make changes inside. To access the RDS SQL database, we have installed the SQL Studio management tool on the RD Connection broker Server.  Because RDS is using the Windows Internal database, when trying to connection you have to pass the following string as server name

\\.\pipe\MICROSOFT##WID\tsql\query

REname_Broker_19

Click on Picture for Better Resolution

If everything is ok, you can navigate to the RDCMS database and you can see the tables used by the RDS application

REname_Broker_20

Click on Picture for Better Resolution

Updating the RDS SQL Database

If you look inside one of the table, you will see that indeed, the server name information is stored in the Database.  We now simply needs to go through all the tables and find/replace the old server name with the new name

REname_Broker_21

Click on Picture for Better Resolution

If you open the rds.server table, you can find the name of the server.  In the screenshot, we have replaced the old name with the new name

REname_Broker_22

Click on Picture for Better Resolution

We have done the same on the rds.ConnectionBroker table (as shown in the following screenshot)

REname_Broker_23

Click on Picture for Better Resolution

Changing information in these two tables provides us already access to the RDMS console (just like before the rename operation)

REname_Broker_24

Click on Picture for Better Resolution

However, to be sure to have full functionality of the RDS Infrastructure, we have checked all the tables in the SQL database. Each time we have found the old server name, we have replaced it with the new name

As you can see, we have modified the following table

rds.rdcbConfig

REname_Broker_25

Click on Picture for Better Resolution

rds.target

REname_Broker_26

Click on Picture for Better Resolution

rds.Environment

REname_Broker_27

Click on Picture for Better Resolution

rds.DeploymentSettings

REname_Broker_28

Click on Picture for Better Resolution

Other issue

After updating the database, we have been able to access the RDMS console and perform the necessary operation needed.  At this stage, we have published new remoteapp and tried to access them via the Web page.  Ok, at this stage, we found out a small issue again.

None of the published apps were displayed on the web page.  We went back on the SQL database to ensure that all instances of the old server name were removed.  This was indeed the case….

After some thoughts, the problem might be coming from the web server. We opened the inetmgr console and navigated to the Virtual Directory RDWeb.  We have clicked on the mid pane on the application settings…and there we have seen again instances of the old server name.

REname_Broker_29

Click on Picture for Better Resolution

Replacing the old server name with the new server name fixed our issue. We were able to access and launch the remoteapp published application through the web page

Final Notes

As you have seen, it’s really not recommended to rename your Connection broker server within your rds infrastructure.  In these posts, we have seen what happens when you rename the connection broker server when a Quick Deploy configuration has been selected.  When you rename your Connection broker server, you basically loosing your RDS Topology.

To restore your RDS Topology, you have the recommended way which consist of removing/re-install the RDS Roles you have. This assume that you have documented your setup.  The other option (which is probably not supported by Microsoft) is to access the RDS Topology database (stored on the connection broker) and update the server name within the tables of the database.

We have been able to restore the RDMS access and the RDS functionalities by updating the SQL database when a single server RDS installation was performed.  If you have a complex  RDS topology (multiple RDS Server roles and HA Broker configuration), I do not know if updating the database would work……. So far, we have simply renamed the connection broker, what happens if we rename other RDS Server roles…..  I do not know….maybe we will investigate further and see how far we can go with these actions…

I hope you enjoyed this post….

Till next time

See ya

 

Leave a Reply