Howto restart snort on schedule?



  • It seems snort memory usage is increasing over time.
    I would like to add a cron job to restart snort every few days.
    Should I just use kilall and ps aux to copy snort's command line to start it again?
    If I did that would it's status be updated properly in status-services and in snort's gui?



  • I think there are three options:

    • test this script you described

    • write a php to kill snort and then call package startup routine/function

    • reboot at night when memory reachs a specific limit



  • I will try to write such a script.
    call package startup routine/function : do you mean to use the status_services.php for that?
    I am looking at the file and apparently it uses killbypid in order to stop services and start_service(servicename) for startup (for generic services anyway and snort is not one of the special cases there).


Log in to reply