/microsoft-sql-admin:backup-strategy-sqlserverfrom Microsoft SQL administration
Reviews or designs SQL Server and Managed Instance backup strategies, including recovery models, backup schedules, and RPO compliance.
Ships in Microsoft SQL administration. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Use this skill when the user asks about database backup strategy, backup jobs, maintenance plans, or backup recommendations on SQL Server or Managed Instance.
Platform Guard: This skill targets Engine Edition 1–4 or 8. For Azure SQL DB (Engine Edition 5, 11), use
backup-history-azuresqlinstead.
msdb backup history, backup Agent jobs, maintenance plans, and the RPO the current strategy achieves.microsoft-sql-admin plugin (mssql_list_database_connections,
mssql_connect_database, then mssql_execute_query); any other SQL tool the agent host provides
for running T-SQL and reading result sets;
sqlcmd from a terminal. If the
SQL Tools MCP server is not connected or lists no connections, follow the sql-tools-mcp-setup
skill, which asks before installing or configuring anything. If no SQL tool can be made available,
give the user the T-SQL to run and ask for the results.SELECT SERVERPROPERTY('InstanceDefaultBackupPath') AS DefaultBackupDirectory; (SQL Server 2019+). If it returns NULL (older versions, or Managed Instance, which backs up to URL), ask the user for the backup directory or report it as unknownmsdb.dbo.backupsetGetBackupMaintenancePlansForCurrentDatabaseGetExistingBackupAgentJobsForCurrentDbGetDatabaseRecoveryModelSELECT
j.job_id,
j.name AS JobName,
js.step_id,
js.step_name,
js.command
FROM msdb.dbo.sysjobs AS j
INNER JOIN msdb.dbo.sysjobsteps AS js ON j.job_id = js.job_id
WHERE (js.command LIKE '%BACKUP DATABASE%' AND js.command LIKE '%' + DB_NAME() + '%')
OR (js.command LIKE '%BACKUP LOG%' AND js.command LIKE '%' + DB_NAME() + '%')
OPTION (MAXDOP 1);
SELECT recovery_model_desc AS RecoveryModel
FROM sys.databases
WHERE name = db_name()
OPTION (MAXDOP 1);
SELECT name, package_data
FROM (
SELECT
p.name,
p.id,
CAST(CAST(p.packagedata AS VARBINARY(MAX)) AS VARCHAR(MAX)) AS package_data
FROM msdb.dbo.sysssispackages AS p
JOIN msdb.dbo.sysssispackagefolders AS pf ON p.folderid = pf.folderid
WHERE foldername = 'Maintenance Plans'
) AS tab
WHERE package_data LIKE '%Back Up Database Task%' AND package_data LIKE '%' + DB_NAME() + '%'
OPTION (MAXDOP 1);
## Database Backup Strategy
Database: {{ current database name}}
Recovery Model: {{ current database's recovery model}}
Default Backup Directory: {{ server's current backup directory}}
Date: {{current date in YYYY-MM-DD format}}
### Available Backups
{{Include list of all available backups and their types (use words, not special codes)}}
### Backup Maintenance Plans
{{Include list of all backup maintenance plans related to backups for the current database}}
### Backup Agent Jobs
{{Include list of all backup agent jobs related to backups for the current database}}
### Backup Strategy Summary
{{Include: summary of the backup strategy for the current database and if possible the RPO the current strategy provides.}}
### Recommendations
{{Include: any recommendations for improving the backup strategy for the current database. Show any BACKUP or job-creation T-SQL as a script to review, with its impact; do not run it without the user's explicit confirmation.}}
BACKUP DATABASE, BACKUP LOG, ALTER DATABASE ... SET RECOVERY ..., and creating or changing
SQL Agent backup jobs or schedules (sp_add_job, sp_add_jobstep, sp_add_jobschedule,
sp_update_job, and similar), or maintenance plans, change server state. Present them as
recommendations or scripts only.COPY_ONLY is used; a new job runs on its schedule until it is disabled or deleted
(sp_update_job @enabled = 0 or sp_delete_job); a recovery model change affects log growth and
point-in-time restore until it is switched back and a new full backup is taken.If the user asks to create a database backup (the confirmation gate above applies):
BACKUP command with its target path, type, and options (for example
COPY_ONLY for an ad hoc backup that must not change the backup chain), explain the impact, and
run it only after the user explicitly confirms that command.If the user asks about potential data loss from a restore:
physical_device_name.fn_dblog. Convert segmented hex LSNs to decimal for comparison.fn_dblog with LSNs higher than latest backup LSN represent potential data loss.Response requirements:
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub microsoft/microsoft-sql --plugin microsoft-sql-admin47 skills in this plugin
/active-connectionsUse when the user asks who is connected, which sessions are idle or hold the oldest open transaction, or how connections split by login or app. If a client can't connect, use `connectivity-troubleshoot`./always-encrypted-columnsUse when the user asks which plaintext columns can or should use Always Encrypted, or why a column is disqualified. Eligibility only: not for listing already-encrypted columns or their keys./authentication-diagnosticsUse when a login fails (18456, 'Login failed for user'), a user can't open a database, a permission is denied, or an Entra or managed identity login fails. For network errors, use `connectivity-troubleshoot`.Other plugins' skills for the same job