Question about tmpfs

Hello,

I have a question about tmpfs.

On my raspberry pi I with only 256 MB RAM df looks like.

root@pi:~# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/root 15G 2.0G 13G 14% /
devtmpfs 111M 0 111M 0% /dev
tmpfs 115M 0 115M 0% /dev/shm
tmpfs 115M 13M 102M 11% /run
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 115M 0 115M 0% /sys/fs/cgroup
/dev/mmcblk0p1 56M 20M 37M 36% /boot
tmpfs 23M 0 23M 0% /run/user/33
tmpfs 23M 0 23M 0% /run/user/0

Is tmpfs “overload”?
What happens when a add a new tmpfs partition e.g for squid?

Is there a way to manipulate the size of the “default” tmpfs shown
above? In /etc/fstab I cant found anything about tmpfs.

root@pi:~# cat /etc/fstab
proc /proc proc defaults 0 0
/dev/mmcblk0p1 /boot vfat defaults 0 2
/dev/mmcblk0p2 / ext4 defaults,noatime 0 1

a swapfile is not a swap partition, no line here

use dphys-swapfile swap[on|off] for that

root@pi:~#

Hi,

This is probably not related to Nginx, you might want to visit Linux
forums or lists for more detailed information. However, having tmpfs
mounted at those directories is a normal mode of operation in many Linux
distros. They are mounted automatically, and typically you don’t need to
worry about them.

I recommend reading at least the section about tmpfs in mount(8) manual
page:

On Thursday, April 28, 2016 11:47:18 AM basti wrote:

tmpfs 115M 0 115M 0% /dev/shm
Is there a way to manipulate the size of the “default” tmpfs shown


nginx mailing list
[email protected]
nginx Info Page

Sincerely yours,
Styopa S…

What happens when a add a new tmpfs partition e.g for squid?

tmpfs uses also swap.
So if you make the fs larger than actual ram and it starts to go beyond
the
physical memory limit things will be swaped out to disk (harddrive) and
everything might become slow(er).

In general if you can’t fit the data in ram it’s not a good idea also
linux
file cache should keep accessed files in ram so unless you suffer from
write
speeds (even those if not specifically O_DIRECT will go to ram first and
later flushed) the reads will come as much as possible from ram anyways.

rr