opinkerfi / adagios

Adagios - Web Based Nagios Configuration
GNU Affero General Public License v3.0
330 stars 75 forks source link

Subdirectory in nagios archives directory causes IOError in logs view #498

Closed wasserman closed 9 years ago

wasserman commented 9 years ago

I was doing nagios log cleanup by moving logs to an 'old' subdirectory in /var/log/nagios/archives and then filtering out bloat and moving the results back to /var/log/nagios/archives. I never removed the subdirectory and discovered this bug.

To reproduce:

This should result in the following error:

A simple fix could be to have the code skip directories. Although I know I need to just remove the subdirectory and possibly do such cleanup somewhere else to avoid this situation. I just wanted to report this so Adagios can handle this situation more gracefully.

palli commented 9 years ago

This is a bug in pynag. I have a fix available already, pending to be merged.

palli commented 9 years ago

Patch has been merged. Marking this issue as close. Let me know if you have any further issues.