Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor

Create cron job on GAIA

I would use the following command example to forward firewall logs on CP Management to syslog. However, the fw log command can only specify time range to filter out the logs.  How can I setup cron job on GAIA to run the command?

fw log -s "DEC 18 2018 14:00:00" | logger -p local4.info

7 Replies
Highlighted
Admin
Admin

You don't need a cron job for this, you need Log Exporter.

Log Exporter guide

0 Kudos
Highlighted
Champion
Champion

Dameon is right - but to answer the original question, for cron in WebGUI see e.g. Gaia Administration Guide R80.10 p.111f !

0 Kudos
Highlighted
Champion
Champion

From the clish command line, I used LogExport as the jobname:

add cron job LogExport command "fw log -s "DEC 18 2018 14:00:00" | logger -p local4.info" recurrence daily time 0:00 

Regards, Maarten
Highlighted
Contributor

Thanks for reply.

I checked the Job Scheduler in Gaia admin guide, the frequency is just daily at most. If I would run the job every 2 hours, shall I create 12 jobs?

0 Kudos
Highlighted
Admin
Admin

But you still haven't explained why you're doing this versus just using Log Exporter, which is a much better solution.

0 Kudos
Highlighted
Contributor

I am learning the CheckPoint with trial software. Unable to download the LogExporter package.

0 Kudos