How to delete Cron created by the IDS service, that is no longer being used

Started by logi, September 15, 2024, 03:13:49 PM

Previous topic - Next topic
Yesterday I was playing with the services and turned ON the IDS, then turned it OFF, now I have a Disabled entry in the Cron section in Settings:

Description: ids rule updates
Command: Update and reload intrusion detection rules

I have tried all the possible options to delete it and it is impossible, what should I do to remove it? Thank you

Have you tried enabling the IDS, deleting the cron job, disabling the IDS again?
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Quote from: Patrick M. Hausen on September 15, 2024, 03:26:26 PM
Have you tried enabling the IDS, deleting the cron job, disabling the IDS again?

When IDS is enabled make sense for the cron to exist, I don't want to delete it then, I think when the IDS is being disable, in the clean up process, this leftover cron should have been deleted

I mean to get rid of it - enable, delete, disable. The end result is IDS disabled and cron job deleted.
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Didn't work with the IDS service ON, this cron is coming from the Schedule Section in:

Services: Intrusion Detection: Administration: Schedule

Once, you have enabled IDS one time, I think this cron gets created, and it is not removed when IDS is Disabled.

Are you speaking about the cronjobs visible in System > Settings > Cron?

Those are created using configd in
/usr/local/opnsense/service/conf/actions.d/

Have a look there in the files, find the related task in the file that contains it and remove the task.
https://docs.opnsense.org/development/backend/configd.html

Regards,
S.
Networking is love. You may hate it, but in the end, you always come back to it.

OPNSense HW
APU2D2 - deceased
N5105 - i226-V | Patriot 2x8G 3200 DDR4 | L 790 512G - VM HA(SOON)
N100   - i226-V | Crucial 16G  4800 DDR5 | S 980 500G - PROD

You don't get rid of the cron job, you just disable it.


Cheers,
Franco