This is the correct approach to measure total memory usage of Firefox or Chrome based browsers. smem -t -P firefox will show PSS of all your firefox processes, followed by a line with total PSS. To see memory usage per-process without double-counting shared memory, you can use sudo atop -R, press M and m, and look in the PSIZE column. The important thing is to watch out for when the disk starts churning, check your memory usage, and respond accordingly.Ĭhecking memory usage of multi-process applications is difficult. I don't know if a 4GB swap partition is too large it might depend what you're doing. The rough balance is between running out of memory and having processes get killed, and having the system hang for so long that you give up and reboot anyway. You can do this even without messing around resizing the partition, because mkswap takes an optional size parameter. In practice, the I/O pattern will be far from optimal.Īfter the difficulty I had with this, I reformatted my swap space to 2GB (several times smaller than before), so the system would not be able to swap as deeply. On the other hand, if you are trying to switch between two different working sets, and it requires swapping 3GB in and out, at 100MB/s it will take at least 60 seconds even if the I/O pattern can be perfectly optimized. Theory says the key concept is thrashing. You won't necessarily see this in all cases where you have more than 3GB of swap. Based on the experiences I had during this, I am not very surprised to hear delays over ten minutes, if you are generating 3GB+ of swap. their memory usage keeps growing over time and never shrinks, so the only way to control it would have been to stop the software and then restart it. I have had problems with a couple of pieces of software with memory leaks. It's usual for Linux to go totally out to lunch, if you overcommit RAM "too much". Remember that random access I/O on your mechanical HDD requires moving a read/write head, which can only do around 100 seeks per second. Overcommitting available RAM, which causes a large amount of swapping, can definitely do this.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |