Does an interactive bash process implicitly send any signal other than SIGHUP to its job?
Does an interactive bash process implicitly send any signal other than SIGHUP to its job? By implicitly, I mean not as a consequence of a user's request to send a signal to a job.
It helps to answer Does `disown` apply only to SIGHUP or some or all the signals?
bash signals job-control
add a comment |
Does an interactive bash process implicitly send any signal other than SIGHUP to its job? By implicitly, I mean not as a consequence of a user's request to send a signal to a job.
It helps to answer Does `disown` apply only to SIGHUP or some or all the signals?
bash signals job-control
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday
add a comment |
Does an interactive bash process implicitly send any signal other than SIGHUP to its job? By implicitly, I mean not as a consequence of a user's request to send a signal to a job.
It helps to answer Does `disown` apply only to SIGHUP or some or all the signals?
bash signals job-control
Does an interactive bash process implicitly send any signal other than SIGHUP to its job? By implicitly, I mean not as a consequence of a user's request to send a signal to a job.
It helps to answer Does `disown` apply only to SIGHUP or some or all the signals?
bash signals job-control
bash signals job-control
edited yesterday
Stephen Kitt
165k24366445
165k24366445
asked yesterday
Tim
26.2k74246455
26.2k74246455
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday
add a comment |
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday
add a comment |
1 Answer
1
active
oldest
votes
Yes, there are a number of instances which can be found by searching calls to kill
and killpg
in jobs.c
in the Bash source code.
One example is the handling of stopped jobs when exec
is run, or when the shell exits: the shell sends SIGTERM
and SIGCONT
to all stopped jobs.
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sendingSIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).
– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What doesdisown
do? How does Bash know which processes are jobs it is supposed to manage?
– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
|
show 9 more comments
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492471%2fdoes-an-interactive-bash-process-implicitly-send-any-signal-other-than-sighup-to%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Yes, there are a number of instances which can be found by searching calls to kill
and killpg
in jobs.c
in the Bash source code.
One example is the handling of stopped jobs when exec
is run, or when the shell exits: the shell sends SIGTERM
and SIGCONT
to all stopped jobs.
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sendingSIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).
– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What doesdisown
do? How does Bash know which processes are jobs it is supposed to manage?
– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
|
show 9 more comments
Yes, there are a number of instances which can be found by searching calls to kill
and killpg
in jobs.c
in the Bash source code.
One example is the handling of stopped jobs when exec
is run, or when the shell exits: the shell sends SIGTERM
and SIGCONT
to all stopped jobs.
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sendingSIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).
– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What doesdisown
do? How does Bash know which processes are jobs it is supposed to manage?
– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
|
show 9 more comments
Yes, there are a number of instances which can be found by searching calls to kill
and killpg
in jobs.c
in the Bash source code.
One example is the handling of stopped jobs when exec
is run, or when the shell exits: the shell sends SIGTERM
and SIGCONT
to all stopped jobs.
Yes, there are a number of instances which can be found by searching calls to kill
and killpg
in jobs.c
in the Bash source code.
One example is the handling of stopped jobs when exec
is run, or when the shell exits: the shell sends SIGTERM
and SIGCONT
to all stopped jobs.
answered yesterday
Stephen Kitt
165k24366445
165k24366445
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sendingSIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).
– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What doesdisown
do? How does Bash know which processes are jobs it is supposed to manage?
– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
|
show 9 more comments
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sendingSIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).
– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What doesdisown
do? How does Bash know which processes are jobs it is supposed to manage?
– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
Thanks. (1) are such cases rare? (2) I don't know how to search for kill in the online hosted repository, even though you might have mentioned it before a little.
– Tim
yesterday
(1) As rare, or otherwise, as sending
SIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).– Stephen Kitt
yesterday
(1) As rare, or otherwise, as sending
SIGHUP
. (2) Ctrl+F in your browser works wonders when searching in a single file ;-).– Stephen Kitt
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
Does disown make interactive bash not send signals other than SIGHUP to a job?
– Tim
yesterday
That question is nonsensical. What does
disown
do? How does Bash know which processes are jobs it is supposed to manage?– Stephen Kitt
yesterday
That question is nonsensical. What does
disown
do? How does Bash know which processes are jobs it is supposed to manage?– Stephen Kitt
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
Does this make sense? Does disown apply to SIGHUP only or also to some other signal(s)?
– Tim
yesterday
|
show 9 more comments
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492471%2fdoes-an-interactive-bash-process-implicitly-send-any-signal-other-than-sighup-to%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
the source code of bash does. e.g. interactive bash's SIGHUP handler does, huponexited and interactive bash's pre-termination cleanup does.
– Tim
yesterday
to bash user, what bash does is implicit. to bash, what the kernel does is implicit. I meant the former.
– Tim
yesterday