# Request elasticsearch to update geoip database

**URL:** <https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850>\
**Category:** Elasticsearch\
**Created:** [October 5, 2022, 8:44am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850 "2022-10-05T08:44:06Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![A\_Abdellah](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/a_abdellah/32/100734_2.png) [@A\_Abdellah](https://discuss.elastic.co/u/A_Abdellah)\
**Post date:** [October 5, 2022, 8:44am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/1 "2022-10-05T08:44:07Z")

</div>

Hello  
I use elasticsearch on premises for security features, and I can't expose it all the time which made my geoip databases expire.  
I'm aware that elasticsearch use maxmind database and request using [https://geoip.elastic.co/v1/database](https://geoip.elastic.co/v1/database)  
but I need to control the start of the update process, so when i need to update I expose my nodes for a short window of time, do the update then secure them again.  
Is there any elasticsearch API dedicated for that ??

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [October 5, 2022, 9:19am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/2 "2022-10-05T09:19:09Z")

</div>

Take a look at [GeoIP processor | Elasticsearch Guide [8.4] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/8.4/geoip-processor.html#manage-geoip-database-updates)

---

<div class="post-metadata">

**Author:** ![A\_Abdellah](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/a_abdellah/32/100734_2.png) [@A\_Abdellah](https://discuss.elastic.co/u/A_Abdellah)\
**Post date:** [October 5, 2022, 9:34am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/3 "2022-10-05T09:34:44Z")

</div>

I'm really sorry if my question is not clear.  
I want to let you know that I already used manual update by downloading the database and uploading from a file, but it's not very practical,  
My question is can I request elasticserch directly to go and download the geoip database ?

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [October 5, 2022, 11:41am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/4 "2022-10-05T11:41:14Z")

</div>

> [@A\_Abdellah](#):
>
> My question is can I request elasticserch directly to go and download the geoip database ?

No, there is no such API to trigger an GeoIP update, Elasticsearch will automatically update it following some logic built-in in the code that is not exposed to the user through an API, so you have no control when it will update.

As the shared documentation says, if you can't let elasticsearch automatically update the geoip database, you will need to use the manual updates.

---

<div class="post-metadata">

**Author:** ![A\_Abdellah](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/a_abdellah/32/100734_2.png) [@A\_Abdellah](https://discuss.elastic.co/u/A_Abdellah)\
**Post date:** [October 5, 2022, 11:42am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/5 "2022-10-05T11:42:56Z")

</div>

Thank you very much, but I think it would be very interesting as a feature.

---

<div class="post-metadata">

**Author:** ![A\_Abdellah](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/a_abdellah/32/100734_2.png) [@A\_Abdellah](https://discuss.elastic.co/u/A_Abdellah)\
**Post date:** [October 6, 2022, 8:51am UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/6 "2022-10-06T08:51:54Z")

</div>

I found a workaround to trigger the update by control, when the elasticsearch service is restarted the geoip update is checked in the startup, it helped me update when I wanted too.

---

<div class="post-metadata">

**Author:** ![matled](https://avatars.discourse-cdn.com/v4/letter/m/ba8739/32.png) [@matled](https://discuss.elastic.co/u/matled)\
**Post date:** [October 14, 2022, 12:32pm UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/7 "2022-10-14T12:32:30Z")

</div>

would be interested in this feature too, had many situations where it would be good to trigger an update manually in order to check if it is configured correctly

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 11, 2022, 12:32pm UTC](https://discuss.elastic.co/t/request-elasticsearch-to-update-geoip-database/315850/8 "2022-11-11T12:32:55Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
