Sidekiq läuft nicht. Sidekiq-Heartbeat-Test fehlgeschlagen, Neustart

Wondering if I can resolve this issue by either flushing Redis or updating it; it hasn’t really been touched in the last 8+ months. I have not personally dealt with Redis before, but our Tests-Pass Discourse instance was setup using local_discourse rather than the Discourse Docker that is now recommended on this forum. Issues I’m encountering are related to email not being sent to users. Any help and suggestions appreciated!

Sidekiq is not running. Many tasks, like sending emails, are executed asynchronously by sidekiq. Please ensure at least one sidekiq process is running.

Sidekiq heartbeat test failed, restarting

config/unicorn.conf.rb:147:in `check_sidekiq_heartbeat
config/unicorn.conf.rb:164:in `master_sleep'
unicorn-5.5.4/lib/unicorn/http_server.rb:296:in `join'
unicorn-5.5.4/bin/unicorn:128:in `<top (required)>'
/var/www/discourse/vendor/bundle/ruby/2.6.0/bin/unicorn:23:in `load'
/var/www/discourse/vendor/bundle/ruby/2.6.0/bin/unicorn:23:in `<main>'

If it makes sense to migrate, I’m open to suggestions.

Ich empfehle, ein Backup deiner aktuellen Installation zu erstellen und eine komplett neue Installation gemäß der offiziellen Standardinstallation von Discourse durchzuführen.

5 „Gefällt mir“

That’s been the recommendation for at least the last 4 years.

I’d second Rafael’s suggestion.

1 „Gefällt mir“

Would it help for me to use launcher to rebuilt or restart the redis container?

Usage: launcher COMMAND CONFIG [–skip-prereqs] [–docker-args STRING]
Commands:
start: Start/initialize a container
stop: Stop a running container
restart: Restart a container
destroy: Stop and remove a container
enter: Open a shell to run commands inside the container
logs: View the Docker logs for a container
bootstrap: Bootstrap a container for the config based on a template
run: Run the given command with the config in the context of the last bootstrapped image
rebuild: Rebuild a container (destroy old, bootstrap, start new)
cleanup: Remove all containers that have stopped for > 24 hours
start-cmd: Generate docker command used to start container

Options:
–skip-prereqs Don’t check launcher prerequisites
–docker-args Extra arguments to pass when running docker
–skip-mac-address Don’t assign a mac address
–run-image Override the image used for running the container

Did you install following the Discourse official Standard Installation guide or some other way? If you have a standard installation, then yes, doing a ./launcher rebuild app will likely solve whatever your problem is.

Not yet, but we’re setting a time to migrate. Our Discourse has been running for almost three years and I just don’t want to add any unnecessary downtime. :slight_smile: Our instance is entirely maintained by volunteers so I’ve been teaching myself how to maintain it in the last month. If a quick redis fix will help (that container has been running for a year untouched) I’d like to apply it.

If you didn’t do a standard install to begin with, it’s anyone’s guess about what might fix your current problem.

I’d set up a new VM and do a test install there to make sure it works. When you do the transfer, you can put the old forum in read-only mode, take a backup, restore it to the new VM, and change the DNS for virtually no down time. (There will actually be a bit as you’ll need to rebuild after you change the DNS to get a let’s encrypt certificate installed)

1 „Gefällt mir“

Thank you, the Let’s Encrypt should actually be quite easy since it has been setup to be a simple nginx reverse proxy edit. Good to hear, and expect, there will be some downtime. Just need to schedule this on an off hour.

I’m about to migrate and restore the backup into official images. Is there anything I should know regarding clearing out backed emails, etc. that would spam the users once sidekiq, etc. is running properly. Thanks!

Die Sidekiq-Job-Warteschlange wird nicht übertragen, sodass viele E-Mails verworfen werden, während Digests weiterhin normal versendet werden.

3 „Gefällt mir“

Also, wir versuchen, die Dokumentation zur Installation offizieller Discourse-Docker-Images zu befolgen, stoßen aber auf Probleme. Wir haben festgestellt, dass uns der Redis-Container, der Mail-Empfänger-Container und der Datencontainer fehlen, die wir zuvor in Docker hatten.

