I am trying to find out, what's the difference between elixir OTP processes and normal operating system process let's say Linux
. Can somebody put some light on this? I am still confused even after researching.
Asked
Active
Viewed 358 times
1

Mohammed Wahed Khan
- 836
- 2
- 14
- 35

Arjun Singh
- 677
- 6
- 18
-
I don't know how you didn't manage to find info about it but one thing I can recommend is the beam book that you can find here -> https://github.com/happi/theBeamBook – NoDisplayName Nov 29 '17 at 07:18
-
1They share only the name. They are completely different things by all means. – Aleksei Matiushkin Nov 29 '17 at 07:57
-
See also [this question](https://stackoverflow.com/q/2708033/113848) and [this question](https://stackoverflow.com/q/605183/113848), which compare Elixir/Erlang processes to OS threads. (I'd say OS processes are more similar to OS threads than to Elixir/Erlang processes.) – legoscia Nov 29 '17 at 11:10
-
It'd be easier to ask what they have in common than to ask what's different. The answer to what they have in common is the name--that's it. – Onorio Catenacci Nov 30 '17 at 21:08
1 Answers
6
OS processes and OTP processes share the name only. They are completely different things by all means. This is misleading, but this is how it is.
From Elixir’s guide, located at Elixir’s home site (1 click from the home page):
Elixir’s processes should not be confused with operating system processes. Processes in Elixir are extremely lightweight in terms of memory and CPU (unlike threads in many other programming languages). Because of this, it is not uncommon to have tens or even hundreds of thousands of processes running simultaneously.
Refer to the linked page for further info on Elixir processes.

Aleksei Matiushkin
- 119,336
- 10
- 100
- 160
-
Do you think, that's a clear explanation of why elixir processes are different? Although, they are lightweight in terms of memory and CPU but, how? Is it the way memory is allocated or the stack to every process? – Arjun Singh Nov 29 '17 at 08:40
-
1There could not be a clear explanation of why an apple differs from the table. They have nothing in common. Elixir processes are isolated environments in which ErlangVM runs different parts of the code. The margins here are too narrow to describe how Erlang virtual machine works in details. – Aleksei Matiushkin Nov 29 '17 at 08:59