Project

General

Profile

Upgrade Debian (Jessie) and Redmine (3.2.1.stable)

Added by Andreas Bruhn about 3 years ago

Hi,

we are usig Redmine 3.2.1.stable on a Debian server (Jessie).
I want to update the debian server from Jessie to Stretch and then to Buster.

But when I upgrade to Strech, Redmine is not running any more (see screenshot).

Do I have to upgrade Redmine, when I update the Debian? Any ideas ;-)?

Many thanks in advance,
Andreas

redmine.png (27 KB) redmine.png Error

Replies (9)

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Liane Hampe about 3 years ago

Hi Andreas,

It might be that you need to rebuild the gems native extensions. Did you try that?

Best Regards,
Liane

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Andreas Bruhn about 3 years ago

Hi Liane,

I'm not sure. Can you tell me how to do that?
Unfortunately, I didn't install the system (I took it over recently) so I'm not very familiar with it yet.

Best regards,
Andreas

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Liane Hampe about 3 years ago

Hi Andreas,

did you do anything at all in the context of Redmine after upgrading your operating system? If not, you should check some other things first.

There are numerous things to check, e.g. Ruby version, Bundler version, and other auxillary software that might break the application. How about the database and webserver and so on. There are plenty components required by Redmine.

The error message is from passenger, the application server. Maybe you can get a logfile for more information.

Best Regards,
Liane

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Andreas Bruhn over 2 years ago

Hi Liane,

sorry for the very very late answer... I have checked a few version levels now:

Linux Debian 10.11 (Buster) (before Update: 8 (Jessie))
Redmine 3.2.1.stable
Ruby 2.5.5p157
Rails 4.2.5.2
Bundler version 1.11.2
MariaDB 10.3.31 database server (before Update: MySQL)

The last lines form production.log:
Mysql2::Error (Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)):
mysql2 (0.3.20) lib/mysql2/client.rb:70:in `connect'
mysql2 (0.3.20) lib/mysql2/client.rb:70:in `initialize'
activerecord (4.2.5.2) lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `new'
activerecord (4.2.5.2) lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `mysql2_connection'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:438:in `new_connection'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:448:in `checkout_new_connection'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:422:in `acquire_connection'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:349:in `block in checkout'
/usr/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in `checkout'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in `block in connection'
/usr/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:262:in `connection'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:571:in `retrieve_connection'
activerecord (4.2.5.2) lib/active_record/connection_handling.rb:113:in `retrieve_connection'
activerecord (4.2.5.2) lib/active_record/connection_handling.rb:87:in `connection'
activerecord (4.2.5.2) lib/active_record/query_cache.rb:51:in `restore_query_cache_settings'
activerecord (4.2.5.2) lib/active_record/query_cache.rb:43:in `rescue in call'
activerecord (4.2.5.2) lib/active_record/query_cache.rb:31:in `call'
activerecord (4.2.5.2) lib/active_record/connection_adapters/abstract/connection_pool.rb:653:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
activesupport (4.2.5.2) lib/active_support/callbacks.rb:88:in `__run_callbacks__'
activesupport (4.2.5.2) lib/active_support/callbacks.rb:778:in `_run_call_callbacks'
activesupport (4.2.5.2) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (4.2.5.2) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/remote_ip.rb:78:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
railties (4.2.5.2) lib/rails/rack/logger.rb:38:in `call_app'
railties (4.2.5.2) lib/rails/rack/logger.rb:20:in `block in call'
activesupport (4.2.5.2) lib/active_support/tagged_logging.rb:68:in `block in tagged'
activesupport (4.2.5.2) lib/active_support/tagged_logging.rb:26:in `tagged'
activesupport (4.2.5.2) lib/active_support/tagged_logging.rb:68:in `tagged'
railties (4.2.5.2) lib/rails/rack/logger.rb:20:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/request_id.rb:21:in `call'
rack (1.6.4) lib/rack/methodoverride.rb:22:in `call'
rack (1.6.4) lib/rack/runtime.rb:18:in `call'
activesupport (4.2.5.2) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
actionpack (4.2.5.2) lib/action_dispatch/middleware/static.rb:116:in `call'
rack (1.6.4) lib/rack/sendfile.rb:113:in `call'
railties (4.2.5.2) lib/rails/engine.rb:518:in `call'
railties (4.2.5.2) lib/rails/application.rb:165:in `call'
railties (4.2.5.2) lib/rails/railtie.rb:194:in `public_send'
railties (4.2.5.2) lib/rails/railtie.rb:194:in `method_missing'
/usr/lib/ruby/vendor_ruby/phusion_passenger/rack/thread_handler_extension.rb:74:in `process_request'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler/thread_handler.rb:141:in `accept_and_process_next_request'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler/thread_handler.rb:109:in `main_loop'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler.rb:455:in `block (3 levels) in start_threads'

