What's swap memory, and when should you be concerned?

26-Oct-2020 1476
Memory is important resource in any application. All programs have to access data in various places, usually in many different places.This matters for performance because where we store data determines how long it takes to access it.Swap memory is a kind of "special" memory behavior used by Linux (it's in Windows and Mac too, but nobody deploys there and it works slightly differently in those environments so we're gonna skip that). When chunks of memory are either infrequently accessed or the box is low on memory, it may "page out" certain memory areas to the disk. This is swap memory.So, when you're accessing memory that's been swapped, you're accessing memory that isn't on a RAM stick - instead, it's on an SSD or HDD.
Use coupon code:

RUBYONRAILS

to get 30% discount on our bundle!
Prepare for your next tech interview with our comprehensive collection of programming interview guides. Covering JavaScript, Ruby on Rails, React, and Python, these highly-rated books offer thousands of essential questions and answers to boost your interview success. Buy our 'Ultimate Job Interview Preparation eBook Bundle' featuring 2200+ questions across multiple languages. Ultimate Job Interview Preparation eBook Bundle