You are not logged in.

#1 2020-06-26 13:31:02

g0nz085
Member
Registered: 2020-06-26
Posts: 5

dev and run file systems using half of my RAM, making them 32 Gig in s

Is there any way I can force the dev and run files systems to not be 1/2 of my available system memory. This is currently making them 32Gig in size, which is far too much IMO.

I've managed to reduce the other, pure tmpfs file system size, but would really like to get these reduced too:

gonzo@Titan  ~  df -h
Filesystem                                            Size  Used Avail Use% Mounted on
dev                                                    32G     0   32G   0% /dev
run                                                    32G  1.5M   32G   1% /run
/dev/mapper/root                                       98G  9.2G   84G  10% /
tmpfs                                                 2.0G   85M  2.0G   5% /dev/shm
tmpfs                                                 2.0G     0  2.0G   0% /sys/fs/cgroup
tmpfs                                                 2.0G     0  2.0G   0% /run/user/1000
tmpfs                                                 2.0G   32K  2.0G   1% /tmp
/dev/sda1                                             511M  126M  386M  25% /boot
/dev/mapper/var                                        98G  7.9G   86G   9% /var
/dev/mapper/home                                      1.3T  162G  1.1T  14% /home

Offline

#2 2020-06-26 14:11:46

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 10,496

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

https://wiki.archlinux.org/index.php/Tmpfs#Examples read the blue note for why this ultimately is irrelevant for most normal circumstances.

Last edited by V1del (2020-06-26 14:14:25)

Offline

#3 2020-06-26 15:12:46

g0nz085
Member
Registered: 2020-06-26
Posts: 5

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

I've been seeing my RAM usage randomly jump up to around 26Gig with no processes using anywhere near that level of RAM, and the clearing down of all processes not releasing the memory without a full OS restart.

I'm trying to ensure this usage isn't being caused by a large file being written too and then removed from one of these tmp file systems, hence me attempting to reduce them all down and control them.

Offline

#4 2020-06-26 15:27:27

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 9,961
Website

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

How are you measuring that? Have you seen https://www.linuxatemyram.com/?


Sakura:-
Mobo: MSI X299 TOMAHAWK ARCTIC // Processor: Intel Core i7-7820X 3.6GHz // GFX: nVidia GeForce GTX 970 // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 5x 1TB HDD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#5 2020-06-26 15:32:35

g0nz085
Member
Registered: 2020-06-26
Posts: 5

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

I have a system monitor tool on my task bar. When I see it jump (from around 5Gig when normally using the PC) to around 22Gig, I'm using htop, free  and ps to try and identify how the RAM is being used (it's not being hogged by caching) and what is using it, but nothing obvious is showing up.

Also killing off typical ram hungry processes like google chrome isn't making much of a dent in freeing up the RAM.

BTW, I'm a senior linux and network sysadmin, I'm aware that linux uses RAM for caching etc, that you wouldn't see under windows, and I am aware of that web page.

Offline

#6 2020-06-26 15:53:24

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 24,260
Website

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

You can see in the `df` output exactly how much ram is actually being used by /dev/ and /run/.  If they were the culprit you were looking for, you'd see it.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#7 2020-06-26 15:57:48

g0nz085
Member
Registered: 2020-06-26
Posts: 5

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

Only if it's releasing the ram after use.

As previously stated, I can't see anything that is explaining the current RAM usage. Also as previously stated, assigning them 32 Gig of RAM is ludicrous any way, so it should be configurable, thought that was the point of Arch Linux especially.

Offline

#8 2020-06-26 15:59:33

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 24,260
Website

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

g0nz085 wrote:

... it should be configurable, thought that was the point of Arch Linux especially.

It is.  You were given the link to simple instructions on how to configure it in the first response.  If that's what you were really looking for, please remember to mark the thread as SOLVED.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#9 2020-06-26 16:02:48

g0nz085
Member
Registered: 2020-06-26
Posts: 5

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

Some directories where tmpfs(5) is commonly used are /tmp, /var/lock and /var/run. Do not use it on /var/tmp, because that folder is meant for temporary files that are preserved across reboots.

Arch uses a tmpfs /run directory, with /var/run and /var/lock simply existing as symlinks for compatibility. It is also used for /tmp by the default systemd setup and does not require an entry in fstab unless a specific configuration is needed.

glibc 2.2 and above expects tmpfs to be mounted at /dev/shm for POSIX shared memory. Mounting tmpfs at /dev/shm is handled automatically by systemd and manual configuration in fstab is not necessary.

Generally, tasks and programs that run frequent read/write operations can benefit from using a tmpfs folder. Some applications can even receive a substantial gain by offloading some (or all) of their data onto the shared memory. For example, relocating the Firefox profile into RAM shows a significant improvement in performance.

No mention of dev, which should be a udev file system and not tmpfs, s which I did ask for in my original request ......

Offline

#10 2020-06-27 00:31:19

loqs
Member
Registered: 2014-03-06
Posts: 11,694

Re: dev and run file systems using half of my RAM, making them 32 Gig in s

As all arch kernels are built with CONFIG_TMPFS=y devtmpfs will take the same options as tmpfs https://github.com/torvalds/linux/blob/ … mpfs.c#L70
Edit:
If you posted the outputs from free and ps others could examine them to help locate what is using the memory.  The contents of /proc/vmstat would also be helpful.
So far the only output you have posted shows /dev using 0M and /run using 1.5M

Last edited by loqs (2020-06-27 01:35:12)

Offline

Board footer

Powered by FluxBB