I am attempting to run a scheduled BASH scripted input on UF 7.2.x on Ubuntu 16 or later.
The script does some preparatory work and then STOPS the UF.
It then needs to change some things in the UF environment, and then restart the UF.
Testing it from the CLI shows that the script works according to plan, HOWEVER,
when running it as a scripted input, the last line that gets executed is the SPLUNK STOP command.
I know the reason is that when the UF stops, it destroys the process tree that is running the script.
From reading older threads on similar issues, I find that this behavior used to not be the default. People were complaining that things were continuing to run, and chewing up resources even though the UF had been stopped. I understand that concern, however in this case, I really need it to keep running, even though that no longer appears to be the default behavior.
I have attempted using a wrapper script using the bash and & parameters, as well as NOHUP and SCREEN. All to no avail. They all get killed when the UF stops. I have attempted using a .path file to call the script. Same result.
How can a fork something that is no longer dependent on the UF process for this one script?
Any help is greatly appreciated!
... View more