App Service Hybrid Connections | Azure Relay | SQL Server | On-Premise to Cloud

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone in this video we are going to understand the concept of hybrid connections on azure and here we are focusing on azure app service hybrid connections with this you can connect let's say your on-premise sql server to your azure app service without having a static ip address or configuring any special firewall settings or anything like that you can directly connect your on-premise services to azure internally this uses another azure service called azure relay here i have logged into my on-premise database and i have a sample database and it only has one table it contains three rows here as you can see and here i have a asp.net application that connects that database and also i have a one controller that lists the customers now let me run this application as you can see i'm getting the data that i have in that customers table and if you look here in the database context i am connecting to my local computer now what i'm going to do is i'm going to host this application on azure i'm using an azure app service for it and then i'm going to access my on-premise database using that hosted application the first thing that i'm going to do is i'm going to create an app service on azure for that i have a script here let me copy that script one thing that you should notice here is that the sku is s1 we need a basic or standard ts as you can see to work with hybrid connections as you can see if you're going with basic we have five per plan perhaps plan and since i'm going with standard i will have 25 hybrid connections for my app service plan now my app service is ready now if i go here to my azure portal as you can see the resource group is ready inside of that resource group we have the fs plan and the app service now let me go into this app service and i'm going to download this published profile all right now i'm going to publish this i have selected the published profile here let me click finish and now i'm going to publish this application all right i have published the application to azure as you can see we're getting this error because my app service cannot access the sql server now i'm going back to my azure portal to configure the hybrid connection here we can see the app service and if i scroll down a bit we can find this tab here networking and here we have this section outbound traffic and in that we have hybrid connections if you're using a free application this won't be available since i'm using a standard we can create hybrid connections and i have option here to add a hybrid connection and i'm going to click create and let me call it sql connection and this is the name of the host that is accessible to the computer that runs hybrid connection manager since i am running the hybrid connection manager on my laptop i'm going to use that name now let me go into and this is name of my local computer and i'm going to put it here and since this is a sql server i'm going to add the default port for it internally hybrid connections use azure relay service we have to specify a service bus namespace name for creating that relay all right as you can see the hybrid connection is getting created my hybrid connection is ready now if we go into my resource group again and click refresh here we can see we have a new service a relay in my resource group relays have two supported ways of connecting and one is hybrid connections and the next one is wcf relays if you go into hybrid connections here you can see the sql connection that i have created now i'm going back to the resource group and the app service and again i'm going into networking and as you can see we have the hybrid connections on i'm going in and we have now and now we have the option to download hybrid connection manager i have downloaded that now let me install this all right as you can see i have just installed hybrid connection manager now we have two options for connecting our hybrid connection manager to azure one is we can log in from your account that you use to create the hybrid connection on azure or you can use this option here enter manually i'm going to use this one and here i'm going to hybrid connections again and i'm going to click on sql connection and here we have this connection string let me copy that and i'm going to paste it here and i'm going to click add as you can see we have the connection that we have created listed here now even if i click refresh here this status won't get updated for some reason you will have to go into the services of your computer and you'll have to find azure hybrid connection manager service and you'll have to restart it here once this is done click refresh as you can see we are connected to azure now let me go back to my browser and this website here let me click refresh and now we are getting a different error the connection was successfully established with the server if you're getting this error you should go to sql configuration manager and you should go to network configuration and protocols and here you will find tcp ip here you should enable tcp ip protocol for this server and click apply and after that you can go into sql server services and you can restart your sql server now after this is done let me try again as you can see i'm getting a response now if i go back to my sql server and let me insert a new row and if we go back to the browser now and as you can see we have successfully connected my azure app service to the sql server that is running on my on-premise environment in this video you'll learn about hybrid connections and how to configure a hybrid connection on azure how to connect your azure app service to sql server if you have any further questions or comments let me know down below and don't forget to like this video and subscribe if you learned something new today and thanks for watching
Info
Channel: Meet Kamal Today - Cloud Mastery
Views: 212
Rating: undefined out of 5
Keywords: app service hybrid connections, azure app service hybrid connection sql server, azure hybrid connections, azure hybrid connection manager, azure relay hybrid connections, hybrid connection azure, hybrid connection azure sql server, hybrid connection azure function app, hybrid connection azure not connected, relay hybrid connection azure, azure on premise hybrid, hybrid connections, azure relay, azure relay service, azure relay tutorial
Id: X_kY7BJQMik
Channel Id: undefined
Length: 6min 55sec (415 seconds)
Published: Wed Nov 10 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.