My APP CPU Billing shot up around april 22 and has stayed consistently high since then.

CTC Office 0 Reputation points
2025-05-15T21:07:04.4466667+00:00

Azure SQL Database High CPU Usage Issue Summary for Support Ticket

Core Problem

Our Azure SQL Serverless database (CTCData) is consistently consuming approximately 40 "App CPU billed" units even when completely idle, resulting in unexpectedly high costs. The database has minimal usage but is incurring charges as if it were under constant load.

Timeline and Observations

  • Around April 22, 2025, we observed a sudden jump in "App CPU billed" metrics
  • Prior to this date, the database had minimal billing
  • The memory usage consistently shows around 39-40% utilization
  • Database auto-pause is enabled but never triggers because the system appears perpetually active
  • The issue persists even when all our applications are disconnected from the database

Detailed Observations

  • Multiple persistent connections remain active at all times, primarily:
    • BackupService connections from DB00000L\WF-pv18Lj2GOGrvzPf
      • DmvCollector connections from DB00000L\WF-pv18Lj2GOGrvzPf
        • MetricsDownloader connections from DB00000L\WF-pv18Lj2GOGrvzPf
          • TdService connections running as NT AUTHORITY\SYSTEM
            • Several connections showing as "azdata" from our Azure account
            • The memory allocation remains high (39%) even when these connections are the only activity

What We've Tried

  1. Function App Management:
    • Identified and stopped an Azure Function (ctc-document-emailer) that was previously connecting to the database
      • Removed connection strings and email-related configurations from the function
      1. Network Access Restrictions:
        • Temporarily disabled public network access to block connections
          • Applied firewall rules to limit access to specific IPs
          1. Memory Management Commands (all were unsuccessful due to permissions or Azure SQL limitations):
            • Attempted to run DBCC FREEPROCCACHE
              • Attempted to run DBCC DROPCLEANBUFFERS
                • Tried ALTER DATABASE SCOPED CONFIGURATION CLEAR PROCEDURE_CACHE
                  • Tried ALTER RESOURCE GOVERNOR RECONFIGURE
                    • Attempted to disable Query Store
                    1. Database Configuration:
                      • Verified auto-pause is enabled with minimal delay
                        • Set minimum vCores to 0.5 and maximum to 1
                          • Disabled diagnostic settings where possible
                          1. System Table Maintenance:
                            • Ran EXEC sp_updatestats to update statistics

Limitations Encountered

Most traditional SQL Server memory management commands are either:

  • Not supported in Azure SQL (e.g., ALTER RESOURCE GOVERNOR)
  • Restricted even for administrator accounts
  • Do not have the expected effect on resource utilization

Impact

We're currently paying approximately $8-10 per day for a minimally used test database that should be costing closer to $2 per day if it were truly idle. This represents a 400-500% cost increase above expected rates.

Request for Support

We need assistance in determining why these background processes are consuming so much CPU and memory, and how to properly configure our database to reduce this consumption when idle. Standard management approaches have been unsuccessful, suggesting this may require backend adjustments or identification of a potential service issue. Azure SQL Database High CPU Usage Issue Summary for Support Ticket

Core Problem

Our Azure SQL Serverless database (CTCData) is consistently consuming approximately 40 "App CPU billed" units even when completely idle, resulting in unexpectedly high costs. The database has minimal usage but is incurring charges as if it were under constant load.

Timeline and Observations

  • Around April 22, 2025, we observed a sudden jump in "App CPU billed" metrics
  • Prior to this date, the database had minimal billing
  • The memory usage consistently shows around 39-40% utilization
  • Database auto-pause is enabled but never triggers because the system appears perpetually active
  • The issue persists even when all our applications are disconnected from the database

Detailed Observations

  • Multiple persistent connections remain active at all times, primarily:
    • BackupService connections from DB00000L\WF-pv18Lj2GOGrvzPf
      • DmvCollector connections from DB00000L\WF-pv18Lj2GOGrvzPf
        • MetricsDownloader connections from DB00000L\WF-pv18Lj2GOGrvzPf
          • TdService connections running as NT AUTHORITY\SYSTEM
            • Several connections showing as "azdata" from our Azure account
            • The memory allocation remains high (39%) even when these connections are the only activity

What We've Tried

  1. Function App Management:
    • Identified and stopped an Azure Function (ctc-document-emailer) that was previously connecting to the database
      • Removed connection strings and email-related configurations from the function
      1. Network Access Restrictions:
        • Temporarily disabled public network access to block connections
          • Applied firewall rules to limit access to specific IPs
          1. Memory Management Commands (all were unsuccessful due to permissions or Azure SQL limitations):
            • Attempted to run DBCC FREEPROCCACHE
              • Attempted to run DBCC DROPCLEANBUFFERS
                • Tried ALTER DATABASE SCOPED CONFIGURATION CLEAR PROCEDURE_CACHE
                  • Tried ALTER RESOURCE GOVERNOR RECONFIGURE
                    • Attempted to disable Query Store
                    1. Database Configuration:
                      • Verified auto-pause is enabled with minimal delay
                        • Set minimum vCores to 0.5 and maximum to 1
                          • Disabled diagnostic settings where possible
                          1. System Table Maintenance:
                            • Ran EXEC sp_updatestats to update statistics

Limitations Encountered

Most traditional SQL Server memory management commands are either:

  • Not supported in Azure SQL (e.g., ALTER RESOURCE GOVERNOR)
  • Restricted even for administrator accounts
  • Do not have the expected effect on resource utilization

Impact

We're currently paying approximately $8-10 per day for a minimally used test database that should be costing closer to $2 per day if it were truly idle. This represents a 400-500% cost increase above expected rates.

Request for Support

We need assistance in determining why these background processes are consuming so much CPU and memory, and how to properly configure our database to reduce this consumption when idle. Standard management approaches have been unsuccessful, suggesting this may require backend adjustments or identification of a potential service issue.

Azure SQL Database
{count} votes

1 answer

Sort by: Most helpful
  1. Manasa Akula 680 Reputation points Microsoft External Staff Moderator
    2025-05-20T00:16:24.59+00:00

    Hi

    It looks like you're facing quite an issue with your Azure SQL Serverless database (CTCData) having unexpectedly high CPU billing even when it seems idle. Here’s a breakdown of some potential steps to help troubleshoot and possibly resolve the problem:

    Troubleshooting Steps

    Monitor Active Connections: It seems you have multiple persistent connections active. These may be contributing to the high CPU usage. You can check and monitor active connections to identify which ones may not be necessary and terminate them if possible.

    Investigate Azure Functions: Since you've mentioned that an Azure Function was stopped, make sure that there are no other Azure services or applications still trying to connect to your database that are retaining these persistent connections.

    Audit Your Firewall Rules: Since you’ve temporarily disabled public network access, ensure that the firewall rules are appropriately set to restrict unnecessary access and confirm that only required applications can connect to your database.

    Check for Scheduled Jobs: Look into whether you have any scheduled jobs or background processes that may be executing at intervals, potentially consuming CPU resources.

    Auto-Pause Configuration: Ensure that your configuration for auto-pause is set up correctly and that the minimum and maximum vCores are appropriately defined, which you've already done. If they are set to a low value, it may still be generating costs even in idle periods.

    Consider Query Store Statistics: Even if you've disabled the Query Store, ensure that there are no lingering statistics or cached execution plans that are still causing CPU utilization. If possible, clear them and check the impact.

    Look at Recent Changes: Since you noted the spike in CPU usage occurred around April 22, review any changes or deployments made around that time that may have inadvertently led to this behavior.
    Hope this helps. Do let us know if you any further queries.

     

    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.