mssql-performance-revi…
Agentic offline orchestrator for end-to-end SQL Server performance reviews. Forms hypotheses from artifacts or symptoms, dispatches the specialised review…
Audits the security-object migration plan for a SQL Server move with 15 checks (J1-J15) — logins, server and database permissions, credentials, certificates/keys ownership, and Central Management Server registrations. Use this skill when a user is migrating a SQL Server database
$ npx -y skills add vanterx/mssql-performance-skills --skill sqlmigration-security-review --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/sqlmigration-security-reviewContext preview
The summary Claude sees to decide when to auto-load this skill.
Audits the security-object migration plan for a SQL Server move with 15 checks (J1-J15) — logins, server and database permissions, credentials, certificates/keys ownership, and Central Management Server registrations. Use this skill when a user is migrating a SQL Server database
name: sqlmigration-security-review description: Audits the security-object migration plan for a SQL Server move with 15 checks (J1-J15) — logins, server and database permissions, credentials, certificates/keys ownership, and Central Management Server registrations. Use this skill when a user is migrating a SQL Server database or instance and needs to carry over logins, permissions, credentials, or certificates, or asks "will my logins still work after migration" or "how do I migrate permissions." Trigger whenever security-object portability during a migration is the topic; dispatched here from /sqlmigration-review for the security-object family. triggers: - /sqlmigration-security-review - /migration-security-review - /sql-migration-logins
Reviews the security-object family of a SQL Server migration — the slice `sqlmigration-review` dispatches here rather than checking itself. This skill owns 15 checks (J1–J15) covering whether logins, server/database permissions, credentials, certificate/key ownership, and Central Management Server (CMS) registrations will survive a backup/restore or log shipping/Always On AG seeding migration, and what breaks if they don't.
unsupported on target platform, password policy differences, default database missing
explicit GRANT/DENY statements, ownership chains crossing the migration boundary
linked server stored logins
(excluding TDE, which is `sqlencryption-review`'s domain), backup of certificates before cutover
All fix recipes use native T-SQL system views (`sys.server_principals`, `sys.database_principals`, `sys.credentials`), the in-box `SqlServer` PowerShell module, and the native `sp_help_revlogin` script — no third-party module is referenced or required.
Accepts any of the following:
1. **Source and target server facts pasted as text** — login lists, permission grants, target platform 2. **Capture script output** (`.txt`/`.csv`) — see `scripts/capture-security-facts.sql` 3. **Natural-language description** — "migrating 40 logins, half are Windows groups, target is Azure SQL Database" 4. **File path to a directory of exported artifacts** — `sp_helplogins` text dumps, SSMS Generate Scripts output for logins/users
Recommended capture (run on the **source** instance):
SELECT name, type_desc, is_disabled, default_database_name,
SUSER_SID(name) AS sid
FROM sys.server_principals
WHERE type IN ('S','U','G') AND name NOT LIKE '##%';
SELECT dp.name AS user_name, dp.type_desc, sp.name AS login_name
FROM sys.database_principals dp
LEFT JOIN sys.server_principals sp ON dp.sid = sp.sid
WHERE dp.type IN ('S','U','G');
SELECT name, credential_identity FROM sys.credentials;
-- TDE encryptor certs also have is_active_for_begin_dialog = 0, so anti-join the DEK view to drop them
SELECT c.name, c.certificate_id, c.expiry_date, c.pvt_key_encryption_type_desc
FROM sys.certificates c
WHERE NOT EXISTS (SELECT 1 FROM sys.dm_database_encryption_keys dek
WHERE dek.encryptor_thumbprint = c.thumbprint);**Trigger:** A database user's SID (`sys.database_principals.sid`) has no matching login SID (`sys.server_principals.sid`) on the target instance after restore. **Severity:** Critical **Fix:** Run `ALTER USER [username] WITH LOGIN = [username];` for each orphaned user once the matching login exists on the target, or use `sp_help_revlogin`'s generated script to recreate logins with matching SIDs before the restore completes.
**Trigger:** Migration plan creates new SQL-authentication logins on the target manually (e.g., via `CREATE LOGIN`) rather than scripting them from the source with matching SIDs. **Severity:** Critical **Fix:** Generate the login-creation script from the source using `sp_help_revlogin` (in-box system stored procedure, or its documented script form), which preserves the original SID and hashed password — manually re-typing `CREATE LOGIN` statements produces a new SID and orphans every database user mapped to that login.
**Trigger:** Source has Windows-authenticated logins/groups, certificate-mapped logins, or asymmetric-key-mapped logins, and the target platform is Azure SQL Database (no Windows Auth support) or otherwise cannot host that login type. **Severity:** Critical **Fix:** Map Windows logins to Microsoft Entra ID identities for Azure SQL Database targets; confirm certificate/key-mapped login support on the specific target platform before migrating — see `/sqlmigration-review` Y8 for the broader Azure platform check.
**Trigger:** Source logins have `CHECK_POLICY`/`CHECK_EXPIRATION` settings that depend on a domain password policy not enforced identically on the target (e.g., target is a workgroup server or Azure SQL Database with no domain policy). **Severity:** Warning **Fix:** Re-evaluate each migrated login's `CHECK_POLICY`/`CHECK_EXPIRATION` settings explicitly on the target rather than assuming the source's domain policy carries over silently.
**Trigger:** A login's `default_database_name` references a database that either was not part of the migration scope or has a different name on the target. **Severity:** Warning **Fix:** `ALTER LO
SQL Server performance tuning skills for LLMs — 829 checks across 26 skills covering T-SQL, execution plans, wait stats, deadlocks, Query Store, indexes, encryption, Always On AG, WSFC, ERRORLOG, SPN, memory, disk I/O, config drift, setup logs, SSRS & migration readiness. Remote MCP server on Cloudflare Workers.
Repo: vanterx/mssql-performance-skills
Agentic offline orchestrator for end-to-end SQL Server performance reviews. Forms hypotheses from artifacts or symptoms, dispatches the specialised review…
Audits SQL Server Always On Availability Group configuration correctness across all layers — prerequisites, replica design, listener architecture, backup…
Analyze SQL Server Setup Bootstrap log files to diagnose failed installations, failed Cumulative Update or Service Pack patching, failed cluster node…
Analyzes Windows Server Failover Cluster (WSFC) CLUSTER.LOG files for Always On Availability Group root-cause diagnosis. Use this skill when an availability…
Analyze SQL Server instance and database configuration drift against proven DBA best practices. Applies 29 checks (B1–B29) across five categories: parallelism…
Analyze SQL Server deadlock XML (from system_health XE session, SSMS deadlock graph, or trace) to identify root cause and produce a prioritized remediation…