Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Finance forum / How do I get SQL serve...
Finance forum
Suggested answer

How do I get SQL server real time parameters such as used RAM, CPU, AXDB size, TempDB size. Is it possible to get them for both on-premise and cloud architectures?

Posted on by Microsoft Employee

Hello,

I would like to find out is it possible to get some SQL server parameters or not.

The parameters I am interested in are:

- current SQL Server RAM usage and amount of free OS RAM

- current SQL Server CPU usage

- current AXDB file size

- current TempDB file size

Also, is it possible and how could I get those parameters for both on-premise and cloud architectures?

I am working with AX D365. I need to get those parameters through code, so the solution to check them by myself via Task manager and SQL Server manager unfortunately is not suitable.

Thank you in advance,

Alexander Zharkov

  • Suggested answer
    Sukrut Parab Profile Picture
    Sukrut Parab 71,643 Moderator on at
    RE: How do I get SQL server real time parameters such as used RAM, CPU, AXDB size, TempDB size. Is it possible to get them for both on-premise and cloud architectures?

    I remember getting some properties like maxdop and db size through code for cloud environment. It was long time back , so I don't remember as well now how to get it . I will share if I get something but not everything is possible to get for cloud version . For on premise version as you have control over everything you can get it .

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: How do I get SQL server real time parameters such as used RAM, CPU, AXDB size, TempDB size. Is it possible to get them for both on-premise and cloud architectures?

    see if this helps

    community.dynamics.com/.../monitoring-your-microsoft-dynamics-365-finance-and-operations-one-version-production-environment

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: How do I get SQL server real time parameters such as used RAM, CPU, AXDB size, TempDB size. Is it possible to get them for both on-premise and cloud architectures?

    Hi Alexander,

    You can refer to the performance monitoring of SQL.

    Review CPU-consuming queries

    https://docs.microsoft.com/en-us/azure/sql-database/sql-database-query-performance

    Capture performance stats: https://www.datduh.com/sql-server/2017/7/27/capture-dtu-performance-stats-in-sql-azure-database

    I hope it will help you.

  • Suggested answer
    nmaenpaa Profile Picture
    nmaenpaa 101,148 on at
    RE: How do I get SQL server real time parameters such as used RAM, CPU, AXDB size, TempDB size. Is it possible to get them for both on-premise and cloud architectures?

    There is no product called "AX 365", it's Dynamics 365 for Finance and Operations. I will move this post from AX forum to the D365FO forum.

    You can't get such insights from within D365FO. The cloud D365FO runs on Azure SQL which is database as a service, and the underlying server setup is hidden from the consumer (this case: D365FO).

    You can see some insights in LCS Environment monitoring page.

    In on-premises version you can use normal monitoring software (not related to D365FO) to monitor the health of the Service Fabric cluster. And you can use tools of your choice to monitor the size of the database files.

Helpful resources

Quick Links

Replay now available! Dynamics 365 Community Call (CRM Edition)

Catch up on the first D365 Community Call held on 7/10

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 287,696 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,490 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans