Does more RAM help?
-
I have 128 megs of RAM in the pfsense box. I only have like 5 computers hooked up to it. memory usage is never above 30%, and is usually around 25%. I know that for most operating systems more RAM would help, but would I need it in this case? pfsense is not using the swap file, and I'm guessing it won't until it fills up physical RAM.
And would I actually be able to do with 64 megs of RAM(not going to do it, just curious).
-
I have 128 megs of RAM in the pfsense box. I only have like 5 computers hooked up to it. memory usage is never above 30%, and is usually around 25%. I know that for most operating systems more RAM would help, but would I need it in this case? pfsense is not using the swap file, and I'm guessing it won't until it fills up physical RAM.
Not unless you want/need a huge state table or are running packages such as ntop. My little Soekris 4801 performs admirably with 128M and with a 50K entry state table (it's only using 19 states right now - but BT takes up a lot so I increased it) I'm sitting at 38% memory usage (and I'll have to look at this box since it's also hitting 30+% cpu which is odd for it).
And would I actually be able to do with 64 megs of RAM(not going to do it, just curious).
I wouldn't recommend 64M. We don't create a swap file (I'm not sure if we even activate a swap partition if it's created manually) and you really really wouldn't want your firewall swapping while trying to pass packets, forget wirespeed routing (not that we do that), but disk speed routing shudder I'll pass. 64M will work on a lowend box (I used to run pfSense on 56M way back in the .4x days - it worked just fine) but YMMV and packages will definetly make a difference. Kind of like M$, 64M (technically around 40M) is the minimum to run pfSense, add anything to it or change anything from stock and you really need more. I recommend 128M, it's a safe start, if you run ntop, I wouldn't touch it w/ less than 512M personally, it's a hog.
–Bill
-
yeah, I thought that a swap on a router is bad too. I just thought it existed because there's a little bar on the system page. I figured the reason for the swap would be maybe to keep the whole thing from dying. But not having one makes more sense in a router.
-
Swap should get used very little if you have enough ram.
-
Correct me if I'm wrong but doesn't FreeBSD want to have swap = 2xRAM as part of a limitation of its memory management system?
-
@submicron:
Correct me if I'm wrong but doesn't FreeBSD want to have swap = 2xRAM as part of a limitation of its memory management system?
Hmm, I was going to reply that this is mostly just old school and out of date, but then I found this:
Second, configure sufficient swap. You should have a swap partition configured on each physical disk, up to four, even on your "work" disks. You should have at least 2x the swap space as you have main memory, and possibly even more if you do not have a lot of memory. You should also size your swap partition based on the maximum memory configuration you ever intend to put on the machine so you do not have to repartition your disks later on. If you want to be able to accommodate a crash dump, your first swap partition must be at least as large as main memory and /var/crash must have sufficient free space to hold the dump
in the FreeBSD Internals handbook at http://www2.kr.freebsd.org/handbook-new/internals-vm.html
I still don't think it's as relevant as it once was though. And FWIW, my 4801 has been chugging along happily for the last 8 months w/out swap (and it'd kinda suck to have to dedicate a 256M CF to a swap partition I'll never hit).
–Bill
-
running the full install version here even without swap for month now and haven't seen issues due to that either.