GNU bug report logs - #65446
[berlin] guix gc throws: "error: build daemon out of memory"

Previous Next

Package: guix;

Reported by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Date: Tue, 22 Aug 2023 02:20:02 UTC

Severity: important

To reply to this bug, email your comments to 65446 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#65446; Package guix. (Tue, 22 Aug 2023 02:20:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Maxim Cournoyer <maxim.cournoyer <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Tue, 22 Aug 2023 02:20:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: bug-guix <bug-guix <at> gnu.org>
Subject: [cuirass] guix gc throws: "error: build daemon out of memory"
Date: Mon, 21 Aug 2023 22:19:25 -0400
Hi,

Since a few days on Berlin, the following appears in /var/log/mcron.log:

--8<---------------cut here---------------start------------->8---
2023-08-22 04:00:29 28215 /gnu/store/4lmpqf8dnk86avq5xa2l6bznxnmrz27x-guix-1.4.0-7.44bbfc2/bin/guix gc: guix gc: error: build daemon out of memory
--8<---------------cut here---------------end--------------->8---

It's not just a fluke, according to the kernel's dmesg:

--8<---------------cut here---------------start------------->8---
[7190243.475312] __vm_enough_memory: pid: 28300, comm: guix-daemon, not enough memory for the allocation
--8<---------------cut here---------------end--------------->8---

Once it appears, it can be triggered simply by running 'guix gc'.  The
problem can be worked around by restarting the Guix daemon, with:

--8<---------------cut here---------------start------------->8---
herd restart guix-daemon
--8<---------------cut here---------------end--------------->8---

Any ideas what could cause such a condition?

The machine hasn't been rebooted in 83 days, perhaps we should start
with that.

-- 
Thanks,
Maxim




Changed bug title to '[berlin] guix gc throws: "error: build daemon out of memory"' from '[cuirass] guix gc throws: "error: build daemon out of memory"' Request was from Maxim Cournoyer <maxim.cournoyer <at> gmail.com> to control <at> debbugs.gnu.org. (Sun, 27 Aug 2023 01:37:02 GMT) Full text and rfc822 format available.

Severity set to 'important' from 'normal' Request was from Ludovic Courtès <ludo <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 02 Sep 2023 16:38:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#65446; Package guix. (Sat, 02 Sep 2023 20:35:02 GMT) Full text and rfc822 format available.

Message #12 received at 65446 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: 65446 <at> debbugs.gnu.org, Leo Famulari <leo <at> famulari.name>
Subject: Re: bug#65446: [berlin] guix gc throws: "error: build daemon out of
 memory"
Date: Sat, 02 Sep 2023 22:33:44 +0200
Hi!

Maxim Cournoyer <maxim.cournoyer <at> gmail.com> skribis:

> Since a few days on Berlin, the following appears in /var/log/mcron.log:
>
> 2023-08-22 04:00:29 28215 /gnu/store/4lmpqf8dnk86avq5xa2l6bznxnmrz27x-guix-1.4.0-7.44bbfc2/bin/guix gc: guix gc: error: build daemon out of memory
>
>
> It's not just a fluke, according to the kernel's dmesg:
>
> [7190243.475312] __vm_enough_memory: pid: 28300, comm: guix-daemon, not enough memory for the allocation
>
>
> Once it appears, it can be triggered simply by running 'guix gc'.  The
> problem can be worked around by restarting the Guix daemon, with:
>
> herd restart guix-daemon
>
> Any ideas what could cause such a condition?

No idea!

I ran “guix gc -C0” minutes ago, which reproduced the problem;
/var/log/guix-daemon.log reads this:

--8<---------------cut here---------------start------------->8---
2023-09-02 21:40:31 accepted connection from pid 12853, user ludo
2023-09-02 21:40:50 unexpected build daemon error: std::bad_alloc
--8<---------------cut here---------------end--------------->8---

and the kernel writes what you wrote above:

--8<---------------cut here---------------start------------->8---
Sep  2 21:40:50 localhost vmunix: [8204269.198144] __vm_enough_memory: pid: 12873, comm: guix-daemon, not enough memory for the allocation
Sep  2 21:40:50 localhost vmunix: [8204269.207396] __vm_enough_memory: pid: 12873, comm: guix-daemon, not enough memory for the allocation
Sep  2 21:40:50 localhost vmunix: [8204269.216639] __vm_enough_memory: pid: 12873, comm: guix-daemon, not enough memory for the allocation
--8<---------------cut here---------------end--------------->8---

My reading of the Linux code is ‘__vm_enough_memory’ is used by Linux
Security Modules (LSM), so perhaps something changed in our kernel
config, be it compile-time or run-time?  (Cc: Leo just in case.)

This is with Linux-libre 6.3.4-gnu.

Ludo’.




Information forwarded to bug-guix <at> gnu.org:
bug#65446; Package guix. (Tue, 17 Dec 2024 04:12:02 GMT) Full text and rfc822 format available.

Message #15 received at 65446 <at> debbugs.gnu.org (full text, mbox):

From: "Collin J. Doering" <collin <at> rekahsoft.ca>
To: 65446 <at> debbugs.gnu.org
Subject: [berlin] guix gc throws: "error: build daemon out of memory"
Date: Mon, 16 Dec 2024 23:11:00 -0500
[Message part 1 (text/plain, inline)]
Perhaps worth noting that I've seen this numerous times on cuirass.genenetwork.org.

Usually restarting guix-daemon will allow 'guix gc' to complete without error. I see dmesg errors that match what Ludo provided.

Kind regards

-- 
Collin J. Doering

http://rekahsoft.ca
http://blog.rekahsoft.ca
http://git.rekahsoft.ca
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#65446; Package guix. (Wed, 18 Dec 2024 02:07:02 GMT) Full text and rfc822 format available.

Message #18 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: "Collin J. Doering" via Bug reports for GNU Guix <bug-guix <at> gnu.org>
Cc: 65446 <at> debbugs.gnu.org, "Collin J. Doering" <collin <at> rekahsoft.ca>
Subject: Re: bug#65446: [berlin] guix gc throws: "error: build daemon out of
 memory"
Date: Wed, 18 Dec 2024 11:05:55 +0900
Hello,

"Collin J. Doering" via Bug reports for GNU Guix <bug-guix <at> gnu.org>
writes:

> Perhaps worth noting that I've seen this numerous times on cuirass.genenetwork.org.
>
> Usually restarting guix-daemon will allow 'guix gc' to complete
> without error. I see dmesg errors that match what Ludo provided.

Thanks for tipping in; it's a useful thing to know the bug is
reproducible in other environments.

-- 
Thanks,
Maxim




Information forwarded to bug-guix <at> gnu.org:
bug#65446; Package guix. (Wed, 18 Dec 2024 02:08:02 GMT) Full text and rfc822 format available.

This bug report was last modified 240 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.