On 05/11/15 at 04:40am, Chao Fan wrote:
Takeshi Nishimura fonud a bug, that vmcore is not created if panic occurs during
We find when shutdown, the kdump will stopped by systemd and then
kdump will not work if kernel crash.
"Kdump cannot dump the vmcore successfully, if the kernel crash happens
during the machine is stopping. The reason why kdump fails to dump
vmcore is kdump is stopped too early during the power is off."
In RHEL-6,kdump will not be stopped when shutdown, but it will be in RHEL-7.
I change the file of kdump.service and add "DefaultDependencies=no" to the
[Unit] of kdump.service to make kdump not stopped by systemd after shutdown
The manpage of systemd.unit about the DefaultDependencies:Takes a boolean ar
gument. If true, (the default), a few default dependencies will implicitly b
e created for the unit. The actual dependencies created depend on the unit ty
pe. For example, for service units, these dependencies ensure that the ser
vice is started only after basic system initialization is completed and is pro
perly terminated on system shutdown. See the respective man pages for details
. Generally, only services involved with early boot or late shutdown should s
et this option to false. It is highly recommended to leave this option enabl
ed for the majority of common units. If set to false, this option does not d
isable all implicit dependencies, just non-essential ones.
It is appropriate to change the commit log format to make it more
clearly to be reviewed.
The mail to the
And follow the suggestion of systemd, add "basic.target" to "After="
It is prefer to explain why you should append the basic.target. Maybe it
is better to paste the basic.target manpage here.
e kdump can run auto when power on.
Signed-off-by: Chao Fan <cfan(a)redhat.com>
kdump.service | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/kdump.service b/kdump.service
index 24c1386..5144597 100644
@@ -1,6 +1,7 @@
Description=Crash recovery kernel arming
-After=network.target network-online.target remote-fs.target
+After=network.target network-online.target remote-fs.target basic.target
kexec mailing list