I deleted a log file and no new log file was created. What should I do?

Ideally, you should not delete log files. Instead, copy them to another location, and clear the log file. However, if you accidentally deleted a log file on running system (only possible for Unix system since Windows does not allow the user to delete currently used files), there are two ways to recreate the log file:

  1. Restart the corresponsing daemon.

  2. Send an HUP signal to the corresponding daemon using the kill -HUP <pid>. The daemon reloads its logging configuration in its handler for the HUP signal, which causes the daemon to log to a new file.