YunoHost-Apps / mastodon_ynh

Free, open-source social network for YunoHost
https://joinmastodon.org/
GNU Affero General Public License v3.0
84 stars 36 forks source link

Issue after upgrading from jessie to buster #234

Closed fflorent closed 3 years ago

fflorent commented 4 years ago

After upgrading from jessie to buster, I encountered this issue: https://github.com/tootsuite/mastodon/issues/12081

Here are the logs when I try to reinstall mastodon:

2020-08-09 16:39:32,129: DEBUG - Done in 84.07s.
2020-08-09 16:39:32,230: DEBUG - + RAILS_ENV=production
2020-08-09 16:39:32,230: DEBUG - + bundle exec rails assets:clean
2020-08-09 16:39:47,284: WARNING - rails aborted!
2020-08-09 16:39:47,285: WARNING - LoadError: Could not open library '/var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/cld3-3.2.6/lib/../ext/cld3/libcld3.so': libprotobuf.so.10: cannot open shared object file: No such file or directory
2020-08-09 16:39:47,285: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/ffi-1.10.0/lib/ffi/library.rb:145:in `block in ffi_lib'
2020-08-09 16:39:47,286: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/ffi-1.10.0/lib/ffi/library.rb:99:in `map'
2020-08-09 16:39:47,286: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/ffi-1.10.0/lib/ffi/library.rb:99:in `ffi_lib'
2020-08-09 16:39:47,287: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/cld3-3.2.6/lib/cld3.rb:115:in `<module:Unstable>'
2020-08-09 16:39:47,288: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/cld3-3.2.6/lib/cld3.rb:112:in `<module:CLD3>'
2020-08-09 16:39:47,288: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/cld3-3.2.6/lib/cld3.rb:24:in `<top (required)>'
2020-08-09 16:39:47,289: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
2020-08-09 16:39:47,289: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
2020-08-09 16:39:47,290: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
2020-08-09 16:39:47,290: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
2020-08-09 16:39:47,291: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
2020-08-09 16:39:47,292: WARNING - /var/www/mastodon/live/config/application.rb:7:in `<top (required)>'
2020-08-09 16:39:47,292: DEBUG - + ynh_exit_properly
2020-08-09 16:39:47,292: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
2020-08-09 16:39:47,293: DEBUG - + local exit_code=1
2020-08-09 16:39:47,293: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
2020-08-09 16:39:47,294: DEBUG - + '[' 1 -eq 0 ']'
2020-08-09 16:39:47,294: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
2020-08-09 16:39:47,295: DEBUG - + trap '' EXIT
2020-08-09 16:39:47,295: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
2020-08-09 16:39:47,295: DEBUG - + set +o errexit
2020-08-09 16:39:47,295: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
2020-08-09 16:39:47,295: DEBUG - + set +o nounset
2020-08-09 16:39:47,295: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
2020-08-09 16:39:47,296: DEBUG - + sleep 0.5
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/Rakefile:4:in `<top (required)>'
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:54:in `load'
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:54:in `load'
2020-08-09 16:39:47,296: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:285:in `block in load'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:285:in `load'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/railties-5.2.4.1/lib/rails/commands/rake/rake_command.rb:22:in `block in perform'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/railties-5.2.4.1/lib/rails/commands/rake/rake_command.rb:20:in `perform'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/railties-5.2.4.1/lib/rails/command.rb:48:in `invoke'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/railties-5.2.4.1/lib/rails/commands.rb:18:in `<top (required)>'
2020-08-09 16:39:47,297: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
2020-08-09 16:39:47,298: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
2020-08-09 16:39:47,299: WARNING - /var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
2020-08-09 16:39:47,299: WARNING - bin/rails:4:in `<main>'
2020-08-09 16:39:47,299: WARNING - (See full trace by running task with --trace)

And indeed:

$ ldd '/var/www/mastodon/live/vendor/bundle/ruby/2.6.0/gems/cld3-3.2.6/lib/../ext/cld3/libcld3.so'
    linux-vdso.so.1 (0x00007ffc65776000)
    libprotobuf.so.10 => not found
    libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f1fa9992000)
    libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f1fa980e000)
    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f1fa968b000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f1fa94ca000)
    libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f1fa94b0000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f1fa9c84000)
fflorent commented 4 years ago

May I try to follow this instruction (bundle install --force)?

https://github.com/tootsuite/mastodon/issues/12081#issuecomment-545662968

yalh76 commented 4 years ago

maybe you should try to upgrade mastodon doing yunohost app upgrade mastodon

fflorent commented 4 years ago

it didn't work. I also tried force an upgrade (yunohost app upgrade -u https://github.com/YunoHost-Apps/mastodon_ynh) and the installation failed, also the removal of the dependencies were hanging.

I uninstalled the app and reinstalled through the backup, and it works now !

Not sure what I may bring to help diagnosing my issue :/. If I can help, I can probably share logs.

MCMic commented 3 years ago

Hello, I have the same problem after upgrading to Buster.

Not sure what is the correct command to fix this?

yalh76 commented 3 years ago

you can force mastodon upgrade doing: YNH_FORCE_UPGRADE=1 yunohost app upgrade mastodon -u https://github.com/YunoHost-Apps/mastodon_ynh/