What decides where core dump files are created?

Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
Does /proc/sys/kernel/core_pattern decide where core dump files are created? Mine looks like
$ cat /proc/sys/kernel/core_pattern
|/usr/share/apport/apport %p %s %c %d %P
which I guess means to pipe the core dump to the apport script. Will the apport script write the input core dump to some file? If yes, where will the file be created? (My /var/crash/ doesn't have a core dump file from the following commands, and /var/lib/systemd/coredump/ is always empty for the following commands.)
When the soft limit for core file is 0, there is no core dump file in the current directory. Where is it created? ("If the message says “(core dumped)” then core really was dumped.")
$ ulimit -S -c
0
$ sleep 10
^bash: line 1: 11837 Quit (core dumped) sleep 10
$ ls core
ls: cannot access 'core': No such file or directory
When I increase the soft limit, why do I get a core dump file in the current working directory?
$ ulimit -S -c 1024;
$ ulimit -S -c;
1024
$ sleep 10
^Quit (core dumped)
$ ls core
core
Thanks.
ubuntu core-dump
add a comment |
up vote
1
down vote
favorite
Does /proc/sys/kernel/core_pattern decide where core dump files are created? Mine looks like
$ cat /proc/sys/kernel/core_pattern
|/usr/share/apport/apport %p %s %c %d %P
which I guess means to pipe the core dump to the apport script. Will the apport script write the input core dump to some file? If yes, where will the file be created? (My /var/crash/ doesn't have a core dump file from the following commands, and /var/lib/systemd/coredump/ is always empty for the following commands.)
When the soft limit for core file is 0, there is no core dump file in the current directory. Where is it created? ("If the message says “(core dumped)” then core really was dumped.")
$ ulimit -S -c
0
$ sleep 10
^bash: line 1: 11837 Quit (core dumped) sleep 10
$ ls core
ls: cannot access 'core': No such file or directory
When I increase the soft limit, why do I get a core dump file in the current working directory?
$ ulimit -S -c 1024;
$ ulimit -S -c;
1024
$ sleep 10
^Quit (core dumped)
$ ls core
core
Thanks.
ubuntu core-dump
Does the last part (acorefile is created in the current directory ifulimit -c unlimitedwas set) also happen if you set (as root)systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed withSIGQUITto report(core dumped), but no core file to be written anywhere).
– mosvy
Dec 2 at 4:13
1
stackoverflow.com/a/18368068/10306503, especially the part about howapportis doing itself the core file creation in cwd
– mosvy
Dec 2 at 5:08
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
Does /proc/sys/kernel/core_pattern decide where core dump files are created? Mine looks like
$ cat /proc/sys/kernel/core_pattern
|/usr/share/apport/apport %p %s %c %d %P
which I guess means to pipe the core dump to the apport script. Will the apport script write the input core dump to some file? If yes, where will the file be created? (My /var/crash/ doesn't have a core dump file from the following commands, and /var/lib/systemd/coredump/ is always empty for the following commands.)
When the soft limit for core file is 0, there is no core dump file in the current directory. Where is it created? ("If the message says “(core dumped)” then core really was dumped.")
$ ulimit -S -c
0
$ sleep 10
^bash: line 1: 11837 Quit (core dumped) sleep 10
$ ls core
ls: cannot access 'core': No such file or directory
When I increase the soft limit, why do I get a core dump file in the current working directory?
$ ulimit -S -c 1024;
$ ulimit -S -c;
1024
$ sleep 10
^Quit (core dumped)
$ ls core
core
Thanks.
ubuntu core-dump
Does /proc/sys/kernel/core_pattern decide where core dump files are created? Mine looks like
$ cat /proc/sys/kernel/core_pattern
|/usr/share/apport/apport %p %s %c %d %P
which I guess means to pipe the core dump to the apport script. Will the apport script write the input core dump to some file? If yes, where will the file be created? (My /var/crash/ doesn't have a core dump file from the following commands, and /var/lib/systemd/coredump/ is always empty for the following commands.)
When the soft limit for core file is 0, there is no core dump file in the current directory. Where is it created? ("If the message says “(core dumped)” then core really was dumped.")
$ ulimit -S -c
0
$ sleep 10
^bash: line 1: 11837 Quit (core dumped) sleep 10
$ ls core
ls: cannot access 'core': No such file or directory
When I increase the soft limit, why do I get a core dump file in the current working directory?
$ ulimit -S -c 1024;
$ ulimit -S -c;
1024
$ sleep 10
^Quit (core dumped)
$ ls core
core
Thanks.
ubuntu core-dump
ubuntu core-dump
edited Dec 2 at 3:01
asked Dec 2 at 2:48
Tim
25.3k72243446
25.3k72243446
Does the last part (acorefile is created in the current directory ifulimit -c unlimitedwas set) also happen if you set (as root)systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed withSIGQUITto report(core dumped), but no core file to be written anywhere).
– mosvy
Dec 2 at 4:13
1
stackoverflow.com/a/18368068/10306503, especially the part about howapportis doing itself the core file creation in cwd
– mosvy
Dec 2 at 5:08
add a comment |
Does the last part (acorefile is created in the current directory ifulimit -c unlimitedwas set) also happen if you set (as root)systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed withSIGQUITto report(core dumped), but no core file to be written anywhere).
– mosvy
Dec 2 at 4:13
1
stackoverflow.com/a/18368068/10306503, especially the part about howapportis doing itself the core file creation in cwd
– mosvy
Dec 2 at 5:08
Does the last part (a
core file is created in the current directory if ulimit -c unlimited was set) also happen if you set (as root) systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed with SIGQUIT to report (core dumped), but no core file to be written anywhere).– mosvy
Dec 2 at 4:13
Does the last part (a
core file is created in the current directory if ulimit -c unlimited was set) also happen if you set (as root) systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed with SIGQUIT to report (core dumped), but no core file to be written anywhere).– mosvy
Dec 2 at 4:13
1
1
stackoverflow.com/a/18368068/10306503, especially the part about how
apport is doing itself the core file creation in cwd– mosvy
Dec 2 at 5:08
stackoverflow.com/a/18368068/10306503, especially the part about how
apport is doing itself the core file creation in cwd– mosvy
Dec 2 at 5:08
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
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%2f485426%2fwhat-decides-where-core-dump-files-are-created%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
Does the last part (a
corefile is created in the current directory ifulimit -c unlimitedwas set) also happen if you set (as root)systctl kernel.core_pattern='|/bin/true'? (this should cause a process killed withSIGQUITto report(core dumped), but no core file to be written anywhere).– mosvy
Dec 2 at 4:13
1
stackoverflow.com/a/18368068/10306503, especially the part about how
apportis doing itself the core file creation in cwd– mosvy
Dec 2 at 5:08