From: Sage Weil Date: Wed, 15 Jan 2020 19:59:32 +0000 (-0600) Subject: tasks/internal: put kernel.core_pattern in sysctl.conf too X-Git-Tag: 1.1.0~169^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F1395%2Fhead;p=teuthology.git tasks/internal: put kernel.core_pattern in sysctl.conf too This way if systemd restarts or is reinstalled (as it is on el8 at the moment) we won't lose this setting. Signed-off-by: Sage Weil --- diff --git a/teuthology/task/internal/__init__.py b/teuthology/task/internal/__init__.py index a53992303..ad590e96a 100644 --- a/teuthology/task/internal/__init__.py +++ b/teuthology/task/internal/__init__.py @@ -416,6 +416,11 @@ def coredump(ctx, config): '{adir}/coredump'.format(adir=archive_dir), run.Raw('&&'), 'sudo', 'sysctl', '-w', 'kernel.core_pattern={adir}/coredump/%t.%p.core'.format(adir=archive_dir), + run.Raw('&&'), + 'echo', + 'kernel.core_pattern={adir}/coredump/%t.%p.core'.format(adir=archive_dir), + run.Raw('|'), + 'sudo', 'tee', '-a', '/etc/sysctl.conf', ], wait=False, )