Automating preemptive site gather on server

The BigFix Console has a “Gather” button on every site listing that will prompt the core to gather the specified site, preempting the regular gather interval.

I was wondering if this mechanism is exposed through some API, so that we could script gathering of some sites on a faster interval than the normal value, which is Daily for us.

I noticed that the Relay Diagnostics page appears to be able to download the latest version of a site.
rd gather latest site version

It looks like, if for example I wanted the latest version of the BES Support site, and if for example the server is 127.0.0.1, then the “Submit” button sends this:

http://127.0.0.1:52311/cgi-bin/bfenterprise/BESGatherMirror.exe/-gatherlatest?&url=http%3A%2F%2Fsync.bigfix.com%2Fcgi-bin%2Fbfgather%2Fbessupport

I’ve tried some variations of this in the browser, but it won’t trigger a server-level gather for a specific site.

EDIT: Upon closer inspection, BESGatherMirror.exe appears to be specific to Relays. So I guess there isn’t any way to do this on the BigFix Server other than opening a console session and hitting “Gather”? It would be awesome if there was a way to script that, since doing so here would require loading 7 console sessions.

If I am not wrong, external site gather interval is every 12 hours and it is not configurable. If nobody else has a solution on this, then you may want to submit an enhancement request to the HCL team: https://bigfix-ideas.hcltechsw.com/ideas

External site gather interval is 1 hour by default, and is configurable :slight_smile:

Please see Content Delivery Service for reference.

Given this default/configuration would you still be looking for a way to trigger this externally?

In any case, if you did want to trigger site gathers, you can do so on the Root Server by making a GET request to the following URL:

https://<root server name/ip>:<bigfix port>/cgi-bin/bfenterprise/BESGatherMirrorNew.exe/-triggergatherdb?trigger

3 Likes

Thanks!

We’re aware of the setting that controls gather interval. :slight_smile:

About that URL - Does that really make the server do a gather? I started to wonder if maybe that only makes the relay service gather from the root server. So if it runs on the root server itself, it causes the root server to gather from sync.bigfix.com?

Would adding the following make it target BES Support?

https://<root server name/ip>:<bigfix port>/cgi-bin/bfenterprise/BESGatherMirrorNew.exe/-triggergatherdb?trigger&url=http%3A%2F%2Fsync.bigfix.com%2Fcgi-bin%2Fbfgather%2Fbessupport