Red Hat Bugzilla – Bug 222621
Memory leak in "gnome-terminal"
Last modified: 2014-11-06 03:45:25 EST
Description of problem:
An instance of "gnome-terminal" with high volume output consumes
more and more memory as time goes by. This becomes apparent as
the system gets slower and starts swapping memory to the disk.
A representative entry in "top" output reads:
"2690 test 15 0 381m 188m 6924 S 2.0 37.8 65:35.22 gnome-terminal"
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Launch "gnome-terminal".
2. Execute a program with high volume output.
Over the time, "gnome-terminal" grabs more and more memory up to
the point where the impact on system performance becomes clearly
An instance of "gnome-terminal" should not require more than a
couple of MB instead of a three figure amount.
After closing the terminal window, the allocated memory gets
released as "gnome-system-monitor" indicates, and the system
returns to normal operation.
Issue probably related or identical to
Created attachment 145859 [details]
Release of memory and swap space after closing "gnome-terminal"
As illustrated by the screenshot, a huge amount of memory and of swap
space gets freed after closing "gnome-terminal".
I am currently again running "FC5" on my system, and it turns out
that "gnome-terminal-2.14.2-1" is totally unaffected by the issue
This seems like just heap fragmentation. Known issue.
Also unaffected is "gnome-terminal-2.16.0-2.fc6". So, this seems to be
a problem with the current 2.17.x development series.
I just installed FC7 Test 2 with all of the updates as of today. I think
gnome-terminal (2.17.92-1.fc7) consumes a lot of memory just with a fresh start.
In gnome-system-monitor it shows a bigger resident memory that for ex: nautilus
and is among the bigger ones. I can't confirm the number right now because I am
running yum in a terminal but I will post them here as soon as I get them.
I don't remember gnome-terminal being as big as this, may be this is something
new in Gnome 2.18 series.
Any idea on how to get more information about this, I am using a spare machine
so I can keep it up to date with rawhide to make testing.
Created attachment 149235 [details]
fresh started gnome desktop on Fedora 7 Test 2
Created attachment 149236 [details]
Same desktop after executing gnome-terminal
It consumes almost the same memory as nautilus.
Created attachment 149237 [details]
This is from Ubuntu Edgy Gnome 2.16
gnome-terminal in Ubuntu use less memory. I don't remember how much memory use
g-t in Fedora Core 6. I'll have to check tomorrow in my office computer.
(In reply to comment #6)
I do not see your point. Memory consumption of "gnome-terminal" does not
look excessive in your case. Your screenshot from comment #7 does not
even show a single "gnome-terminal" process running!
Btw, it seems to me that the issue has already been resolved as of
"gnome-terminal-2.17.92-1.fc7". Expect this bug to be closed some time
(In reply to comment #10)
After some "stress testing", I have to revoke my statement of comment #10.
"gnome-terminal-2.17.92-1.fc7" still has the same huge memory footprint
when applications with a high output volume to the shell are used.
(In reply to comment #10)
> I do not see your point. Memory consumption of "gnome-terminal" does not
> look excessive in your case. Your screenshot from comment #7 does not
> even show a single "gnome-terminal" process running!
> Btw, it seems to me that the issue has already been resolved as of
> "gnome-terminal-2.17.92-1.fc7". Expect this bug to be closed some time
Yes, you are right: memory consumption doesn't look that high, I am just
comparing with Ubuntu which is about 4 megs lower (14,8 MB) and right now I am
seeing gnome-terminal from FC6 and it says 13,1 MB of RSS.
May be this is just because of debugging symbols or build parameters during the
testing period so it doesn't seem like a problem.
BTW, I use a lot gnome-terminal and I have not seen the problem you are
reporting, I am going to stress test g-t in Fedora 7 and see what happens.
Seems to be gone as of "gnome-terminal-2.18.0-1.fc7".
Created attachment 954363 [details]
Demonstration that the problem still exists
The system is running GNOME and is monitored by Nagios.
It is one of a number running similar Linux-based operating systems, software and applications (including Virtual machines on VirtualBox) in a business environment. It is the only system in the business running GNOME. Very shortly it won't be running GNOME any more so I won't be able to add further to this thread.
The other systems (running XFCE) don't show this behaviour.