Do you notice anything that could be a problem?

Best regards,
Andreas

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Liane Hampe over 2 years ago

Hi Andreas,

It seems as if there are some versions mixed due to this line

 /usr/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'.

Maybe Redmine is not using the right Ruby Version.

Could you please also show the RubyGems Environment by typing

gem env

in your console?

Did you also check your database configuration? You can find it in

<redmine_root>/config/database.yml

Best Regards
Liane

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Andreas Bruhn over 2 years ago

Hi Liane,

thank you for your answer!
I have checked "gem env" in the console:

RubyGems Environment:
- RUBYGEMS VERSION: 2.7.6.2
- RUBY VERSION: 2.5.5 (2019-03-15 patchlevel 157) [x86_64-linux-gnu]
- INSTALLATION DIRECTORY: /var/lib/gems/2.5.0
- USER INSTALLATION DIRECTORY: /root/.gem/ruby/2.5.0
- RUBY EXECUTABLE: /usr/bin/ruby2.5
- EXECUTABLE DIRECTORY: /usr/local/bin
- SPEC CACHE DIRECTORY: /root/.gem/specs
- SYSTEM CONFIGURATION DIRECTORY: /etc
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-linux
- GEM PATHS:
- /var/lib/gems/2.5.0
- /root/.gem/ruby/2.5.0
- /usr/lib/x86_64-linux-gnu/rubygems-integration/2.5.0
- /usr/share/rubygems-integration/2.5.0
- /usr/share/rubygems-integration/all
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- https://rubygems.org/
- SHELL PATH:
- /usr/local/sbin
- /usr/local/bin
- /usr/sbin
- /usr/bin
- /sbin
- /bin

The database configuration is the same like before.

production:
adapter: mysql2
database: redmine_test
host: localhost
username: redmine_test
password: redmine_test
encoding: utf8

Does this need to be adjusted because of the change to MariaDB?

Best regards
Andreas

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Liane Hampe over 2 years ago

Hi Andreas,

the db adapter is the same for both MySQL and MariaDB.

Your Gem environment looks o.k. Nevertheless, you have had the line with Ruby 2.1 in your error logfile. Did you check whether Ruby version 2.1 is still installed and could you uninstall it if it is not needed elsewhere?

Are you using rbenv for Ruby version management?

Sorry, some more questions ... :)

Best Regards
Liane

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Andreas Bruhn over 2 years ago

Hi Liane,

I have deinstalled Ruby 2.1 now with "sudo apt-get purge ruby2.1*" and "sudo apt-get purge libruby2.1*", but it doesn't change anything. Even the production.log has no new entries.
I have now installed rbenv (it wasn't before), but I think it doesn't work right...

rbenv version -> system (set by /root/.rbenv/version)
rbenv versions -> * system (set by /root/.rbenv/version)
rbenv global -> system

I had assumed that the query "Version" or "Versions" would show me my Ruby versions.

Best regards
Andreas

RE: Upgrade Debian (Jessie) and Redmine (3.2.1.stable) - Added by Liane Hampe over 2 years ago

Hi Andreas,

You should follow these instructions here https://github.com/rbenv/rbenv. Read it carefully and do the steps as explained, then it will work.

When there is no content in the production log and Ruby 2.1 is uninstalled, then it could be that your Redmine instance did depend on Ruby 2.1 and not on Ruby 2.5 as you thought.

You should try to connect Ruby 2.5 to Redmine and try to start the instance again.

Best Regards
Liane

    (1-9/9)