1 / 46

IT390 Business Database Administration

IT390 Business Database Administration. Unit 10: Troubleshooting SQL Server 2000. Objectives. Troubleshoot basic Microsoft SQL Database Server problems. Apply SQL Server troubleshooting to resolve network problems. Explain the commands to check network connections.

toan
Download Presentation

IT390 Business Database Administration

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. IT390 Business Database Administration Unit 10: Troubleshooting SQL Server 2000

  2. Objectives • Troubleshoot basic Microsoft SQL Database Server problems. • Apply SQL Server troubleshooting to resolve network problems. • Explain the commands to check network connections.

  3. Monitoring the Database Server • Monitoring is the process by which you can check if your database server is properly working. • The performance of a database deteriorates if maintenance tasks are not frequently performed on the database. • SQL Server provides you with various tools to monitor your database server to achieve optimal performance.

  4. Can you… ? • Differentiate between Response Time and Throughput Time.

  5. Can you… ? List the factors that affect the performance of an SQL database server. Much more painful than proper maintenance!

  6. Monitoring Performance Factors • A network administrator should check theusage of the following server resources: • Central processing unit (CPU) • Memory • Storage capacity • Network usage (A topic which has a larger scope!)

  7. SQL Server 2000 provides the following tools to monitor the factors that can hamper the performance of SQL Server 2000: T-SQL commands SQL Server 2000 Error Log Current Activity Window SQL Profiler SQL Server MonitoringTools

  8. Class Activity • Which SQL commands can you use to obtain information on CPU usage? YIKES!!

  9. Solution You can use the following SELECT syntax to get the SQL server processes and their corresponding threads: SELECT spid, lastwaittype, dbid, uid, cpu, physical_io, memusage, status, loginname, program_name from master..sysprocesses ORDER BY cpu desc GO

  10. Troubleshooting SQL Server 2000 • A database server might face various problems, such as network congestion, memory allocations, and permission problems on various database objects. • SQL Server provides various debugging tools for diagnosing and rectifying errors, such as DBCC commands and Enterprise Manager.

  11. Performance Tuning: Techniques and Tools • Performance tuning involves measures to enhance database performance. You can enhance performance of a database by taking small measures, which do not require much effort on your part except that you need to perform them at the right time. Some of these measures are: • Indexing • Creating large tables • Defining optimized data retrieval queries • In addition, you can use the Performance Monitor and Query Analyzer tools to monitor the performance of a database. HOW?

  12. Class Activity You are the DBA at PQR Inc. You are frequently receiving errors in SQL Server 2000. How can you view the root cause of these errors?

  13. You can view SQL Server Error Log using Enterprise Manager. Viewing SQL Server Error Log

  14. Class Activity • What is the significance of the Current Log File?

  15. Answer The Current Error Log is the most recent error log located under Program Files\Microsoft SQL Server\Mssql\Log.

  16. You can view an error message by double-clicking any item in the SQL Server Error Log file. Viewing an Error Log Message

  17. SQL Server provides database settings that can be used to troubleshoot some common problems, such as multiple users accessing the database at a critical time. You can use Enterprise Manager to change database settings under ‘Properties’ / Options tab. You can also use the sp_dboptionsystem stored procedure to change database settings. Alternatively, you can use DBCC commands to change database settings. Troubleshooting / Tools for Database Configurations

  18. What are the following DBCC commands used for? DBCC CHECKCATALOG DBCC CHECKTABLE DBCC CHECKDB Class Activity

  19. What are the following DBCC commands used for? DBCC CHECKCATALOG Solution

  20. What are the following DBCC commands used for? DBCC CHECKTABLE Solution (cont.)

  21. What are the following DBCC commands used for? DBCC CHECKDB Solution (cont.)

  22. John is a DBA at XYZ Inc. The database server at XYZ is facing network problems. What can be the causes of this problem? Class Activity

  23. A database server can also face problems due to network errors thus causing congestion. There can be several kinds of these network errors, such as: Bandwidth crunch (exhaustion) Subnet masking Congestion Orphaned sessions Monitoring the Network

  24. Stays open on the server-side even after the client has disconnected. Occurs when the client cannot free the network connection(s) that it is holding even when the session is terminated. Takes up an SQL Server network connection, and prevents other clients from connecting to the Server. Orphaned Session

  25. What are the 2 primary commands to check for database network connectivity over named pipes? Class Activity

  26. Use the net view command: net view \\servername Activity Answer

  27. Use the net use command: net use [device_name | *] [\\computer_name\share_name[\volume]] [password | *]] [/user:[domain_name\]user_name] [[/delete] | [/persistent:{yes | no}]] Activity Answer

  28. Summary • Performance tuning involves measures to enhance the performance of a database. • There are tools that can monitor the performance of a database. Some of these tools are: • Performance Monitor • Query Analyzer

  29. Summary • A Database Administrator should be able to use basic SQL Server Tools and Troubleshooting such as logs and the DBCC command. • A Database Administrator should use the commands to check Network conductivity.

  30. Summary • Did you understand the key points from the Lesson? • Do you have any questions?

More Related