What exactly is thrashing? Why does it happen?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • BarryA
    New Member
    • Jun 2022
    • 19

    What exactly is thrashing? Why does it happen?

    Thrashing is linked to memory management in an operating system. What causes thrashing? How can we avoid it?

    I looked on Scaler topics and Wikipedia but I need more info regarding thrashing, Can someone help me out?
    Last edited by BarryA; Jul 14 '22, 07:24 AM. Reason: Update
  • Willjoe
    Banned
    New Member
    • Jul 2022
    • 12

    #2
    Thrashing happens when your system starts spending more time in doing paging rather than performing computation. Thrashing results in severe performance problems.

    The operating system always monitors CPU utilization. if CPU utilization is less OS increases the degree of multi-programming by adding more processes to the system. there is a global page replacement algorithm that is running run. so if os added more processes this algorithm will swap in and swap out of some pages. so now CPU utilization increases. so os added more processes to the system to increase the CPU utilization more. but after some time page faults start happening so CPU utilization decreases. by seeing this os adds more processes, as a result, more and more page faults occur so the CPU utilization decreases drastically.

    Regards,
    WILL

    Comment

    Working...