2014年1月4日 星期六

1134345 - Using locked pages for SQL Server

1134345 - Using locked pages for SQL Server
加入lock page的使用者權限群組
避免windows page out,影響sql server效能
有用網域帳號才需要(例如做cluster)
因為local的預設已有權限
需重啟sql service才能生效

2014年1月3日 星期五

SAP 建議手動維護DATA FILE的增長

1238993 - Proportional File Auto-Growth with SQL Server 2008

1744217 - MSSQL: Improving the database performance

Symptom
You experience bad general system performance and suspect the database as root cause.

Environment
ABAP-, Java- or dual-stack based SAP systems based on Microsoft SQL Server

Cause
In the majority of cases left out maintenance and housekeeping activities on database level are the root cause for database performance related issues.
Without proper and up-to-date system operation procedures in place, the overall performance of the database (and the BW system if in use) in turn can degrade significantly over time.

1744217 - MSSQL: Improving the database performance

SAP note 1558087 - SQL Server Statistics Maintenance

Windows NT下
先將批次檔與note的附件放在以下路徑
(1)D:\usr\sap\PRD\command\
SM69 增加外部指令,範例:
(2)D:\usr\sap\PRD\command\sap_IndexStatsMaintenance.bat
批次檔 sap_IndexStatsMaintenance.bat 內容如下:
sqlcmd -i D:\usr\sap\PRD\command\sap_IndexStatsMaintenance.sql -o D:\usr\sap\PRD\Log\sap_IndexStatsMaintenance.txt
(3)建立 D:\usr\sap\PRD\Log\目錄
(4) sap_IndexStatsMaintenance.sql 增加三行(紅字部份,prd = sid,要分大小寫):
 /********************************************************/
/*  Object  :Stored Procedure sap_IndexStatsMaintenance */
/*  Author  : C5024907                                  */
/*  Note    : 1558087                                   */
/*  Version : 1.5                                       */
/*                                                      */
/*  05/13/2011 - Initial version                        */
/*  08/23/2011 - C5002239 found more fields             */
/*  08/09/2012 - I035208 found some more in INDX        */
/*  11/30/2012 - I044729 found the systemobject         */
/*               problem                                */
/*  04/09/2013 - Added PA* and HRP* tables              */
/********************************************************/
use PRD
setuser 'prd'
go


(5)@NoExecute        int           = 0,
改成 @NoExecute        int           = 1,

(6)存檔
(7)排程每月月中或每年一月執行