Bug 11423 - Some applications started from gnome-terminal exit when gt exits
Some applications started from gnome-terminal exit when gt exits
Status: CLOSED NOTABUG
Product: Red Hat Linux
Classification: Retired
Component: gnome-core (Show other bugs)
6.2
All Linux
medium Severity medium
: ---
: ---
Assigned To: Havoc Pennington
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-05-15 16:39 EDT by mw
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-05-16 18:27:39 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description mw 2000-05-15 16:39:34 EDT
If I start an Emacs from a gnome-terminal, and then exit the
gnome-terminal, Emacs also exits.  The same happens if I start a
gnome-terminal from the gnome-terminal.

The only *good* application I found was xterm.  Indeed, and xterm started
from a GT does not exist when GT exits.
Comment 1 Havoc Pennington 2000-05-15 17:02:59 EDT
This is how shells work; if you start a job from a shell, then exit the
shell, normally the jobs are all killed. If you want the job to outlast the
shell, use the "disown" command or the "nohup" command - I'll let you
check out the man pages for those.
Comment 2 mw 2000-05-16 16:10:59 EDT
I did not know that gnome-terminal is a shell...

So what if I start several applications from a gnome-terminal, and then,
noticing that the applications clutter up my screen, I quit the gnome-terminal,
and suddenly all my applications are gone (except good old xterm).

In other words, it is expected that the user remembers which terminal is the
father of which application?!

What is wrong with xterm's behavior which takes advantage of X in that it does
*not* have to behave like a shell?
Comment 3 Havoc Pennington 2000-05-16 18:27:59 EDT
xterm behaves exactly the same way as gnome-terminal
as far as I can see.

If you exit the xterm or gnome-terminal, then the child shell
is killed. Most shells (such as bash) kill child processes
when they exit. tcsh won't kill backgrounded processes; bash won't
kill backgrounded processes if you use the "disown" command.
bash also doesn't kill child processes if you exit the shell
using the control-D shortcut. This behavior has existed for
probably 20 years, and is certainly the right behavior
for shells not running inside an xterm, so I don't think
the shell maintainers will accept a patch to change it.

If you see a difference in how gnome-terminal and xterm
behave, I can look into that, but they work the same on
my computer, so I need more details to figure out why
they seem different on yours.

The "disown" command and the tcsh behavior for background
processes are supposed to solve exactly this problem,
so I would recommend taking advantage of those features.

Note You need to log in before you can comment on or make changes to this bug.