Was trying to build something via Docker on my Raspberry Pi 4 and it kept failing with the above error. The same worked on a VM with no issues, albeit an amd64 one. Finally I saw via dmesg on the Docker host that the build was running out of memory:
1 2 3 4 5 6 7 8 |
[2684203.739480] Out of memory: Kill process 32162 (cc1) score 747 or sacrifice child [2684203.739491] Killed process 32162 (cc1) total-vm:1578180kB, anon-rss:1556964kB, file-rss:0kB, shmem-rss:0kB [2684203.908611] oom_reaper: reaped process 32162 (cc1), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB [2684206.102016] veth724146d: renamed from eth0 [2684206.244902] docker0: port 1(vethbf95d39) entered disabled state [2684206.331927] docker0: port 1(vethbf95d39) entered disabled state [2684206.345703] device vethbf95d39 left promiscuous mode [2684206.345711] docker0: port 1(vethbf95d39) entered disabled state |
Funny, it sacrificed a child! :)
Now trying this on a Pi 4 with more RAM and fingers crossed it works!