To see how much RAM memory your computer has, use
For limiting MEM usage of a user, which also limits the programs ran under it
/boot/loader.conf
This must be compiled into the kernel, if it's not already there.
For myusername, use your user or any other group listed in /etc/group:
Also, enter this exact line into /etc/rctl.conf. deny says the max amount that can be used by this user. See https://klarasystems.com/articles/controlling-resource-limits-with-rctl-in-freebsd/.
For dedicating an amount of RAM memory to kernel
/etc/sysctl.conf
Also, use this on the command line with sysctl to make it take effect immediately. To see set values, use
Need more ways of limiting/dedicating RAM and memory usage
On my computer, Firefox often causes FreeBSD to freeze up, and I can't get out without shutting off the computer. Hopefully, the above help.
To find the WM class of desktop programs, use
dmesg|grep -i memory
.For limiting MEM usage of a user, which also limits the programs ran under it
/boot/loader.conf
Code:
kern.racct.enable="1"
For myusername, use your user or any other group listed in /etc/group:
rctl -a user:myusername:memoryuse:deny=3840K
Also, enter this exact line into /etc/rctl.conf. deny says the max amount that can be used by this user. See https://klarasystems.com/articles/controlling-resource-limits-with-rctl-in-freebsd/.
For dedicating an amount of RAM memory to kernel
/etc/sysctl.conf
Code:
hw.physmem=512K
sysctl -a
with | grep
. See, sysctl(3) for details.Need more ways of limiting/dedicating RAM and memory usage
On my computer, Firefox often causes FreeBSD to freeze up, and I can't get out without shutting off the computer. Hopefully, the above help.
To find the WM class of desktop programs, use
xprop|grep -i class
. Could use some help on using this WM class to restrict RAM/CPU usage for these programs. Then, may need to look at limits(1).process allocation
forums.freebsd.org