Querying sys.master_files through a linked server, I get no results.
Why? How do I work around this issue?
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It only takes a minute to sign up.Sign up to join this community
This approach works fine for me:
SELECT * FROM [linked_server_name].master.sys.master_files;
What you need to be sure of is that the linked server is running in the context of a user who has enough privileges to see the contents of the DMV. You can check who you're executing as using:
EXEC [linked server name].master.sys.sp_executesql N'SELECT SUSER_SNAME(), ORIGINAL_LOGIN();';