Selection of Cache Replacement Algorithm for PostgreSQL
P. Yogendra Prasad, Lakshmi Narayana Velayduam, Srirama Sai Kumar, Momin Shaikshavali, V. Vamsidhar Reddy, Nayudori Ajay Kumar · 2023
To always ensure that the best memory blocks are available in the Cache Memory, several Cache Replacement algorithms are used like Least Recently Used, Most Frequently Used, etc. but each Cache Replacement algorithm has its own advantages and disadvantages. To avoid problems like scanning, and time complexity, this study intends to propose a cache replacement algorithm for PostgreSQL, which currently uses 2Q algorithm to keep the best memory block references needed by the processor to complete its task inside cache memory. The PostgreSQL database retrieves the data very slowly when compared to other databases. We will compare various cache replacement algorithms under the same workload and choose the best one among them. When we compare ARC, LRU, MRU, and LFU, Adaptive Replacement Cache (ARC) is the significant cache replacement policy. So, we check the PostgreSQL with the ARC and analyze the condition of the database.