Evenly Spread WebApp DB Connections to SQL Server VMs - azure

I'm in the process of migrating an existing website into Azure for a client. The current architecture is 4 web vm's mated to 4 sql server vms. One web vm per sql server vm. Complexity and cost is prohibiting us from migrating the sql server vm's into azure sql servers. These are read only databases and use log shipping to keep them synced.
I have easily published the asp.net application to an azure web app. My question is, how do I evenly distribute the web app instances to the 4 sql server vm's?
Depending on hourly traffic, I can see anywhere from 2 to 8 web app instances running at any given time. How can I evenly distribute the load to the 4 database vm's?

Depending on how you setup your environment you could put an Azure Internal Load Balancer (ILB) in place to load balance TCP 1433 across the four back-end SQL Database Servers.
You might need to tweak the distribution mode, but I'd run it first to see what the performance is like. If the Database is relatively static perhaps you could even consider using a VM Scale Set to scale out SQL based on load.

Related

PowerBI On-Premises Data Gateway through a VM for customers?

I work in a small company and we develop PowerBI dashboards for a few clients. Data sources tend to change with each client from MySQL, MariaDB, SQL Server, Excel etc. Most clients want to setup scheduled refreshes but in order to do that we need a Data Gateway. So far i've used my machine as a gateway but that requires my computer to be on all the time which is not ideal. Since our clients data is usually stored in their own networks I believe we need an enterprise data gateway to manage all those scheduled refreshes for our current and future projects.
We don't have any physical on prem infrastructure, most of the company's developemnts are managed through AWS linux cloud servers. From what I've read a possible solution is to have a VM running 24/7 with the enterprise data gateway installed, although this seems a bit expensive taking into consideration Azure VM prices. Is there any other solution to my situation or is a VM the only path I can take?
There is no other option available, On prem data gateway requires installation and configuration to connect your data sources to powerBI, for this we require onprem machine or a VM in azure.
As you are aware the recommended machine configuration is:
An 8-core CPU
8 GB of memory
A 64-bit version of Windows 8 or Server 2012 R2 or later
Solid-state drive (SSD) storage for spooling.
If in case, your resources are running in azure you can use vnet data gateway,It doesn’t require any installation Create virtual network data gateways

Azure - Migration from on-premises to Azure

We are planning to migrate our Enterprise Application(s) from on-premises to Azure. Below are the high level details about our current infrastructure.
One Web Server hosting multiple WebSites (around 30 websites)
One Server with SSIS installed in it which processes huge data coming from multiple data sources and dumps the data into Pre-production database server explained in #3 below
Two Servers (Pre-production and Production) with SQL Server hosted in them where some jobs run on Pre-Produciton Server and the data gets replicated to the Production database server.
One Server where SSRS is hosted that uses data (and stored procedures) from Pre-Production database Server.
Could you please let us know if it is a good option to migrate the current infrastructe to PAAS? Is it really possible? We are also planning to leverage the other Azure features like Load Balancing on Web Servers and High availability on Production Database server with Active-Passive servers.
For migration scenarios, please see the following: https://azure.microsoft.com/en-us/documentation/articles/sql-database-cloud-migrate/

Connecting to azure SQL database from web role and performance.

I am new to Azure and just trying to get my head around some things.
I have a web app running locally that now connects to a windows azure SQL database. I want to move my local web app into an azure web role. I have two questions:
Do I need to change my connection string or does it just work?
I am assuming windows azure is smart enough to now know that they are both hosted on azure so each request no longer needs to go over the internet?
Cheers
Do I need to change my connection string or does it just work?
No, this is still that same connection string.
I am assuming windows azure is smart enough to now know that they are both hosted on azure so each request no longer needs to go over the internet?
You're both web site and SQL Azure database will be in Azure data center. It depends in which region your web site and database will be. If they are in the same region you'll have low latencies because it will be in the same data center, however if they are in two different regions, then at one point it has to go through connections between data centers called backbones. Even if those are special very fast connections you'll notice higher latencies.
http://www.azurespeed.com/ web site allows you to check what are the latencies between Azure data centers. This gives you a kind of idea.
Answer 1 : Since you are already connecting to SQL azure from local,
you don't need to change the connection string.
Answer 2: If both your Web Role, and SQL azure are in same Geo
Location (say SoutCentral US) then there will not be much internet
traffic, but it will use azure's network to communicate.

Windows Azure availability set

I have 2 appservers and 1 Db server running in Azure. I have created a CloudService and put the app servers in that. I have created a Availablity set for app server and added the appservers in it.
Now comes the issue, I cannot add Db server in the same availability set, because they are not in the same cloud service as appservers. So Azure may reboot the dbserver anytime and cause an outage. How to solve this.
Do I need add one more DB server and replicate the DB and add them to a new availability set?
If 1 is yes, then I should make my application smarter when the primary Db server goes down?
Any betterways?
Availability sets are limited to Virtual Machines within a single cloud service. Even if you added your database server in the same cloud service as your app servers, this still wouldn't provide HA for your DB since you can have the host OS updated, bringing your DB server down for a short time.
The only way to have HA is to run multiple DB servers. If you run SQL Server, you can set up an Always On configuration (see here for documentation). EDIT I missed the comment about you using MySQL. MySQL has HA configurations, but I haven't set one up before; you'd need to set this up across multiple VMs, and you should consider putting all nodes in an Availability Set, so that any Host OS updates will be staggered across the VMs, rather than being applied at once (and also separating the VMs across different fault domains).

Using Windows Azure SQL Database from Azure VM

Is there any performance penalty to using Windows Azure SQL Database (formerly known as SQL Azure) from within a Windows Azure VM hosted web app? I would like to know if the performance of this is any worse than using Azure SQL database from a website running on Azure reserved instance. The assumption in both scenarios is that Azure SQL Database is deployed in the same region as the app.
There should not be any difference with respect to utilization of SQL Azure
As #Igorek pointed out, there's no difference (assuming same data center) between using a Virtual Machine and a Website for accessing Windows Azure SQL. That said: One thing that may not be so obvious is that, today, Virtual Machines (and Cloud Services) support XL instances (meaning 800Mbps on the NIC) vs Websites, which are currently limited to Large reserved instances (400Mbps). So... if you're moving a considerable amount of data, you'll get better throughput with an XL Virtual Machine vs. a Large Website instance.
I realize this is an edge case, but just thought I'd throw it out there...
There may be some difference in performance which depends on the configuration on the Virtual Machine and the Website Infrastructure where the Website is Hosted.
The connections in-bound and out-bound performances depends on the load balancing which is abstracted in Azure. This relates to the infrastructure which is in place.
For instance if the VM is in Basic Tier More on VM Sizing, and the website is hosted with a higher configuration, you may get some variance in Performance.

Resources