Support Questions

Find answers, ask questions, and share your expertise

With Ambari 2.6.1, how can I change "Max Retention Days"?

avatar

Looks like updating "Max Retention Days" from Ambari Web UI does not update not only existing docs (which is expected) but also newly added docs.

I unloaded the ranger audit core multiple times and restarted Ranger to recreate the collection, then it eventually worked.

Is this expected behaviour? If so, why Ambari doesn't unload (or reload if that should work)? (a bug?)

1 ACCEPTED SOLUTION

avatar
Contributor

hi, @Hajime
If you are restarting Ranger it should upload a new solrconfig.xml to zookeeper with the changed max retention days.
Then maybe you can reload the collection with Solr API (RELOAD action on collections, see: https://lucene.apache.org/solr/guide/6_6/collections-api.html) ,

View solution in original post

3 REPLIES 3

avatar
Contributor

hi, @Hajime
If you are restarting Ranger it should upload a new solrconfig.xml to zookeeper with the changed max retention days.
Then maybe you can reload the collection with Solr API (RELOAD action on collections, see: https://lucene.apache.org/solr/guide/6_6/collections-api.html) ,

avatar

Hi @Olivér Szabó,

I see the new dates in solrconfig.xml in the Zookeeper, but newly added docs still used previous days, so that I posted this question.

After unloading ranger_audit core multiple times, it eventually worked.

But I was wondering if unload/reload is required? If yes, why Ambari doesn't do that?

avatar
Contributor

Seems like it's required. I guess mostly that was used for bootstrapping.
How that solrconfig.xml file changes ... it's not that clear we already have the collection created or we are just doing an update.
Then i think in the future upload configs + create / reload collections should be moved on Ranger side (background bootstrap process), then Ambari should just configure the files, not to do anything with Solr API from agent side.