I have a server hosting many sites, many of which have SSL set up.
For these the SSL config are held in a separate config file, being /etc/httpd/conf/httpd-le-ssl.conf
This has been in use and working for a long time - SSL certs are updated using the Lets Encrypt certbot
utility
Yesterday I found that the SSL config file was suddenly blank (It should have in the region of 3000 lines)
While finding a backup copy of the file to restore, watching the file I noticed that the last modification time matched the current time. This continued for about 20 minutes while getting a copy of the file back from the previous day's backup. Using the command watch ls -l httpd*conf
confirmed that the file was apparently being constantly written to, and it remained at 0 bytes.
This then stopped - eg the last modification time stopped being updated. Shortly after that I was able to put a copy of the restored file back in place and reload the apache config. Since then I've been watching the config file and making local backups of it every hour.
My question is What could possibly have caused this? My gut feeling is some kind of issue with certbot being run by multiple admins logging in at the same time, but I have no real way to prove this.