Does Linux "perform buffered I/O"

clemenza

New Member
Joined
Mar 11, 2022
Messages
3
Reaction score
1
Credits
26
Good day friends,

I am in a course that loves to pose frustratingly vague questions to which I cannot find definitive answers. Last time I fought tooth and nail to argue with an instructor that Linux is multi-user even though it's run on a "personal" computer. (Please correct me if this is wrong).

My question today is: Does Linux "perform buffered I/O"?

My reaction initial reaction is: Well, of course! What modern OS doesn't? But I cannot find a definitive resource that states it plainly so that I can reference it.
So, does it? And would you perhaps know of a reference?

Thank you in advance!
 


Of course Linux is a multi-user environment.

As for the current question - I'd say yes, but I'm not going to dig into the mechanism. The Linux kernel is a schedule. If commands weren't buffered, it'd crash or data would be lost every time there's a queue for the kernel.

Lemme search real quick like...

 
Of course Linux is a multi-user environment.

As for the current question - I'd say yes, but I'm not going to dig into the mechanism. The Linux kernel is a schedule. If commands weren't buffered, it'd crash or data would be lost every time there's a queue for the kernel.

Lemme search real quick like...

Amazing! I will use this as a reference. It's perfect! Thank you.
 
Amazing! I will use this as a reference. It's perfect! Thank you.

No problem. I suspect the majority of OSes are buffered I/O. One exception might be the RTOS, which I have only read about. Still, those must use a buffer, or at least be under very strong constraints.
 
clemenza asked:
Does Linux "perform buffered I/O"?
Yes, for example:
Code:
[tom@owl ~]$ free -h
               total        used        free      shared  buff/cache   available
Mem:           3.8Gi       1.5Gi       611Mi        29Mi       1.7Gi       2.0Gi
Swap:          5.6Gi          0B       5.6Gi
or
Code:
[tom@owl ~]$ cat /proc/meminfo
MemTotal:        3989268 kB
MemFree:          618624 kB
MemAvailable:    2069416 kB
Buffers:          350976 kB
Cached:           684360 kB
<snip>
 
No problem. I suspect the majority of OSes are buffered I/O. One exception might be the RTOS, which I have only read about. Still, those must use a buffer, or at least be under very strong constraints.
I added the reference to RTOS as well after looking up some information about it. Thanks again. :)
 

Members online


Top