Why does gnome-terminal use so much memory

gnomememoryxorg

Why does gnome-terminal use so much memory?

I almost never turn my development machine off. Only time it gets turned off really is during power outages. I am almost always either having something build in a gnome-terminal or using VIM in a gnome terminal. I have set the scrolling to something like 65535 lines. I periodically close tabs and clear the buffer but my gnome-terminal process shows in top as having something like 670MB of virt mem and 160MB of res mem. Is this normal? Is there some way of launching more gnome-terminals so that when I close terminals I free the memory instead of it getting eaten by one big process? I know that on occasion, the gnome-terminal will crash and it closes ALL my gnome-terminal windows. (This is when I usually start throwing things.) Anyway to prevent that as well would be awesome, but primority one is how to manage the memory issue.

… This also is happening with Xorg, but a bit less extreme… something like 403MB virt and 32MB res mem.

Thanks,
Chenz

Best Answer

I have set the scrolling to something like 65535 lines.

Have you tried setting this to something more ... sane? Like 5000 lines. Experiment. Correlation may be causation, in this case.

FWIW, my gnome-terminal is 38MB VIRT 15MB RES (while running htop), everything is default, and no compositing.