In Microsoft SQL Server 2019, is "MS_DataCollectorInternalUser" an internal Microsoft SQL Server database principal in the msdb system database, required for SQL Server Data Collector functionality?

R.O 0 Reputation points
2026-08-11T05:59:13.6733333+00:00

In Microsoft SQL Server 2019, is "MS_DataCollectorInternalUser" an internal Microsoft SQL Server database principal in the msdb system database, required for SQL Server Data Collector functionality?

SQL Server | Other
SQL Server | Other

Additional SQL Server features and topics not covered by specific categories

0 comments No comments

1 answer

Sort by: Most helpful
  1. Erland Sommarskog 137.9K Reputation points MVP Volunteer Moderator
    2026-08-11T13:48:32.6866667+00:00

    That's a good question, and after having installed a junk instance and activated data collection, my answer will have to be: I don't know. That is, I have not been able to find that this user is actually used anywhere.

    I ran:

    SELECT * FROM sys.sql_modules WHERE definition LIKE '%MS_DataCollectorInternalUser%'
    

    And it does return a couple of rows, but the code all look like this example:

    CREATE   PROCEDURE [dbo].[sp_syscollector_verify_collector_state]
        @desired_state          int
    WITH EXECUTE AS OWNER -- 'MS_DataCollectorInternalUser'
    

    That is, the username is only a comment.

    I also note that the user has a sid, which suggests that it would be a server principal, but the sid is not present in master.

    I tried to drop the user, but I was told:

    Msg 15284, Level 16, State 1, Line 14
    The database principal has granted or denied permissions to objects in the database and cannot be dropped.
    
    

    I ran:

    SELECT * FROM sys.database_permissions WHERE grantor_principal_id = user_id('MS_DataCollectorInternalUser')
    
    

    And which returned one row that grants the role dc_admin to impersonate MS_DataCollectorInternalUser. But I have not found case where any such impersonation happens. But I might not have looked hard enough,

    Was this answer helpful?

    0 comments No comments

Your answer

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