{"id":7861,"date":"2026-10-25T04:23:29","date_gmt":"2026-10-25T11:23:29","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/azure-sql\/?p=7861"},"modified":"2026-10-26T05:22:22","modified_gmt":"2026-10-26T12:22:22","slug":"the-paper-that-split-the-database-in-four-inside-azure-sql-database-hyperscale-aka-socrates","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/azure-sql\/the-paper-that-split-the-database-in-four-inside-azure-sql-database-hyperscale-aka-socrates\/","title":{"rendered":"The paper that split the database in four: inside Azure SQL Database Hyperscale, aka Socrates"},"content":{"rendered":"<p><span style=\"font-family: arial, helvetica, sans-serif;\"><em>Under the Hood: The Research Behind Microsoft SQL, part 1<\/em><\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">The Microsoft SQL team is always innovating. They do this in day-to-day efforts, but there are also brand new efforts that are constantly being explored, investigated, tested, and researched. Our engineering team partners closely with MSR (Microsoft Research) on some of these efforts. The team writes papers, submits these papers to conferences, and generally gets high recognition for their ingenuity in the databases and cloud space.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">One thing I\u2019ve been thinking about recently is how little I actually have read the papers being written, and what scenarios they unlock for customers &#8211; could be security, performance, or availability (you know, the \u201cmeat and potatoes\u201d of SQL Server, as Bob Ward would say).<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">I\u2019m starting a new blog series where I read some of the papers over the past 5-10 years, and then try to break them down so we all understand. You should know that I am not a database expert, but I love learning and this seemed like a great way to learn and share.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">So enough preamble. I thought it would be fitting to start with the paper about Socrates, which was the codename for <a href=\"https:\/\/learn.microsoft.com\/azure\/azure-sql\/database\/service-tier-hyperscale\">Azure SQL Database Hyperscale<\/a>, since we\u2019ve been talking so much about it lately (check out <a href=\"https:\/\/aka.ms\/azuresqlfoundationseries\">https:\/\/aka.ms\/azuresqlfoundationseries<\/a> and <a href=\"https:\/\/aka.ms\/azuresqlyt\">https:\/\/aka.ms\/azuresqlyt<\/a>). Every cloud database vendor eventually hits the same wall. Which wall is that, and how did we get around it?<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">In 2019, the Azure SQL team published how they got around the big wall called \u2018size of data operations\u2019 and \u2018horizontal plus vertical\u2019 scaling. Think about the following scenarios: A database grows past what one machine can hold, and suddenly the things you took for granted stop working. Backups take hours. Failover takes longer. Adding an active replica means copying terabytes across the network before it can serve a single query. The paper is called <a href=\"https:\/\/www.microsoft.com\/en-us\/research\/uploads\/prod\/2019\/05\/socrates.pdf\">Socrates: The New SQL Server in the Cloud<\/a>, and Socrates is the internal name for what shipped as <a href=\"https:\/\/learn.microsoft.com\/azure\/azure-sql\/database\/service-tier-hyperscale\">Azure SQL Database Hyperscale<\/a>.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">If you\u2019ve ever wondered why Hyperscale can restore a 50 TB+ database in minutes vs days, this paper will help us understand the answer.<\/span><\/p>\n<h2><a id=\"post-7861-the-problem-one-machine-four-jobs\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">The problem: one machine, four jobs<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Traditional SQL Server architecture asks a single node to do four things at once, and this applies to the Azure SQL Database Business Critical tier as well (General purpose is slightly different, but for purposes of this blog, I\u2019ll focus on BC). It processes queries. It manages the transaction log. It stores the data. It keeps the copies in sync.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">That works well until you need all four at cloud scale simultaneously, or you want to scale independently. The team was direct about it:<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">\u201cIt turns out that meeting all these requirements is not possible in the cloud using the traditional monolithic database architecture.\u201d<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">The design that came before Socrates is what still powers the Business Critical service tier, and it works like this: a database runs as a small cluster of 3-4 replicas, very similar to an always-on availability group. One primary accepts reads and writes, and three secondaries stay current by replaying the primary\u2019s transaction log. Each replica is a complete, self-sufficient SQL Server instance with its own local SSD holding a full copy of the data. If the primary fails, one of the secondaries is promoted, and because it already has everything, it can take over quickly.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">That symmetry is what makes it fast, and also what caps it. Every replica needs local storage big enough for the entire database, so a database can never outgrow a single machine\u2019s disk. Backups run on the primary and compete with live traffic for I\/O. Adding a replica means seeding a fresh full copy across the network first. Every one of those operations scales with data size, so the largest database the service could support set the cost of routine operations for everyone. The practical ceiling was around 4 TB.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">For the rest of this post, I\u2019ll call it the full-replica architecture.<\/span><\/p>\n<h2><a id=\"post-7861-what-they-built\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">What they built<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Socrates separates the database into four tiers, each doing one job well.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Compute nodes<\/strong> run the query processor. One primary handles reads and writes. Secondaries serve read-only queries. Critically, a compute node doesn\u2019t need to store a full copy of the database. It keeps data close through two layers of cache: the in-memory buffer pool and a smart local SSD cache called RBPEX (Resilient Buffer Pool Extension). That SSD cache extends the buffer pool beyond memory, so more reads can be served locally instead of making a trip to a page server.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>The XLOG service<\/strong> owns the transaction log. When the primary commits, log blocks land in a fast SSD \u201clanding zone,\u201d and XLOG fans them out to everyone who needs them. This is where durability lives. One of the key decisions is there is \u201cpush\u201d of the log unlike AG technology used in BC. Everyone \u201cpulls\u201d from the log and only apply log records for pages in their caches.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Page servers<\/strong> own the data. Each one holds a slice of the database, applies log records to keep its slice current, and serves individual pages on request. These are, for the most part, full covering, which means any page not found on compute node can be fetched here. This is how a new compute can spin up so quickly, there\u2019s no seeding or data copy, just pointing.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>XStore<\/strong>, built on Azure Storage, holds the long-term durable copy and handles backups through snapshots. It also contains destaged log for longer retention.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">The connective tissue is a call called GetPage@LSN. A compute node (whether it\u2019s a primary or a replica) that needs a page it doesn\u2019t have in cache asks a page server for that specific page, at a specific point in the log. It\u2019s a small idea with large consequences, \u201cthe Page Server waits until it has applied log up to that LSN and then returns the page, which guarantees the replica never sees a stale page.\u201d<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><img decoding=\"async\" class=\"alignnone wp-image-7862\" src=\"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-content\/uploads\/sites\/56\/2026\/10\/word-image-7861-1.webp\" alt=\"Source: Figure 2 from Socrates: The New SQL Server in the Cloud (SIGMOD 2019).\" width=\"735\" height=\"765\" srcset=\"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-content\/uploads\/sites\/56\/2026\/10\/word-image-7861-1.webp 735w, https:\/\/devblogs.microsoft.com\/azure-sql\/wp-content\/uploads\/sites\/56\/2026\/10\/word-image-7861-1-288x300.webp 288w, https:\/\/devblogs.microsoft.com\/azure-sql\/wp-content\/uploads\/sites\/56\/2026\/10\/word-image-7861-1-24x24.webp 24w\" sizes=\"(max-width: 735px) 100vw, 735px\" \/><\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><em>Source: Figure 2 from Socrates: The New SQL Server in the Cloud (SIGMOD 2019).<\/em><\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">The line I keep coming back to:<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">\u201cSeparating the log and storage tiers separates durability (implemented by the log) and availability (implemented by the storage tier).\u201d<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Once those two concerns are separate, backup stops being a compute problem. Restore stops being a copy operation. Adding a replica stops being proportional to database size.<\/span><\/p>\n<h2><a id=\"post-7861-what-it-bought\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">What it bought<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">The paper\u2019s own before-and-after table is the clearest summary of the payoff:<\/span><\/p>\n<table>\n<thead>\n<tr>\n<th><\/th>\n<th><span style=\"font-family: arial, helvetica, sans-serif;\">Full-replica architecture (before)<\/span><\/th>\n<th><span style=\"font-family: arial, helvetica, sans-serif;\">Socrates<\/span><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Max database size<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">4 TB<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">100 TB<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Availability<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">99.99%<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">99.999%<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Scale operations<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">O(data)<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">O(1)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Storage copies<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">4\u00d7<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">2\u00d7<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Commit latency<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">3 ms<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">under 0.5 ms<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">Log throughput<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">50 MB\/s<\/span><\/td>\n<td><span style=\"font-family: arial, helvetica, sans-serif;\">100+ MB\/s<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Two things stand out. Scale operations went from O(data) to O(1). Adding a read replica no longer depends on how big your database is. And storage overhead was roughly cut in half, from four copies to two (note that we also replicate each XStore blob for each replica for resiliency).<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Caching held up better than you\u2019d expect. On that 1 TB database, a cache covering 22% of the data still served 52% of reads. On a 30 TB TPC-E database, a cache covering just 1% of the data served 32% of reads. Real workloads are skewed, and the architecture leans on that.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Under update-heavy load, Socrates pushed 89.8 MB\/s of log versus 56.9 MB\/s for the full-replica architecture, roughly 58% higher, because backups moved to XStore snapshots instead of competing with the log.<\/span><\/p>\n<h2><a id=\"post-7861-where-you-see-this-today\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">Where you see this today<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">If you run Hyperscale, you\u2019re running the descendants of this design.<\/span><\/p>\n<ul>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Backups are near-instant<\/strong> and don\u2019t consume your compute, because they\u2019re snapshot-based in the storage tier.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Restore time is largely independent of database size.<\/strong> Restoring 50 TB is not 50 times harder than restoring 1 TB.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Read replicas come up fast<\/strong>, which is why <a href=\"https:\/\/learn.microsoft.com\/azure\/azure-sql\/database\/service-tier-hyperscale-replicas\">named replicas<\/a> work as a pattern for isolating reporting or AI workloads from your transactional traffic. This is what you\u2019ve heard me call \u201cread scale on the fly\u201d.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Storage grows automatically<\/strong> up to 128 TB, without you pre-provisioning it.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Log throughput now reaches 150 MB\/s<\/strong>, up from the 100+ MB\/s reported when the paper was published.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Continuous priming<\/strong> is a new concept available that keeps the hottest pages in caches for replicas.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">There\u2019s one more line from the paper worth reading as a design philosophy:<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">\u201cEvery database function that can be offloaded to storage relieves the Primary Compute node and the log, the two bottlenecks of the system.\u201d<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Seven years later, that sentence still describes how the team makes decisions.<\/span><\/p>\n<h2><a id=\"post-7861-Xa8f20b1cf4718855b9095af3e399b7bc4b5327f\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">Why this matters if you\u2019re choosing a database<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">Developers evaluating databases in 2026 tend to sort them into \u201cmodern, cloud-native\u201d and \u201cthe relational one my company already has.\u201d Socrates is a useful counterexample. Compute-storage separation, log as a service, and page-level remote fetch are the same architectural moves that show up in systems marketed as cloud-native today. Microsoft SQL got there in production, at scale, and kept full T-SQL compatibility while doing it.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">That last part is the interesting trade. Your existing application, your existing queries, and your existing tooling still work. The architecture underneath changed completely.<\/span><\/p>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\">And, completely unrelated to this paper &#8211; I have to call out a few other things about Hyperscale today:<\/span><\/p>\n<ul>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\">It has no separate software to acquire, purchase, or maintain. We priced it at open source.<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\">This architecture is great for large databases but it also works for small databases. It starts at 10GB. You can, as Bob Ward says, \u201cstart here, stay here.\u201d<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\">We just announced serverless auto-pause and resume support in public preview. This means you can make it scale to zero when inactive, if you want.<\/span><\/li>\n<\/ul>\n<h2><a id=\"post-7861-credits\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">Credits<\/span><\/h2>\n<p><span style=\"font-family: arial, helvetica, sans-serif;\"><em>Socrates: The New SQL Server in the Cloud<\/em> was written by Panagiotis Antonopoulos, Alex Budovski, Cristian Diaconu, Alejandro Hernandez Saenz, Jack Hu, Hanuma Kodavalla, Donald Kossmann, Sandeep Lingam, Umar Farooq Minhas, Naveen Prakash, Vijendra Purohit, Hugh Qu, Chaitanya Sreenivas Ravella, Krystyna Reisteter, Sheetal Shrotri, Dixin Tang, and Vikram Wakade (Microsoft Azure and Microsoft Research).<\/span><\/p>\n<h2><a id=\"post-7861-next-steps\"><\/a><span style=\"font-family: arial, helvetica, sans-serif;\">Next steps<\/span><\/h2>\n<ul>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Read the paper<\/strong>: <a href=\"https:\/\/www.microsoft.com\/en-us\/research\/uploads\/prod\/2019\/05\/socrates.pdf\">Socrates: The New SQL Server in the Cloud<\/a> (SIGMOD 2019)<\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Understand the architecture<\/strong>: <a href=\"https:\/\/learn.microsoft.com\/azure\/azure-sql\/database\/hyperscale-architecture\">Hyperscale distributed functions architecture<\/a><\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Try it<\/strong>: <a href=\"https:\/\/learn.microsoft.com\/azure\/azure-sql\/database\/hyperscale-database-create-quickstart\">Create a Hyperscale database<\/a><\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Watch the foundations series:<\/strong> <a href=\"https:\/\/aka.ms\/azuresqlfoundationseries\">https:\/\/aka.ms\/azuresqlfoundationseries<\/a><\/span><\/li>\n<li><span style=\"font-family: arial, helvetica, sans-serif;\"><strong>Next in this series<\/strong>: Constant Time Recovery, and why a 12-hour recovery became a 3-minute one<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Under the Hood: The Research Behind Microsoft SQL, part 1 The Microsoft SQL team is always innovating. They do this in day-to-day efforts, but there are also brand new efforts that are constantly being explored, investigated, tested, and researched. Our engineering team partners closely with MSR (Microsoft Research) on some of these efforts. The team [&hellip;]<\/p>\n","protected":false},"author":12403,"featured_media":81,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1,594],"tags":[510,752],"class_list":["post-7861","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-azure-sql","category-hyperscale","tag-azure-sql-database","tag-paper"],"acf":[],"blog_post_summary":"<p>Under the Hood: The Research Behind Microsoft SQL, part 1 The Microsoft SQL team is always innovating. They do this in day-to-day efforts, but there are also brand new efforts that are constantly being explored, investigated, tested, and researched. Our engineering team partners closely with MSR (Microsoft Research) on some of these efforts. The team [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/posts\/7861","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/users\/12403"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/comments?post=7861"}],"version-history":[{"count":1,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/posts\/7861\/revisions"}],"predecessor-version":[{"id":7865,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/posts\/7861\/revisions\/7865"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/media\/81"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/media?parent=7861"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/categories?post=7861"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azure-sql\/wp-json\/wp\/v2\/tags?post=7861"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}