Unser vorheriges Setup scheint Folgendes zu enthalten:
app.yml
data.yml
mail-receiver.yml
redis.yml

Dieses Multi-Container-Setup unterscheidet sich von den grundlegenden Installationsanweisungen. Ich habe jedoch ein Backup unseres alten /var/discourse zur Referenz.

FAILED                                                                                                                                                        │················································································································
--------------------                                                                                                                                          │················································································································
Pups::ExecError: cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate' fehlgeschlagen mit Rückgabewert #<Process::Status: pid 645 exit 1>                 │················································································································
Fehlerort: /pups/lib/pups/exec_command.rb:112:in `spawn'                                                                                            │················································································································
Ausführung fehlgeschlagen mit den Parametern {"cd"=>"$home", "hook"=>"db_migrate", "cmd"=>["su discourse -c 'bundle exec rake db:migrate'"]}                                   │················································································································
bbf0e57ac69f1febe2a5f149aa7e6e12541c3c23aaf199188fdf19d507254b58                                                                                              │················································································································
** BOOTSTRAP FEHLGESCHLAGEN ** Bitte scrollen Sie nach oben und suchen Sie nach früheren Fehlermeldungen; es kann mehr als eine geben.                                                   │················································································································
./discourse-doctor kann bei der Diagnose des Problems helfen.

Anscheinend haben wir den Schritt ./launcher bootstrap data und ./launcher start redis übersehen.

[Mon 11 May 2020 12:53:20 AM UTC] Reload-Befehl ausführen: sv reload nginx                                                                                             │················································································································
Fehler: nginx: runsv läuft nicht                                                                                                                                │················································································································
[Mon 11 May 2020 12:53:20 AM UTC] Reload-Fehler für :                                                                                                          │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Domains nicht geändert.                                                                                                        │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Übersprungen, nächste Erneuerungszeit ist: Thu 09 Jul 2020 11:33:04 PM UTC                                                                 │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Fügen Sie '--force' hinzu, um die Erneuerung zu erzwingen.                                                                                            │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Schlüssel installieren nach:/shared/ssl/discuss.noisebridge.info_ecc.key                                                              │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Vollständige Kette installieren nach:/shared/ssl/discuss.noisebridge.info_ecc.cer                                                       │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Reload-Befehl ausführen: sv reload nginx                                                                                             │················································································································
Fehler: nginx: runsv läuft nicht                                                                                                                                │················································································································
[Mon 11 May 2020 12:53:21 AM UTC] Reload-Fehler für :                                                                                                          │················································································································
run-parts: Ausführung von /etc/runit/1.d/remove-old-socket                                                                                                         │················································································································
runsvdir gestartet, PID ist 626                                                                                                                                  │················································································································
ok: run: redis: (pid 636) 0s                                                                                                                                  │················································································································
chgrp: ungültige Gruppe: 'syslog'                                                                                                                                │················································································································
ok: run: postgres: (pid 639) 0s                                                                                                                               │················································································································
rsyslogd: imklog: Kann Kernel-Log nicht öffnen (/proc/kmsg): Vorgang nicht erlaubt.                                                                               │················································································································
rsyslogd: Aktivierung des Moduls imklog fehlgeschlagen [v8.1901.0 siehe https://www.rsyslog.com/e/2145 ]                                                                  │················································································································
supervisor pid: 640 unicorn pid: 667
1 „Gefällt mir“

Okay, wir haben unsere vorherige Discourse-Instanz erfolgreich wiederhergestellt! Jetzt wird angezeigt:

Alle ausgehenden E-Mails wurden von einem Administrator global deaktiviert. Es werden keine E-Mail-Benachrichtigungen jeglicher Art versendet.

Das ist korrekt, die Importeure haben das so eingestellt, damit Sie nach einer Migration nicht 50.000 E-Mails versenden. Schalten Sie E-Mails in Ihren Site-Einstellungen vorsichtig ein.

2 „Gefällt mir“

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