Linux Server Swap and Memory Usage | Top Docs from Linode

  Рет қаралды 5,009

Akamai Developer

Akamai Developer

Күн бұрын

Пікірлер: 9
@afflictionofarmada8857
@afflictionofarmada8857 Жыл бұрын
Swap can have another benefit: Linux takes note of which pages of memory are not being touched. It tags them as "Inactive". They might be speculatively written to the swap file but not removed from DRAM (SwapCached). When memory pressure happens, those SwapCached pages can be released without having to write to disk. Some processes might allocate, but not actively use, a fair amount of memory that can eventually be recognised as Inactive, and SwapCached. If those pages are eventually accessed, they can be quickly pulled out of SwapCached+Inactive and into Active, without having to read from disk. Alternatively, if you're dealing with a fileserver, most of your memory might indeed be Cached, swap might allow those Inactive pages to be moved out of DRAM to gain a little bit more memory for the cache. The linux kernel devs working on its virtual memory subsystem are pretty smart, swap is rarely going to be a hinderence, but as mentioned swappiness (and many other tunables) can be adjusted for pretty much any workload. Those categorizations I mentioned about memory (Active, Inactve, SwapCached, Cached, and dozens more) can be retrieved with: $ cat /proc/meminfo If you have a large amount of Inactive, swap might just be a benefit.
@lethalz4519
@lethalz4519 Жыл бұрын
Great video, clear and consice!
@art4018
@art4018 Жыл бұрын
Thank you for another great video!
@send2gl
@send2gl Жыл бұрын
I actually run headless Raspberry Pi server using Apache, xsane, mumble, samba, dlna and others. It is an original Pi with only 256MB RAM. I also have a desktop and vnc installed but neither run at boot. I created a 512MB RAM for the very rare occasions I initialize the Desktop and VNC. Works well but I admit I've not actually checked the memory usage whilst running these two services.
@vinvvinv7460
@vinvvinv7460 Жыл бұрын
Hi, can you make a video explaining /etc/hosts, /etc/resolve.conf & /etc/named.conf why and when are they used? if you can provide a practical real-world working example In a basic understanding manner, please its a request
@netwebgaming5121
@netwebgaming5121 Жыл бұрын
In Ubuntu, if CSF and fail2ban is installed, do you recommend installing UFW too?
@Henk777ER
@Henk777ER Жыл бұрын
Hi, thanks for the video. What about the size of the swap partition? These days you can have plenty of RAM on your system like 16GB. A rule of thumb is the swap size is twice the amount of RAM, so here the swap partition would be 32GB. But with 16GB of RAM isn't the chance you run out of RAM and need swap very remote? So why then allocate 32GB of swap space?
@AkamaiDeveloper
@AkamaiDeveloper Жыл бұрын
Hello Henk - The following article from It's Foss outlines a bit more about swap recommendations and how vary from distro to distro. itsfoss.com/swap-size/ For some additional context, on the Linode platform, the default swap size on a 16GB instance is 512MB.
@PS_Tube
@PS_Tube Жыл бұрын
If someone uses Linux desktop with suspend, you'd need to have swap that's equal to or double the RAM. Else, 1 or 2 GiB of swap is enough. Better to be safe than sorry.
How to Use Tar on Linux | Command Line Tips from Linode's Top Docs
23:26
А что бы ты сделал? @LimbLossBoss
00:17
История одного вокалиста
Рет қаралды 11 МЛН
ROSÉ & Bruno Mars - APT. (Official Music Video)
02:54
ROSÉ
Рет қаралды 182 МЛН
🕊️Valera🕊️
00:34
DO$HIK
Рет қаралды 16 МЛН
Everything You Need to Know About sudo | Linux Essentials Tutorial
23:51
Akamai Developer
Рет қаралды 40 М.
Linux Crash Course - Understanding Memory and Swap Usage
20:55
Learn Linux TV
Рет қаралды 48 М.
18 Commands That Will Change The Way You Use Linux Forever
29:50
Akamai Developer
Рет қаралды 1,2 МЛН
The wget Command | How to Download Files From a Server
12:39
Akamai Developer
Рет қаралды 14 М.
Hostnames and Domains on Linux Servers | Top Docs with Jay LaCroix
16:23
How computer memory works - Kanawat Senanan
5:05
TED-Ed
Рет қаралды 3,4 МЛН
Complete SSH Tutorial: All-in-One Guide for Secure Connections
1:28:00
Learn Linux TV
Рет қаралды 613 М.
btrfs Filesystem for Linux | Top Docs
13:01
Akamai Developer
Рет қаралды 14 М.
How to use the ps Command | Linux Command Line Basics
14:45
Akamai Developer
Рет қаралды 35 М.
The Linux Filesystem Explained | How Each Directory is Used
14:08
Akamai Developer
Рет қаралды 231 М.