Redirect fail in php exec

I capture the output of the certbot command…
$cmd1= ‘certbot certificates >’ . $Certs_txt;

$opS1 = exec($cmd1, $op1, $retval1);
gjLog('cmd1 ’ . $cmd1 . " op1\n" . print_r($op1,1) . "\niretval1 " . $iretval1 . ’ opS1 ’ . $opS1 . PHP_EOL);

This command failed twice yesterday. It also succeeded twice.

memory_limit 512M

Output file created is 30,000 lines 190kb.

I am confused. What could happen to make this fail? Also, it has run nightly for 1 year, without a failure?

Can you post specific error from your log file?

Nothing in my php or application log file. Running ubuntu 18 on a rackspace cloud server. Which log file would you look at? Kernel, sys ?, What might you search for , besides time? BTW, I don’t think this is worth your effort looking at. But if something comes to mind, please do not hesitate to share. My guess is it is some kind of memory or time limitation that is kicking in. The issue is, it is flaky. I posted here because problems like this are of interest. I scanned syslog and kern.log, did not see anything. I have a lot of these in syslog,
Aug 31 12:56:25 cloudb-2019 systemd-resolved[5338]: Server returned error NXDOMAIN, mitigating potential DNS violation DVE-2018-0001, retrying transaction with reduced feature level UDP.
But, I think that is a different issue

There was a global outage few days back and many sites failed to load. I believe you might have been affected too.