Here the same case occurred sending more than 50,000 letters (1.1 GB of data).
I used a simple script that reads everything using "select * from email_queue" and passes it to mail () in the mysqli_fetch_assoc () loop. It has been running smoothly cronjob for years, but not for the last time.
The solution here was to send only "select id from email_queue", which then reads the record in a loop using another "select * ..." and passes it to mail (). In addition, the average load decreased significantly.
source share