linuxmemorymemory-managementswapfilepagefile

Does Linux have a page file?


I found at several places that Linux uses pages and a paging mechanism but I didn't find anywhere where this file is or how to configure it.

All the information I found is about the Linux swap file / partition. There is a difference between paging and swapping:

Paging moves pages (a small frame which contains a piece of data - usually 4 KB but can vary between different OS's) from main memory to a backbend storage, happens always as a normal function of the operating system. Swapping moves an entire process to storage and happens when the system is memory stressed or on windows 8 when a new application is hibernating.

Does Linux uses it's swap file / partition for both cases? If so, how could I see how many page are currently paged out? This information is not there in vmstat, free or swapon commands (or that I fail to see it).

Or is there another file used for paging? If so, how can I configure it (and watch it's usage)?

Or perhaps Linux does not use paging at all and I was mislead?

I would appreciate if the answers will be specific to red hat enterprise Linux both versions 6 and 7 but also a general answer about all Linux's will be good.

Thanks in advance.


Solution

  • Although Linux retains the term 'swap partition' as a historical relic, it actually performs paging. So your expectation is borne out; you were just thrown by the archaic terminology.