0

I know this type of question has already been asked (Difference of speed if SQL Server is on one server and website is on another, rather than both on same server), I don't know if it's applicable to my situation.

The current situation:

I have one dedicated server (Corei5 3.6ghz, 4 cores, no HT, 32 gb of ram, 120go ssd + 1tb hdd) where I host almost everything needed for the website to run (IIS, SQL server, mail server, Redis cache). The choice of putting them all together was at first to minimize the cost.

The website currently generate a good amount of traffic (arround 90 millions request on the website per day) and the database is under pressure as well (an average of 1500 requests per second).

I of course already thought about separating those 2. The cpu activity is quite high (generally between 70 and 80%).

My main question is: I'm afraid of the issues that having 2 servers can bring, especially in term of performance.

It is usually said that it's recommended to separate, but is it also the case considering the number of requests made on the database ? I'm especially scared about the network latency between the 2 servers cause I have no real control on it.

With such an amount of SQL requests, will the network latency and the bandwidth can be an issue ? Pinging between the servers I have at my hosting provider is lower than 2ms. The bandwidth is 100mb/s.

Would you think it's a good idea to separate them ?

Thanks,

Tom741
  • 1
  • No experience. But I would say that it'd be advisable. If both servers are connected to a gigabit switch, I don't see how latency and bandwith could possibly be a problem. I mean, most people still own a internet plan slower than 16 MBit/s. From what I hear, it's also a good idea to actually have a reverse proxy that serves clients from cached content (if you don't already do that). That even reduces stress on the database, if you don't have to query the database for the same information three times a second. Enough noob talk from me now. – Daniel Jan 27 '16 at 12:18
  • You might want to look into the benefits of hosting your SQL Server on a dedicated instance some more. One of the main possible issues I see with your current setup is that you don't have dedicated disks for your database. You also don't say if you allocate RAM to your SQL Server or just let it gobble up what it wants. Similarly you don't say what version of SQL Server you're using and if you have CPU Affinity set up. If you aren't well versed in how to tune your SQL Server you're better of either hiring someone who is, or at least adhering to best practices online. – Reaces Jan 27 '16 at 12:35
  • Hello, About the ram, I didn't put any limit since 32gb seems plenty for my need. Actually SQL Server consumes around 7 gb and a total of 11gb are used by the entire system. I use SQL Server 2014 Web edition. No CPU affinity has been set up. It's mainly a personal project that turns ... too well :). I'm mainly learning as I discover issues. – Tom741 Jan 28 '16 at 13:48
  • @Tom741 The issue isn't that you wont have enough RAM, it is the way that SQL Server handles memory. [It will take all your memory, and do so with the best intentions](http://www.brentozar.com/archive/2011/09/sysadmins-guide-microsoft-sql-server-memory). However if you believe you are limited by CPU usage, try [testing for it](https://www.mssqltips.com/sqlservertip/2316/how-to-identify-sql-server-cpu-bottlenecks/). – Reaces Jan 29 '16 at 08:50

1 Answers1

1

You need to find out what's the bottleneck right now, before worrying about what might become your next one.

Your question is formulated as if you have a performance problem.
But I don't see any actual numbers to back it up.

Monitor your current server for:

  • CPU
  • Memory
  • Disk usage
  • Network latency

You should focus on both general statistics, and SQL Server specific counters..
If you think that the added latency that comes from adding a second server with a network connection might be an issue try testing for it.
Simulate an environment with a higher network latency, and do a load test to see if the performance impact is measurable / a concern.

After you've done all that, you can have your answer with absolute certainty.
But I would wager a guess, and say that you'll find out that hosting your SQL Server on a dedicated machine is better for performance.
It's simply way more likely that a SQL Server is contending for memory and CPU with an IIS server and causing bad performance. Than that a network connection will cause latency issues unless you host your servers far apart with a bad connection.

Reaces
  • 5,597
  • 4
  • 38
  • 46
  • Hello, Thank you for your answer. Indeed my main fear is performance issue. The one I fight usually is "The service is unavailable." (503) error due to intermittent high load. I don't think it's because of the output bandwidth at the moment but I usually see this error when cpu is struggled. I'll try to simulate and do some test as soon as possible. – Tom741 Jan 28 '16 at 13:56