Central Management Servers - query from different server

  • Hi,

    I'm new to Central Management Servers. I just created one in SSMS, added all my SQL servers.

    I can run this query against all the instances at once:

    Select a.name,Backup_Date from master.dbo.sysdatabases a

    left join

    (select database_name,max(backup_finish_date) backup_date

    from msdb.dbo.backupset where backup_finish_date <= getdate()

    group by database_name) B

    on a.name = b.database_name

    order by backup_date

    Returns all the backup info for all my servers..fine.

    But I really want to be able to do is query my Central Managment server from another SQL server. Like this:

    USE [ZSW-ROBCON1].[SQLCENTRAL]

    Select a.name,Backup_Date from master.dbo.sysdatabases a

    left join

    (select database_name,max(backup_finish_date) backup_date

    from msdb.dbo.backupset where backup_finish_date <= getdate()

    group by database_name) B

    on a.name = b.database_name

    order by backup_date

    Where ZSW-ROBCON1 is my servername - SQLcentral is the newly created central management server name.

  • You need to register your Central Management Server with SSMS on the machine you want to query from.

    In SSMS:

    Go to View>Registered Servers

    Right click on Central Management Servers>Register Central Management Server

    Enter your server name>Save

    Now you can query the servers registered to your Central Management Server from SSMS.

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply