Thursday, December 10, 2009

Seven Tips for SQL Server Production DBAs

  1. Use Forfiles utility (forfiles.exe) to delete old database backup files:
    forfiles /p "e:\sqlbackup" /m "*.bak" /c "cmd /c del /Q @path" /d -2
  2. Use ALTER USER WITH LOGIN to repair orphaned logins.
  3. Use sp_addsrvrolemember to give yourself the sysadmin role.
  4. Use the PortQryUI utility to troubleshoot connectivity problems.
  5. Use a different strategy when running DBCC CHECKDB against large databases.
  6. Use the Import Package Option to deploy SQL Server Integration Services (SSIS) packages to the msdb database.
  7. Use SQL Server 2008's local server groups and Central Management Servers to query multiple servers at the same time.
URL: Seven Tips for SQL Server Production DBAs

Wednesday, December 9, 2009

HSN: MSSQL DBA daily jobs

HSN: MSSQL DBA daily jobs

MSSQL DBA daily jobs

Daily maintenance jobs:
  1. Backup database.
  2. Check database integrity: check primary key etc.
  3. History cleanup: log history archive.
  4. Check indexes: rebuild index, re-organize index etc.
  5. Shrink database.

Daily monitoring jobs:

  1. Monitor database connections.
  2. Monitor physical storage usage.
  3. Monitor memory usage: cache hits ratio, page reads, writes/sec etc.
  4. Monitor CPU usage.
  5. Monitor physical disk I/O, network segment.
  6. Monitor error log on critical events: severity level > 16.
  7. Monitor user activities: connections, dead lock detection, user security breach, SQL compilation/sec etc.

HSN: Oracle DBA checklist

HSN: Oracle DBA checklist

Oracle DBA checklist

Daily procedures

  1. Verify all instances are up: run daily reports or via "Oracle Enterprise Manager's 'probe' event"
  2. Look for any new alert log entries: Check ORA-errors in $ORACLE_BASE//bdump/alert_.log
  3. Verify success of database backup
  4. Verify success of database archiving to tape
  5. Verify enough resource for acceptable performance:
    a. Verify free space in tablespaces (free.sql, space.sql)
    b. Verify rollback segment: should be ONLINE
    c. Identify bad growth projections:
    I. analyze5pct.sql
    II. nr_extents.sql
    III. Query current table sizing
    IV. Query current index sizing
    V. Query growth trends
    d. Identify space-bound objects (spacebound.sql)
    e. Review contention for CPU, RAM, network and disk resources.
  6. Copy archived logs to standby database and roll forward: use automated scripts, verify daily

Nightly procedures

  1. Collect volumetric data: mk_volfact.sql, analyze_comp.sql, pop_vol.sql

Weekly procedures

  1. Look for objects that break rules
    a. Check NEXT_EXTENT: nextext.sql, check existing extents: existext.sql
    b. Check missing PK: no_pk.sql, check disabled PK: disPK.sql, check PK indexes uniqueness: nonuPK.sql
    c. All indexes should use INDEXES tablespace: mkrebuild_idx.sql
    d. Check schema objects consistency between test and production: datatype.sql, obj_coord.sql, Quest Schema Manager.
  2. Look for security policy violations
  3. Look in SQL*Net logs for errors, issues
    a. Check client side logs
    b. Check server side logs
  4. Archive all alert logs to history

Montly procedures

  1. Look for harmful growth rates
  2. Review tuning opportunities: cache hit ratio, latch contention etc.
  3. Look for I/O contention
  4. Review fragmentation: row chaining etc.
  5. Project performance into the future
  6. Perform tuning and maintenance

HSN: 股票买卖操盘策略

HSN: 股票买卖操盘策略

股票买卖操盘策略

根据美国次贷危机,中国A股崩盘,网络泡沫破裂,911危机及亚洲金融风暴经验,股市通常会下跌到1/5位置,甚至会到达1/10, 在此调整操盘策略:
  1. 买入:
    跌幅
    百分比 买入金额
    -20%
    81% 1000 (短期) :从近期高处下跌
    -20% 63% 1 / 4 (期)
    -20% 45% 1 / 3 (中期)
    -20% 36% 1/2 (期)
    -20% 25% 1 (长期)
    -20% 15% reserved 1/2 (长期)

  2. 卖出:
    涨幅 百分比 卖出金额
    +30%
    130% 1000 (短期) :从近期低处上涨
    +30% 170% 1 / 4 (中期) :中期走势
    +30% 220% 1 / 3 (中期)
    +30% 280% 1 / 2 (长期)
    +30% 350% 1 (长期)

  3. 取参照点:
    以上一次拐点为参照点.
    举例:
    A涨B跌C涨, 在C点时, 涨幅20%, 拐点B, 卖出金额1000.
    A涨BC涨, 在C点时, 涨幅20%, 拐点A, 卖出金额1 / 4.
    A涨B跌C, 在C点时, 幅20%, 拐点B, 买入金额1000.
    AB跌C, 在C点时, 幅10%, 拐点A, 买入金额1 / 3.

HSN: Replication Configuration Between MSSQL 2005 and Oracle

HSN: Replication Configuration Between MSSQL 2005 and Oracle

HSN: VMs vs. Multiple SQL Server Instances

HSN: VMs vs. Multiple SQL Server Instances

HSN: Steps to set up oracle database RAC

HSN: Steps to set up oracle database RAC

HSN: 基金买卖操盘方式

HSN: 基金买卖操盘方式

HSN: 我的投资策略

HSN: 我的投资策略

HSN: 如何从MACD指标研判股市走势?

HSN: 如何从MACD指标研判股市走势?

HSN: Dollar Cost Averaging

HSN: Dollar Cost Averaging

HSN: 4 ways to be a millionaire

HSN: 4 ways to be a millionaire

HSN: All Money Sense

HSN: All Money Sense

HSN: Linux User Guide (2)

HSN: Linux User Guide (2)

HSN: Linux User Guide (1)

HSN: Linux User Guide (1)

Tuesday, December 8, 2009

HSN: Oracle Dictionary - DBA Views

HSN: Oracle Dictionary - DBA Views

HSN: Oracle Dictionary - All Views

HSN: Oracle Dictionary - All Views

HSN: Oracle Dictionary - Dynamic Views

HSN: Oracle Dictionary - Dynamic Views

HSN: Oracle Dictionary - User Views

HSN: Oracle Dictionary - User Views

HSN: SCJP 310-035 Sample Questions (1)

HSN: SCJP 310-035 Sample Questions (1)

HSN: Sun Certified Web Component Developer 310-081 Sample Questions

HSN: Sun Certified Web Component Developer 310-081 Sample Questions

HSN: J2EE Patterns

HSN: J2EE Patterns

HSN: Catalog of design patterns

HSN: Catalog of design patterns

HSN: Configure MSSQL to use more than 2GB RAM

HSN: Configure MSSQL to use more than 2GB RAM

HSN: MCTS 07-431 Sample Questions (1)

HSN: MCTS 07-431 Sample Questions (1)

HSN: MSSQL 2005 Knowledge Base 1

HSN: MSSQL 2005 Knowledge Base 1

HSN: Using LogMiner to analyze transaction history

HSN: Using LogMiner to analyze transaction history

HSN: How to query server and client environment in PL/SQL

HSN: How to query server and client environment in PL/SQL

HSN: OCA references

HSN: OCA references

HSN: OCP References

HSN: OCP References

HSN: 1Z0-043 sample questions (1)

HSN: 1Z0-043 sample questions (1)

HSN: 1Z0-042 sample questions (1)

HSN: 1Z0-042 sample questions (1)

HSN: Steps to set up oracle database RAC

HSN: Steps to set up oracle database RAC

Latest Posts