# Clarification needed on memory requirements for Docker install

**URL:** <https://meta.discourse.org/t/clarification-needed-on-memory-requirements-for-docker-install/151976>\
**Category:** Self-hosting\
**Tags:** server-resources\
**Created:** [May 19, 2020, 6:51pm UTC](https://meta.discourse.org/t/clarification-needed-on-memory-requirements-for-docker-install/151976 "2020-05-19T18:51:42Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![maiki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/maiki/32/233950_2.png) [@maiki](https://meta.discourse.org/u/maiki)\
**Post date:** [May 19, 2020, 8:19pm UTC](https://meta.discourse.org/t/clarification-needed-on-memory-requirements-for-docker-install/151976/4 "2020-05-19T20:19:20Z")

</div>

> [@EricGT](#):
>
> If one ask a provider for a server with 1 GB of ram I take it during the install it would grab an additional 2 GB for swap, thus needing 3 GB. And if the provider limited the machine to 1 GB you now have a problem.
> 
> If one ask a provider for a server with 3 GB of ram I take it during the install it would **NOT** grab an additional 2 GB for swap, thus using 3 GB for just memory.
> 
> If one ask a provider for a server with 4 GB thinking they need 2 GB as normal memory and 2 GB as swap, would using the 4 GB as 2 GB for memory and 2 GB for swap be the best option?

> [@EricGT](#):
>
> We ask for 4 GB or RAM. We don’t ask how it is to be configured. Using web console access we create the virtual machine ourselves and along the way we will be asked to split off part of the 4 GB into a 2 GB swap drive and the leave the other 2 GB as normal memory.

A “swap” is a file on a storage drive.

> **[Memory paging | Swap files and partitions](https://en.wikipedia.org/wiki/Paging#Swap_files_and_partitions)**
>
> From the end-user perspective, swap files in versions 2.6.x and later of the Linux kernel are virtually as fast as swap partitions; the limitation is that swap files should be contiguously allocated on their underlying file systems. To increase performance of swap files, the kernel keeps a map of where they are placed on underlying devices and accesses them directly, thus bypassing the cache and avoiding filesystem overhead. When residing on HDDs, which are rotational magnetic media devi Swappin...

I just wanted to point out, in case there was confusion.

When you provision a server you will know how much RAM is available (in numbers like 1GB, 2GB, or 4GB), but you will also have disk storage, generally available in larger numbers (like 20GB, 30GB, or 40GB).

Your swap will be part of the disk storage. Your RAM is separate. 🕶

---

_[View the full topic](https://meta.discourse.org/t/clarification-needed-on-memory-requirements-for-docker-install/151976)._
