Skip to content

Commit

Permalink
Merge pull request #664 from BrentOzarULTD/Blitz_602
Browse files Browse the repository at this point in the history
Blitz 602
  • Loading branch information
BrentOzar committed Jan 16, 2017
2 parents 68d3140 + 48683a7 commit 9931bd3
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 2 deletions.
1 change: 1 addition & 0 deletions Documentation/sp_Blitz Checks by Priority.md
Expand Up @@ -26,6 +26,7 @@ If you want to change anything about a check - the priority, finding, URL, or ID
| 10 | Performance | Auto-Close Enabled | http://BrentOzar.com/go/autoclose | 12 |
| 10 | Performance | Auto-Shrink Enabled | http://BrentOzar.com/go/autoshrink | 13 |
| 10 | Performance | CPU Schedulers Offline | http://BrentOzar.com/go/schedulers | 101 |
| 10 | Performance | CPU w/Odd Number of Cores | http://BrentOzar.com/go/oddity | 198 |
| 10 | Performance | High Memory Use for In-Memory OLTP (Hekaton) | http://BrentOzar.com/go/hekaton | 145 |
| 10 | Performance | Memory Nodes Offline | http://BrentOzar.com/go/schedulers | 110 |
| 10 | Performance | Plan Cache Erased Recently | http://BrentOzar.com/askbrent/plan-cache-erased-recently/ | 125 |
Expand Down
8 changes: 7 additions & 1 deletion LICENSE.md
@@ -1,6 +1,12 @@
MIT License

Copyright (c) 2016 Brent Ozar Unlimited
Copyright for portions of sp_Blitz are held by Microsoft as part of project
tigertoolbox and are provided under the MIT license:
https://github.com/Microsoft/tigertoolbox

All other copyright for sp_Blitz are held by Brent Ozar Unlimited, 2017.

Copyright (c) 2017 Brent Ozar Unlimited

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
57 changes: 56 additions & 1 deletion sp_Blitz.sql
Expand Up @@ -72,9 +72,17 @@ AS
@IgnorePrioritiesAbove 50=ignore priorities above 50
For the rest of the parameters, see http://www.brentozar.com/blitz/documentation for details.
MIT License
Copyright for portions of sp_Blitz are held by Microsoft as part of project
tigertoolbox and are provided under the MIT license:
https://github.com/Microsoft/tigertoolbox
All other copyright for sp_Blitz are held by Brent Ozar Unlimited, 2017.
Copyright (c) 2016 Brent Ozar Unlimited
Copyright (c) 2017 Brent Ozar Unlimited
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand All @@ -95,6 +103,8 @@ AS
SOFTWARE.
*/'
ELSE IF @OutputType = 'SCHEMA'
BEGIN
Expand Down Expand Up @@ -3810,6 +3820,51 @@ IF @ProductVersionMajor >= 10 AND @ProductVersionMinor >= 50
'Mismatch between the number of TempDB files in sys.master_files versus tempdb.sys.database_files' AS [Details]
END

/*Perf - Odd number of cores in a socket*/
IF NOT EXISTS ( SELECT 1
FROM #SkipChecks
WHERE DatabaseName IS NULL
AND CheckID = 198 )
AND EXISTS ( SELECT 1
FROM sys.dm_os_schedulers
WHERE is_online = 1
AND scheduler_id < 255
AND parent_node_id < 64
GROUP BY parent_node_id,
is_online
HAVING ( COUNT(cpu_id) + 2 ) % 2 = 1 )
BEGIN

INSERT INTO #BlitzResults
(
CheckID,
DatabaseName,
Priority,
FindingsGroup,
Finding,
URL,
Details
)
SELECT 198 AS CheckID,
NULL AS DatabaseName,
10 AS Priority,
'Performance' AS FindingsGroup,
'CPU w/Odd Number of Cores' AS Finding,
'http://BrentOzar.com/go/oddity' AS URL,
'Node ' + CONVERT(VARCHAR(10), parent_node_id) + ' has ' + CONVERT(VARCHAR(10), COUNT(cpu_id))
+ CASE WHEN COUNT(cpu_id) = 1 THEN ' core assigned to it. This is a really bad NUMA configuration.'
ELSE ' cores assigned to it. This is a really bad NUMA configuration.'
END AS Details
FROM sys.dm_os_schedulers
WHERE is_online = 1
AND scheduler_id < 255
AND parent_node_id < 64
GROUP BY parent_node_id,
is_online
HAVING ( COUNT(cpu_id) + 2 ) % 2 = 1;

END;


IF @CheckUserDatabaseObjects = 1
BEGIN
Expand Down

0 comments on commit 9931bd3

Please sign in to comment.