Delete Log Files That Are Older Than 6 Months
I'm using NLog in most of the web applications that I built. This library generates files with extension ".log" where the exceptions and tracing logs are stored. After, few months to years, I noticed that few applications reached a large number of log files generated over the time and this is totally normal especially if we are tracing major events in the application. The files are consuming some good space of the hard disk. Therefore, there is a need to delete old files and cleanup the hard d…