# Metricbeat MSSQL User Role required

**URL:** <https://discuss.elastic.co/t/metricbeat-mssql-user-role-required/256159>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [November 20, 2020, 4:25pm UTC](https://discuss.elastic.co/t/metricbeat-mssql-user-role-required/256159 "2020-11-20T16:25:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kotha](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kotha/32/79410_2.png) [@kotha](https://discuss.elastic.co/u/kotha)\
**Post date:** [November 20, 2020, 4:25pm UTC](https://discuss.elastic.co/t/metricbeat-mssql-user-role-required/256159/1 "2020-11-20T16:25:09Z")

</div>

what is the minimum role required to gather stats for Metric MSSQL beat. Right now we are using **sysadmin** role, but there is a push back from the DBA in using that role for the user that collects the metrics for MSSQL

---

<div class="post-metadata">

**Author:** ![bering](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bering/32/4044_2.png) [@bering](https://discuss.elastic.co/u/bering)\
**Post date:** [November 23, 2020, 6:33am UTC](https://discuss.elastic.co/t/metricbeat-mssql-user-role-required/256159/2 "2020-11-23T06:33:40Z")

</div>

You could try the VIEW SERVER STATE combined with public as mention here [https://github.com/elastic/beats/issues/13006](https://github.com/elastic/beats/issues/13006)

Microsoft has this article on the DMVs [https://docs.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-views/system-dynamic-management-views?view=sql-server-ver15](https://docs.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-views/system-dynamic-management-views?view=sql-server-ver15)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [December 21, 2020, 6:33am UTC](https://discuss.elastic.co/t/metricbeat-mssql-user-role-required/256159/3 "2020-12-21T06:33:44Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
