Oracle uses v $ osstat view to query CPU usage

Source: Internet
Author: User

OS statistics
John also needs to eliminate the possibility that the host system is a bottleneck when carefully checking the user's performance problems. Before using Oracle for 10 Gbit/s, he can use operating system (OS) tools such as SAR and vmstat and infer some metric indicators that determine contention issues. In Oracle 10 Gb, OS-level metrics are automatically collected in the database. To view potential host contention problems, John performs the following query on the V $ osstat View:
Select * from V $ osstat;
CodeThe output in Listing 6 shows various OS-level metric elements. All time elements are in the unit of per second. John learned from the results shown in code listing 6 that a CPU in the system is idle for 51025805 seconds (idle_ticks) and busy for 2389857 seconds (busy_ticks ), this indicates that the CPU is about 4% busy.

 

2389857/(51025805 + 2389857) = 4%

 

He concluded that CPU is not a bottleneck in the host. Note that if the host system has more than one CPU, the header contains the AVG _ prefix column. For example, avg_idle_ticks displays the average value of these metrics for all CPUs.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.