how to mimize disk usage

Started by jojothehumanmonkey, January 29, 2023, 01:38:20 AM

Previous topic - Next topic
January 29, 2023, 01:38:20 AM Last Edit: January 29, 2023, 02:18:55 AM by jojothehumanmonkey
hello, thanks,

i am confused, by default, if opnsense using a swap file?
and if so, how to move it to memory, same as "/var/log RAM disk" and "/tmp RAM disk"

from dashboard:
"SWAP usage 0 % ( 0/8192 MB )"

from system_advanced_misc.php, this setting is uncheck.
"Swap file Add a 2 GB swap file to the system"

from /etc/rc.conf, there is no "swapfile=", so does that mean, opnsense is not using swap.

swapinfo -k
Device          1K-blocks     Used    Avail Capacity
/dev/gpt/swapfs   8388608        0  8388608     0%

--------------

also, curious, what else does opnsense write to disk?
--- log files
if this is enabled, where does opnsense save logs?
Local Logging    Disable writing log files to the local disk

--- other stuff i would not know about, the so-called "unknown unkowns"

thanks, david

Hi David, on the subject of logging - consider setting up an external log server and redirect your firewall logs to it. System, settings, logging/targets.

A big part of security is being able to work out what happened if something happens  ;)

Bart...

thanks,

does anyone run `opnsense` from a read-only source, such as a cd-rom or DiskOnModule?