I have a saved search which runs every day and this calls a script through a windows batch file. This is triggered successfully each day, but the script is killed after 300 seconds. The script does start and generate some data, so the script is working as expected, it just needs more time to complete.
WARN script - Script has timed out and will be killed, maxtime=300sec
Is there a way to modify the timelimit for a script? I can't see anything linked with saved searches or scripted inputs in the limits.conf which specifically mentions this limit.
That timeout can be increased in alert_action.conf
maxtime = <integer>[m|s|h|d] * The maximum amount of time that the execution of an action is allowed to take before the action is aborted. * Use the d, h, m and s suffixes to define the period of time: d = day, h = hour, m = minute and s = second. For example: 5d means 5 days. * Default (for all stanzas except 'rss': 5m * Default (for the 'rss' stanza): 1m
You can have the script write to a file, do an
exec inside the script to spawn the slow part as a separate process and configure a
[monitor://...] input to pull in the file changes.
Thanks for the suggestion. I am currently using another workaround by running the script via inputs.conf as a scripted input.
So I specifically looking for an answer to the question of the modifying the timeout - either it can be changed by or it is fixed and cannot be changed?