Error on command line in Mastodon since upgrade

What type of hardware are you using: VPS bought online
What YunoHost version are you running: 12.0.10
What app is this about: mastodon

Describe your issue

Since upgrading mastodon 4.3.2, and also Yunohost to v12, I can not run the command line interface for mastodon

example:

(cd /var/www/mastodon/live && sudo -u mastodon RAILS_ENV=production PATH=/opt/rbenv/versions/mastodon/bin bin/tootctl --help)

Gives:

cannot open shared object file: No such file or directory - /var/www/mastodon/live/vendor/bundle/ruby/3.3.0/gems/idn-ruby-0.1.5/lib/idn.so

Share relevant logs or error messages

there are no errors place in the log files

I tried a reboot of the server and now Mastodon will not start!

Hi Bumble,

:frowning:

If you look around in these directories, up till where does the path exist?

Yes, the file idn.so exists in that director.

Since the reboot, I now get the following

Could not find bigdecimal-3.1.8 in locally installed gems
Run bundle install --gemfile /var/www/mastodon/live/Gemfile to install missing gems.

I tried doing the bundle install as above, but there’s a whole host of errors, starting

Fetching gem metadata from https://rubygems.org/........
Installing bigdecimal 3.1.8 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/var/www/mastodon/live/vendor/bundle/ruby/3.3.0/gems/bigdecimal-3.1.8/ext/bigdecimal
/opt/rbenv/versions/3.3.5/bin/ruby extconf.rb
checking for __builtin_clz()... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Things seem bad :frowning:

Besides those suggestions, reasens that come to mind are lack permissions or lack of disk space.

Is restoring a backup an option?

I have a full system backup before the upgrade. It looks like I can restore the individual mastodon App but will that cause any issues for other apps I run on the same server?

If you restore only Mastodon, that will no cause issues for the other apps.

If Mastodon has worked a while after the upgrade, you will lose the data/messages between the making of the backup until Mastodon stopped working.

An intermediate step would be to unpack the backup to a location, and compare file permissions. Seeing Mastodon is a large and complex app, that will involve more trouble than restoring.

Something you could do anyway, is backup the currently not working Mastodon as well so that you can revert to the current not working situation, or compare in the future.

1 Like

Just for completeness, to update and close the post…
I restored from a previous backup, and all works fine. The earlier backup had the previous version of mastodon on it. I will attempt an upgrade at a later time.

1 Like

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