Discourse update keeps failing

Today, I’ve tried to run an update and the rebuild keeps failing, I also removed all unofficial plugins, but I don’t know what to do further.

This is the error message

Location of failure: /usr/local/lib/ruby/gems/2.7.0/gems/pups-1.1.1/lib/pups/exec_command.rb:117:in `spawn'
exec failed with the params {"cd"=>"$home", "hook"=>"db_migrate", "cmd"=>["su discourse -c 'bundle exec rake db:migrate'"]}
bootstrap failed with exit code 134

Below that error message is the text ** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.

So… please scroll up and look for earlier error messages.

3 Likes

Sorry, pasted the wrong one:

 could not receive data from client: Connection reset by peer
Aborted (core dumped)
I, [2022-07-04T09:24:39.336838 #1]  INFO -- : 
I, [2022-07-04T09:24:39.337289 #1]  INFO -- : Terminating async processes
I, [2022-07-04T09:24:39.337528 #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
2022-07-04 09:24:39.337 UTC [42] LOG:  received fast shutdown request
I, [2022-07-04T09:24:39.337594 #1]  INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 103
103:signal-handler (1656926679) Received SIGTERM scheduling shutdown...
103:M 04 Jul 2022 09:24:39.373 # User requested shutdown...
103:M 04 Jul 2022 09:24:39.373 * Saving the final RDB snapshot before exiting.
2022-07-04 09:24:39.441 UTC [42] LOG:  aborting any active transactions
2022-07-04 09:24:39.447 UTC [42] LOG:  background worker "logical replication launcher" (PID 51) exited with exit code 1
2022-07-04 09:24:39.448 UTC [46] LOG:  shutting down
2022-07-04 09:24:39.925 UTC [42] LOG:  database system is shut down

Can you paste a few lines above that as well please?

1 Like

I hope these are enough but let me know if you need more:

7f7ec07f9000-7f7ec07fd000 rw-p 00000000 00:00 0 
7f7ec07fe000-7f7ec07ff000 r--p 00000000 00:38 43787088                   /usr/local/lib/ruby/2.7.0/x86_64-linux/enc/encdb.so
7f7ec07ff000-7f7ec0800000 r-xp 00001000 00:38 43787088                   /usr/local/lib/ruby/2.7.0/x86_64-linux/enc/encdb.so
7f7ec0800000-7f7ec0801000 r--p 00002000 00:38 43787088                   /usr/local/lib/ruby/2.7.0/x86_64-linux/enc/encdb.so
7f7ec0801000-7f7ec0802000 r--p 00002000 00:38 43787088                   /usr/local/lib/ruby/2.7.0/x86_64-linux/enc/encdb.so
7f7ec0802000-7f7ec0803000 rw-p 00003000 00:38 43787088                   /usr/local/lib/ruby/2.7.0/x86_64-linux/enc/encdb.so
7f7ec0803000-7f7ec0830000 r--p 00000000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0830000-7f7ec0a43000 r-xp 0002d000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0a43000-7f7ec0b3b000 r--p 00240000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0b3b000-7f7ec0b3c000 ---p 00338000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0b3c000-7f7ec0b42000 r--p 00338000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0b42000-7f7ec0b45000 rw-p 0033e000 00:38 43659503                   /usr/local/lib/libruby.so.2.7.6
7f7ec0b45000-7f7ec0b62000 rw-p 00000000 00:00 0 
7f7ec0b62000-7f7ec0b63000 r--p 00000000 00:38 39719923                   /lib/x86_64-linux-gnu/ld-2.31.so
7f7ec0b63000-7f7ec0b83000 r-xp 00001000 00:38 39719923                   /lib/x86_64-linux-gnu/ld-2.31.so
7f7ec0b83000-7f7ec0b8b000 r--p 00021000 00:38 39719923                   /lib/x86_64-linux-gnu/ld-2.31.so
7f7ec0b8b000-7f7ec0b8c000 r-xp 00000000 00:00 0 
7f7ec0b8c000-7f7ec0b8d000 r--p 00029000 00:38 39719923                   /lib/x86_64-linux-gnu/ld-2.31.so
7f7ec0b8d000-7f7ec0b8e000 rw-p 0002a000 00:38 39719923                   /lib/x86_64-linux-gnu/ld-2.31.so
7f7ec0b8e000-7f7ec0b8f000 rw-p 00000000 00:00 0 
7ffdf35f7000-7ffdf3df6000 rw-p 00000000 00:00 0                          [stack]
7ffdf3dfb000-7ffdf3dfe000 r--p 00000000 00:00 0                          [vvar]
7ffdf3dfe000-7ffdf3dff000 r-xp 00000000 00:00 0                          [vdso]
ffffffffff600000-ffffffffff601000 --xp 00000000 00:00 0                  [vsyscall]


2022-07-04 09:24:39.333 UTC [892] discourse@discourse LOG:  could not receive data from client: Connection reset by peer
Aborted (core dumped)
I, [2022-07-04T09:24:39.336838 #1]  INFO -- : 
I, [2022-07-04T09:24:39.337289 #1]  INFO -- : Terminating async processes
I, [2022-07-04T09:24:39.337528 #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
2022-07-04 09:24:39.337 UTC [42] LOG:  received fast shutdown request
I, [2022-07-04T09:24:39.337594 #1]  INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 103
103:signal-handler (1656926679) Received SIGTERM scheduling shutdown...
103:M 04 Jul 2022 09:24:39.373 # User requested shutdown...
103:M 04 Jul 2022 09:24:39.373 * Saving the final RDB snapshot before exiting.
2022-07-04 09:24:39.441 UTC [42] LOG:  aborting any active transactions
2022-07-04 09:24:39.447 UTC [42] LOG:  background worker "logical replication launcher" (PID 51) exited with exit code 1
2022-07-04 09:24:39.448 UTC [46] LOG:  shutting down
2022-07-04 09:24:39.925 UTC [42] LOG:  database system is shut down
103:M 04 Jul 2022 09:24:40.378 * DB saved on disk
103:M 04 Jul 2022 09:24:40.378 # Redis is now ready to exit, by

Ouch.

Tell me more about this install. Is it a standard install? On what kind of hardware are you attempting to do this?

2 Likes

Initially, I tried to update the forum through the docker manager today’s update (there were eleven updates) I already updated to version 2.9.0 beta6 last Friday and the forum has been already up and running for three years now without an issue on the same server:

It is running on a dedicated server with these specs:

  • AMD Opteron 4180
  • 6 x 2,6 GHz
  • 16 GB RAM
  • 2 x 1 TB SSD
    (Ubuntu 20.04 LTS)

EDIT: There’s more than enough space on the server.

1 Like

I’m sorry, I’m stumped here, I hope someone else has a clue.

3 Likes

Thank you anyway for your effort.

2 Likes

If it helps, I also found this warning:

I, [2022-07-04T11:08:15.901173 #1]  INFO -- : > cd /var/www/discourse && [ ! -d 'node_modules' ] || su discourse -c 'yarn install --production && yarn cache clean'
warning "eslint-config-discourse > eslint-plugin-lodash@7.1.0" has unmet peer dependency "lodash@>=4".
warning " > @mixer/parallel-prettier@2.0.1" has unmet peer dependency "prettier@^2.0.0".

1 Like

Have you rebooted lately? Maybe you installed updates that require a reboot? I’d update the os and reboot next. (Because I have no actual ideas)

2 Likes

Yes, I did a reboot Friday, due to a kernel update, and I also tried it earlier this day to see if it could solve the issue.

1 Like

Might not be a clue but I’ve seen the exact same error when installing a plugin. Now I’m not sure anymore if that plugin is the root cause.

https://meta.discourse.org/t/web-3-0-features/203321/21?u=marcp

1 Like

Well, I uninstalled all unofficial plugins, but I will investigate further in that direction.

No, you’re getting a different error. You should scroll back to find the original error.

1 Like

A post was merged into an existing topic: Custom Wizard Plugin :mage:

I really hope someone can help me. I’ve tried to clean the cache, remove container images and rebuilding with an older image and all result to the same error.

1 Like

It would be much more useful for to paste the entire log rather than snippets from it.

For example, it’s unclear exactly what is abending; it might be the database or a rake task.

If it’s too long, feel free to post it gzipped. If you’re not sure how to scrub secrets from it (if any), you can PM it to me and I’ll see what I can find.

6 Likes

I am creating it right now.

The key part of the output appears to be this “Illegal instruction”:

I, [2022-07-04T21:01:40.452409 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate'                                                                      
2022-07-04 21:01:46.756 UTC [932] discourse@discourse LOG:  duration: 120.094 ms  bind <unnamed>: SELECT t.oid, t.typname                                                                   
        FROM pg_type as t                                                                                                                                                                   
        WHERE t.typname IN ('int2', 'int4', 'int8', 'oid', 'float4', 'float8', 'numeric', 'bool', 'timestamp', 'timestamptz')                                                               
                                                                                                                                                                                            
2022-07-04 21:01:47.069 UTC [932] discourse@discourse LOG:  duration: 100.781 ms  statement: SELECT name, data_type, value FROM site_settings                                               
/var/www/discourse/vendor/bundle/ruby/2.7.0/gems/message_bus-4.2.0/lib/message_bus/codec/json.rb:11: [BUG] Illegal instruction at 0x00007f90039e1339                                        
ruby 2.7.6p219 (2022-04-12 revision c9c2245c0a) [x86_64-linux]

The same “illegal instruction” is also present at the end of the Unicorn log (just before things broke).

(Hopefully Bryan can provide the full output as necessary).

Edit: Full log incoming, Discourse is not letting me upload it.

Edit 2: Bitwarden Send (available for 7 days).

2 Likes