Activity log for bug #1814874

Date Who What changed Old value New value Message
2019-02-06 11:07:56 Ken Sharp bug added bug
2019-02-06 11:07:56 Ken Sharp attachment added dmesg.txt https://bugs.launchpad.net/bugs/1814874/+attachment/5236292/+files/dmesg.txt
2019-02-06 11:08:25 Ken Sharp bug watch added https://bugzilla.kernel.org/show_bug.cgi?id=201603
2019-02-06 11:08:25 Ken Sharp bug task added systemd
2019-02-06 11:08:34 Ken Sharp bug task deleted systemd
2019-02-06 11:09:12 Ken Sharp bug task added linux
2019-02-06 12:39:18 Bug Watch Updater linux: status Unknown Confirmed
2019-02-06 12:39:18 Bug Watch Updater linux: importance Unknown High
2019-02-06 12:39:23 Bug Watch Updater bug watch added https://bugzilla.kernel.org/show_bug.cgi?id=198585
2019-03-04 17:03:44 Bug Watch Updater linux: status Confirmed Fix Released
2019-03-04 17:38:05 Ken Sharp tags amd64 apport-bug bionic kernel-bug kernel-bug-exists-upstream amd64 apport-bug bionic kernel-bug kernel-fixed-upstream
2019-04-02 07:47:45 Po-Hsu Lin affects linux-signed-hwe (Ubuntu) linux (Ubuntu)
2019-04-09 09:41:11 Po-Hsu Lin bug added subscriber Po-Hsu Lin
2019-04-09 09:42:24 Po-Hsu Lin linux (Ubuntu): assignee Po-Hsu Lin (cypressyew)
2019-04-09 09:42:26 Po-Hsu Lin linux (Ubuntu): status New In Progress
2019-04-12 04:40:50 Po-Hsu Lin nominated for series Ubuntu Cosmic
2019-04-12 04:40:50 Po-Hsu Lin bug task added linux (Ubuntu Cosmic)
2019-04-12 11:10:51 Po-Hsu Lin nominated for series Ubuntu Bionic
2019-04-12 11:10:51 Po-Hsu Lin bug task added linux (Ubuntu Bionic)
2019-04-12 11:11:00 Po-Hsu Lin linux (Ubuntu Bionic): status New In Progress
2019-04-12 11:11:02 Po-Hsu Lin linux (Ubuntu Cosmic): status New In Progress
2019-04-12 11:11:16 Po-Hsu Lin linux (Ubuntu): status In Progress Fix Released
2019-04-12 11:11:22 Po-Hsu Lin tags amd64 apport-bug bionic kernel-bug kernel-fixed-upstream amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream
2019-04-17 03:28:15 Po-Hsu Lin description Under memory pressure, my VM locks up. This has been reported upstream though I don't know how far any solution has progressed. https://bugzilla.kernel.org/show_bug.cgi?id=201603 Feb 6 07:15:42 vps632258 kernel: [151336.450064] z3fold: unknown buddy id 0 Feb 6 07:15:42 vps632258 kernel: [151336.454450] BUG: unable to handle kernel NULL pointer dereference at 0000000000000008 The little bit of log I managed to salvage is attached. This has happened to two identical VMs. Unusually it has not occurred on a third VM which is configured the same but has less RAM (fingers crossed it won't). Irrelevant information: I thought the lock-ups were due to me using a BTRFS filesystem, however I swapped over to NILFS2 and this still occurs. The only difference seems to be that I am now able to grab some of the kernel output. ProblemType: Bug DistroRelease: Ubuntu 18.04 Package: linux-image-4.18.0-14-generic 4.18.0-14.15~18.04.1 ProcVersionSignature: Ubuntu 4.18.0-14.15~18.04.1-generic 4.18.20 Uname: Linux 4.18.0-14-generic x86_64 ApportVersion: 2.20.9-0ubuntu7.5 Architecture: amd64 Date: Wed Feb 6 10:55:05 2019 ProcEnviron: TERM=xterm PATH=(custom, no user) XDG_RUNTIME_DIR=<set> LANG=en_GB.UTF-8 SHELL=/bin/bash SourcePackage: linux-signed-hwe UpgradeStatus: No upgrade log present (probably fresh install) == Justification == When using z3fold and zswap on a VM under overcommitted memory stress, z3fold will complains about an "unknown buddy id 0" and fail to get a pointer to the mapped allocation in z3fold_map(). z3fold: unknown buddy id 0 WARNING: CPU: 2 PID: 1584 at mm/z3fold.c:971 z3fold_zpool_map+0xce/0x100 [z3fold] And it will leads to a null pointer dereference in zswap BUG: unable to handle kernel NULL pointer dereference at 0000000000000000 PGD 0 P4D 0 Oops: 0000 [#1] SMP PTI CPU: 2 PID: 1584 Comm: stress Tainted: G W 4.18.0-17-generic #18-Ubuntu Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.11.1-1ubuntu1 04/01/2014 RIP: 0010:zswap_writeback_entry+0x4d/0x360 == Fix == ca0246bb (z3fold: fix possible reclaim races) This patch has already in Disco, and can be cherry-picked into B/C. Not needed for Xenial and older kernels as z3fold is not supported. == Test == Test kernels for Bionic / Cosmic could be found here: http://people.canonical.com/~phlin/kernel/lp-1814874-z3fold-zswap/Bionic/ http://people.canonical.com/~phlin/kernel/lp-1814874-z3fold-zswap/Cosmic/ This issue can be reproduced easily in a KVM with the following setup: * 8G disk, 4G RAM, 4 CPUs * 1G swap * "zswap.enabled=1 zswap.zpool=z3fold zswap.max_pool_percent=7" added to grub * "z3fold" module added into /etc/initramfs-tools/modules Stress it with two childs running: * stress --vm-bytes 512M --vm 4 --vm-hang 3 * stress --vm-bytes 512M --vm 4 --vm-hang 7 The VM is expected to crash within 5 minutes. With the patched kernel, the VM can withstand this stress for over an hour with crashing with this issue == Regression potential == Small. Fix limited to z3fold. User needs to enable it explicitly for this feature. == Original Bug Report == Under memory pressure, my VM locks up. This has been reported upstream though I don't know how far any solution has progressed. https://bugzilla.kernel.org/show_bug.cgi?id=201603 Feb 6 07:15:42 vps632258 kernel: [151336.450064] z3fold: unknown buddy id 0 Feb 6 07:15:42 vps632258 kernel: [151336.454450] BUG: unable to handle kernel NULL pointer dereference at 0000000000000008 The little bit of log I managed to salvage is attached. This has happened to two identical VMs. Unusually it has not occurred on a third VM which is configured the same but has less RAM (fingers crossed it won't). Irrelevant information: I thought the lock-ups were due to me using a BTRFS filesystem, however I swapped over to NILFS2 and this still occurs. The only difference seems to be that I am now able to grab some of the kernel output. ProblemType: Bug DistroRelease: Ubuntu 18.04 Package: linux-image-4.18.0-14-generic 4.18.0-14.15~18.04.1 ProcVersionSignature: Ubuntu 4.18.0-14.15~18.04.1-generic 4.18.20 Uname: Linux 4.18.0-14-generic x86_64 ApportVersion: 2.20.9-0ubuntu7.5 Architecture: amd64 Date: Wed Feb 6 10:55:05 2019 ProcEnviron:  TERM=xterm  PATH=(custom, no user)  XDG_RUNTIME_DIR=<set>  LANG=en_GB.UTF-8  SHELL=/bin/bash SourcePackage: linux-signed-hwe UpgradeStatus: No upgrade log present (probably fresh install)
2019-04-23 15:37:16 Kleber Sacilotto de Souza linux (Ubuntu Cosmic): status In Progress Fix Committed
2019-04-23 15:37:18 Kleber Sacilotto de Souza linux (Ubuntu Bionic): status In Progress Fix Committed
2019-04-25 22:32:29 Ubuntu Kernel Bot tags amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-needed-cosmic
2019-04-29 16:04:02 Ubuntu Kernel Bot tags amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-needed-cosmic amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-needed-bionic verification-needed-cosmic
2019-05-08 09:59:16 Po-Hsu Lin tags amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-needed-bionic verification-needed-cosmic amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-done-bionic verification-needed-cosmic
2019-05-09 03:12:38 Po-Hsu Lin tags amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-done-bionic verification-needed-cosmic amd64 apport-bug bionic cosmic kernel-bug kernel-fixed-upstream verification-done-bionic verification-done-cosmic
2019-05-14 19:00:51 Launchpad Janitor linux (Ubuntu Bionic): status Fix Committed Fix Released
2019-05-14 19:00:51 Launchpad Janitor cve linked 2017-5715
2019-05-14 19:00:51 Launchpad Janitor cve linked 2017-5753
2019-05-14 19:00:51 Launchpad Janitor cve linked 2017-5754
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-12126
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-12127
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-12130
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-16884
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-3620
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-3639
2019-05-14 19:00:51 Launchpad Janitor cve linked 2018-3646
2019-05-14 19:00:51 Launchpad Janitor cve linked 2019-3874
2019-05-14 19:00:51 Launchpad Janitor cve linked 2019-3882
2019-05-14 19:00:51 Launchpad Janitor cve linked 2019-9500
2019-05-14 19:00:51 Launchpad Janitor cve linked 2019-9503
2019-05-14 19:04:10 Launchpad Janitor linux (Ubuntu Cosmic): status Fix Committed Fix Released
2019-05-14 19:04:10 Launchpad Janitor cve linked 2019-3887