I got this in a cron email from a Bitnami Linux machine hosted on Azure:
/etc/cron.daily/apt:
FATAL -> Failed to fork.
following by this one for a few days once a day:
/etc/cron.daily/apt:
DB Update failed, database locked
Then it cleared up for a few days on its own, then it came back.
There are several suggestions in this ServerFault thread:
https://serverfault.com/questions/626836/apt-fatal-failed-to-fork
This server didn’t have a Swap file (don’t know why), so I set one up as suggested here:
https://serverfault.com/a/814694/166311
I followed these instructions, but making it a hidden file and 2GB in size since I have 2GB of memory:
https://docs.bitnami.com/installer/faq/linux-faq/#what-is-swap
sudo dd if=/dev/zero of=/mnt/.swap.0 bs=1024 count=2097152
sudo mkswap /mnt/.swap.0
sudo su
echo "/mnt/.swap.0 swap swap defaults 0 0" >>/etc/fstab
swapon /mnt/.swap.0
exit
sudo swapon -s
After that, the error emails stopped.