Skip to content

Commit 6e0b3a5

Browse files
author
Bo Anderson
committed
Remove ServerName Check for RDS (sp_BlitzLock)
Removing the ServerName Check so the script will work on RDS Instances with renamed ServerName
1 parent 244348b commit 6e0b3a5

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

sp_BlitzLock.sql

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,6 @@ You need to use an Azure storage account, and the path has to look like this: ht
320320
/* WITH ROWCOUNT doesn't work on Amazon RDS - see: https://github.com/BrentOzarULTD/SQL-Server-First-Responder-Kit/issues/2037 */
321321
IF LEFT(CAST(SERVERPROPERTY('ComputerNamePhysicalNetBIOS') AS VARCHAR(8000)), 8) <> 'EC2AMAZ-'
322322
AND LEFT(CAST(SERVERPROPERTY('MachineName') AS VARCHAR(8000)), 8) <> 'EC2AMAZ-'
323-
AND LEFT(CAST(SERVERPROPERTY('ServerName') AS VARCHAR(8000)), 8) <> 'EC2AMAZ-'
324323
AND db_id('rdsadmin') IS NULL
325324
BEGIN;
326325
BEGIN TRY;
@@ -768,7 +767,6 @@ You need to use an Azure storage account, and the path has to look like this: ht
768767
IF SERVERPROPERTY('EngineEdition') NOT IN (5, 6) /* Azure SQL DB doesn't support querying jobs */
769768
AND NOT (LEFT(CAST(SERVERPROPERTY('ComputerNamePhysicalNetBIOS') AS VARCHAR(8000)), 8) = 'EC2AMAZ-' /* Neither does Amazon RDS Express Edition */
770769
AND LEFT(CAST(SERVERPROPERTY('MachineName') AS VARCHAR(8000)), 8) = 'EC2AMAZ-'
771-
AND LEFT(CAST(SERVERPROPERTY('ServerName') AS VARCHAR(8000)), 8) = 'EC2AMAZ-'
772770
AND db_id('rdsadmin') IS NOT NULL
773771
AND EXISTS(SELECT * FROM master.sys.all_objects WHERE name IN ('rds_startup_tasks', 'rds_help_revlogin', 'rds_hexadecimal', 'rds_failover_tracking', 'rds_database_tracking', 'rds_track_change'))
774772
)

0 commit comments

Comments
 (0)