]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
99memstrack: Only start tracking service when rd.memdebug=4|5
authorKairui Song <kasong@redhat.com>
Wed, 10 Jun 2020 10:28:27 +0000 (18:28 +0800)
committerDaniel Molkentin <daniel@molkentin.de>
Tue, 4 Aug 2020 10:53:14 +0000 (12:53 +0200)
Currently systemd will always start the tracking service, it will
exit early if rd.memdebug<=3 so there is no issue here, but it
leave a message of: "Started Memstrack Anylazing Service.".
Better to avoid such message if it's not used.

Signed-off-by: Kairui Song <kasong@redhat.com>
modules.d/99memstrack/memstrack.service

index c9fcadef9c5bc83d4abd2505bafbd59185e86d59..fce373b54a2f3656c4c3ee9fa6ed61d25b3442ef 100644 (file)
@@ -3,6 +3,8 @@ Description=Memstrack Anylazing Service
 DefaultDependencies=no
 Before=dracut-cmdline.service systemd-udevd.service local-fs-pre.target
 IgnoreOnIsolate=true
+ConditionKernelCommandLine=|rd.memdebug=4
+ConditionKernelCommandLine=|rd.memdebug=5
 
 [Service]
 Type=simple