# Error with maxmind download during update

**URL:** https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341
**Category:** Self-hosting
**Tags:** maxmind
**Created:** [April 24, 2024, 11:04pm UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341 "2024-04-24T23:04:40Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![مباركمبارك](https://avatars.discourse-cdn.com/v4/letter/%D9%85/a87d85/32.png) [@مباركمبارك](https://meta.discourse.org/u/%D9%85%D8%A8%D8%A7%D8%B1%D9%83%D9%85%D8%A8%D8%A7%D8%B1%D9%83)
#### Post date: [April 24, 2024, 11:04pm UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/1 "2024-04-24T23:04:41Z")

</div>

Guys, I need urgent help, I’m about to give up on my speech, I’ve been trying to update my speech for a few days and this error always appears, what could it be?

```plaintext

Done compiling CSS: 2024-04-24 22:53:38 UTC
/var/www/discourse/lib/discourse_ip_info.rb:50:in `mmdb_download': undefined method `path' for nil:NilClass (NoMethodError)

     filename = File.basename(gz_file.path)
                                     ^^^^^
from /var/www/discourse/lib/tasks/maxminddb.rake:73:in `block (3 levels) in <main>'
from /var/www/discourse/lib/tasks/maxminddb.rake:71:in `each'
from /var/www/discourse/lib/tasks/maxminddb.rake:71:in `block (2 levels) in <main>'
Docker Manager: FAILED TO UPGRADE
#<RuntimeError: RuntimeError>
/var/www/discourse/plugins/docker_manager/lib/docker_manager/upgrader.rb:210:in `run'
/var/www/discourse/plugins/docker_manager/lib/docker_manager/upgrader.rb:111:in `upgrade'
/var/www/discourse/plugins/docker_manager/scripts/docker_manager_upgrade.rb:19:in `block in <main>'
/var/www/discourse/plugins/docker_manager/scripts/docker_manager_upgrade.rb:6:in `fork'
/var/www/discourse/plugins/docker_manager/scripts/docker_manager_upgrade.rb:6:in `<main>'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/commands/runner/runner_command.rb:43:in `load'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/commands/runner/runner_command.rb:43:in `perform'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/thor-1.3.1/lib/thor/command.rb:28:in `run'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/thor-1.3.1/lib/thor/invocation.rb:127:in `invoke_command'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/thor-1.3.1/lib/thor.rb:527:in `dispatch'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/command/base.rb:87:in `perform'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/command.rb:48:in `invoke'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/commands.rb:18:in `<main>'
<internal:/usr/local/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
<internal:/usr/local/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
/var/www/discourse/vendor/bundle/ruby/3.2.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
bin/rails:18:in `<main>'
Spinning up 7 Unicorn worker(s) that were stopped initially

```

---

<div class="post-metadata">

### Author: ![مباركمبارك](https://avatars.discourse-cdn.com/v4/letter/%D9%85/a87d85/32.png) [@مباركمبارك](https://meta.discourse.org/u/%D9%85%D8%A8%D8%A7%D8%B1%D9%83%D9%85%D8%A8%D8%A7%D8%B1%D9%83)
#### Post date: [April 24, 2024, 11:08pm UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/2 "2024-04-24T23:08:55Z")

</div>

Every time this error occurs during updates, this message appears on the control panel. Sidekiq is not running. Many tasks, such as sending emails, are performed asynchronously by Sidekiq. Make sure that at least one sidekiq process is running.

---

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [April 24, 2024, 11:37pm UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/3 "2024-04-24T23:37:40Z")

</div>

You posted here already:

> [@Docker update error](https://meta.discourse.org/t/docker-update-error/302140):
>
> I tried to update docker through my discourse control panel but all of them gave an error, can anyone help me /var/www/discourse/lib/discourse\_ip\_info.rb:48:in `mmdb_download': undefined method `path' for nil:NilClass (NoMethodError) filename = File.basename(gz\_file.path) ^^^^^ from /var/www/discourse/lib/tasks/maxminddb.rake:72:in `block (3 levels) in \<main\>' from /var/www/discourse/lib/tasks/maxminddb.rake:70:in `each' from /var/www/discourse/lib/ta…

Did the fix ([Allow redirect when downloading maxmind database by pfaffman · Pull Request #26333 · discourse/discourse · GitHub](https://github.com/discourse/discourse/pull/26333)) not work for you?

It worked for Jay, but I believe it failed for @Firepup650 too. That’s odd for sure 🤔 .

> [@Fail to download maxmind db with valid key & can download the DB from inside container](https://meta.discourse.org/t/fail-to-download-maxmind-db-with-valid-key-can-download-the-db-from-inside-containerr/300590/13):
>
> End of the logs from the crashed build: Downloading MaxMindDB... Compressing Javascript and Generating Source Maps I, [2024-03-26T13:27:38.305597 #1] INFO -- : Terminating async processes I, [2024-03-26T13:27:38.307312 #1] INFO -- : Sending INT to HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main pid: 42 I, [2024-03-26T13:27:38.307891 #1] INFO -- : Sending TERM to exec …

---

<div class="post-metadata">

### Author: ![مباركمبارك](https://avatars.discourse-cdn.com/v4/letter/%D9%85/a87d85/32.png) [@مباركمبارك](https://meta.discourse.org/u/%D9%85%D8%A8%D8%A7%D8%B1%D9%83%D9%85%D8%A8%D8%A7%D8%B1%D9%83)
#### Post date: [April 25, 2024, 1:01am UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/4 "2024-04-25T01:01:01Z")

</div>

Yes friend, I posted again, because my installation a few days ago started to appear several problems, simply after all these errors, I click F5 and it appears that the installation is updated with nothing pending, even after the previous attempt presented an error, my speech is very strange lately, it is very slow, there is nothing different, I am only using it on my server, and I only use 1 plugin which is not official, all the others are official.

---

<div class="post-metadata">

### Author: ![مباركمبارك](https://avatars.discourse-cdn.com/v4/letter/%D9%85/a87d85/32.png) [@مباركمبارك](https://meta.discourse.org/u/%D9%85%D8%A8%D8%A7%D8%B1%D9%83%D9%85%D8%A8%D8%A7%D8%B1%D9%83)
#### Post date: [April 25, 2024, 1:03am UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/5 "2024-04-25T01:03:14Z")

</div>

I didn’t try anything, simply after being alerted about the error I clicked F5 and after returning the warning about pending updates disappeared, as if the last update had been successful, even though I knew it had not been completed successfully.

---

<div class="post-metadata">

### Author: ![Firepup650](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/firepup650/32/465200_2.png) [@Firepup650](https://meta.discourse.org/u/Firepup650)
#### Post date: [April 25, 2024, 1:03am UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/6 "2024-04-25T01:03:29Z")

</div>

Please try doing a manual CLI rebuild, the panel might have an issue with the maxmind changes.

---

<div class="post-metadata">

### Author: ![مباركمبارك](https://avatars.discourse-cdn.com/v4/letter/%D9%85/a87d85/32.png) [@مباركمبارك](https://meta.discourse.org/u/%D9%85%D8%A8%D8%A7%D8%B1%D9%83%D9%85%D8%A8%D8%A7%D8%B1%D9%83)
#### Post date: [April 25, 2024, 1:40am UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/7 "2024-04-25T01:40:46Z")

</div>

Good idea friend, this possibility didn’t cross my mind, tomorrow I’ll try to do this, after every update attempt sidekiq always stops working and warns me on my control panel, the only thing that makes it come back is using the command " sudo reboot" on the server, but tomorrow I will try to rebuild manually.

---

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [April 25, 2024, 3:04am UTC](https://meta.discourse.org/t/error-with-maxmind-download-during-update/305341/8 "2024-04-25T03:04:54Z")

</div>

Generally, if you encounter an issue with the upgrade from the UI, use the console; that’s the way to go!  
Discourse is updated daily, and some changes can happen that require a full container rebuild.

* * *

As a side note, there is a Rake task `maxminddb:refresh` to test/download the MaxMind DB files directly (or `maxminddb:get` to ignore last downloaded date check and backup) :

```plaintext
./launcher enter app
rake maxminddb:refresh
quit

```
