Unable to update to 5.1.1 on ubuntu 20.04 (bundle issue)

  • Used Zammad 5.0 (with mysql)
  • Operating system: Ubuntu Server 20.04 x64
  • Browser + version: Chrome/Firefox

Hi,

I can’t install update on our Zammad neither with deb package nor the sources which get me errors.
The first one was

“mysql2 not found !”

So, I tried many thing including change version of ruby, updating gem, ruby, … but I have every time a new error !
Sometimes the ruby version is 2.6.5 and Gemfile 2.7.0, after I tried to install 2.7.4 (and modify Gemfile with 2.7.4)…I even tried to install last ruby 3.1.2… but in all cases bundle gives me errors. The latest one is (with official documentation) the following :

zammad@server-1:/opt/zammad$ bundle install --without test development postgres
Calling `DidYouMean::SPELL_CHECKERS.merge!(error_name => spell_checker)' has been deprecated. Please call `DidYouMean.correct_error(error_name, spell_checker)' instead.
[DEPRECATED] The `--without` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set --local without 'test development postgres'`, and stop using this flag
Fetching gem metadata from https://rubygems.org/
Fetching gem metadata from https://rubygems.org/........
Using rake 13.0.6
Using simple_po_parser 1.1.6
Using concurrent-ruby 1.1.10
Using minitest 5.15.0
Using erubi 1.10.0
Using mini_portile2 2.8.0
Using builder 3.2.4
Using crass 1.0.6
Using rack 2.2.3
Fetching racc 1.6.0
Fetching nio4r 2.5.8
Using thread_safe 0.3.6
Using websocket-extensions 0.1.5
Using zeitwerk 2.5.4
Using mini_mime 1.1.2
Using multi_json 1.15.0
Using method_source 1.0.0
Using thor 1.2.1
Using public_suffix 4.0.6
Fetching ffi 1.15.5
Using marcel 1.0.2
Using httpclient 2.8.3
Using little-plugger 1.1.4
Using nori 2.6.0
Using execjs 2.8.1
Using clavius 1.0.4
Fetching msgpack 1.4.5
Installing racc 1.6.0 with native extensions
Installing nio4r 2.5.8 with native extensions
Installing msgpack 1.4.5 with native extensions
Installing ffi 1.15.5 with native extensions
Using browser 5.3.1
Using buftok 0.2.0
Using bundler 2.2.20
Using nestful 1.1.4
Using coffee-script-source 1.12.2
Using csv 3.2.2
Using daemons 1.4.1
Using dalli 3.2.1
Using diffy 3.4.0
Fetching unf_ext 0.0.8
Installing unf_ext 0.0.8 with native extensions
Using eco-source 1.1.0.rc.1
Fetching eventmachine 1.2.7
Installing eventmachine 1.2.7 with native extensions
Fetching http_parser.rb 0.6.0
Installing http_parser.rb 0.6.0 with native extensions
Using equalizer 0.0.11
Using faraday-em_http 1.0.0
Using faraday-em_synchrony 1.0.0
Using faraday-excon 1.1.0
Using faraday-httpclient 1.0.1
Using multipart-post 2.1.1
Using faraday-net_http 1.0.1
Using faraday-net_http_persistent 1.2.0
Using faraday-patron 1.0.0
Using faraday-rack 1.0.0
Using faraday-retry 1.0.3
Using ruby2_keywords 0.0.5
Using oauth 0.5.8
Using hashie 5.0.0
Fetching hiredis 0.6.3
Installing hiredis 0.6.3 with native extensions
Using htmlentities 4.3.4
Using http-form_data 2.3.0
Using http-accept 1.7.0
Using ice_cube 0.16.4
Using inflection 1.0.0
Fetching json 2.6.1
Installing json 2.6.1 with native extensions
Using jwt 2.3.0
Fetching kgio 2.11.4
Installing kgio 2.11.4 with native extensions
Using rexml 3.2.5
Using messagebird-rest 3.0.0
Using mime-types-data 3.2022.0105
Using multi_xml 0.6.0
Fetching mysql2 0.5.3
Installing mysql2 0.5.3 with native extensions
Using naught 1.1.0
Using net-ldap 0.17.0
Using netrc 0.11.0
Fetching openssl 3.0.0
Installing openssl 3.0.0 with native extensions
Fetching raindrops 0.20.0
Installing raindrops 0.20.0 with native extensions
Using rchardet 1.8.0
Using redis 4.6.0
Fetching rszr 0.5.2
Installing rszr 0.5.2 with native extensions
Using rubyntlm 0.6.3
Using tilt 2.0.10
Using simple_oauth 0.3.1
Using slack-notifier 2.4.0
Using telephone_number 1.4.14
Using writeexcel 1.0.5
Using PoParser 3.2.6
Using aasm 5.2.0
Using i18n 1.10.0
Using rack-test 1.1.0
Using rack-attack 6.6.0
Using sprockets 3.7.2
Using tzinfo 1.2.9
Fetching websocket-driver 0.7.5
Installing websocket-driver 0.7.5 with native extensions
Using memoizable 0.4.2
Using mail 2.7.2.edge from https://github.com/zammad-deps/mail (at 2-7-stable@9265cf7)
Using addressable 2.8.0
Using logging 2.3.0
Using autoprefixer-rails 10.4.2.0
Using uglifier 4.2.0
Using clearbit 0.3.3
Using coffee-script 2.4.1
Using faraday-multipart 1.0.3
Using gmail_xoauth 0.4.2
Using omniauth 1.9.1
Using icalendar 2.7.1
Using mime-types 3.4.1
Using activesupport 6.0.4.8
Using biz 1.8.2
Using eco 1.0.0
Using faraday 1.10.0
Using icalendar-recurrence 1.1.3
Using omniauth-oauth 1.2.0
Using globalid 1.0.0
Using activemodel 6.0.4.8
Using delayed_job 4.1.10
Using oauth2 1.4.9
Using omniauth-twitter 1.4.0
Using pundit 2.2.0
Using zendesk_api 1.35.0
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/racc-1.6.0/ext/racc/cparse
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-xhbe1h.rb extconf.rb
checking for rb_block_call()... yes
checking for rb_ary_subseq()... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/racc-1.6.0/ext/racc/cparse
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/racc-1.6.0/ext/racc/cparse
make DESTDIR=
compiling cparse.c
linking shared-object racc/cparse.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/racc-1.6.0/ext/racc/cparse
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.-.racc.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/racc-1.6.0 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/racc-1.6.0/gem_make.out

An error occurred while installing racc (1.6.0), and Bundler
cannot continue.
Make sure that `gem install racc -v '1.6.0' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
rails was resolved to 6.0.4.8, which depends on
actioncable was resolved to 6.0.4.8, which depends on
actionpack was resolved to 6.0.4.8, which depends on
actionview was resolved to 6.0.4.8, which depends on
rails-dom-testing was resolved to 2.0.3, which depends on
nokogiri was resolved to 1.13.4, which depends on
racc

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/nio4r-2.5.8/ext/nio4r
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-161epdf.rb extconf.rb
checking for unistd.h... yes
checking for linux/aio_abi.h... yes
checking for linux/io_uring.h... yes
checking for sys/select.h... yes
checking for port_event_t in poll.h... no
checking for sys/epoll.h... yes
checking for sys/event.h... no
checking for port_event_t in port.h... no
checking for sys/resource.h... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/nio4r-2.5.8/ext/nio4r
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/nio4r-2.5.8/ext/nio4r
make DESTDIR=
compiling bytebuffer.c
compiling monitor.c
compiling nio4r_ext.c
In file included from nio4r_ext.c:6:
../libev/ev.c:2136:31: warning: ‘ev_default_loop_ptr’ initialized and
declared ‘extern’
2136 | EV_API_DECL struct ev_loop *ev_default_loop_ptr = 0; /*
needs to be initialised to make it a definition despite extern <em>/
| ^~~~~~~~~~~~~~~~~~~
../libev/ev.c: In function ‘evpipe_write’:
../libev/ev.c:2798:11: warning: ignoring return value of ‘write’,
declared with attribute warn_unused_result [-Wunused-result]
2798 | write (evpipe [1], &counter, sizeof (uint64_t));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../libev/ev.c:2810:11: warning: ignoring return value of ‘write’,
declared with attribute warn_unused_result [-Wunused-result]
2810 | write (evpipe [1], &(evpipe [1]), 1);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../libev/ev.c: In function ‘pipecb’:
../libev/ev.c:2831:11: warning: ignoring return value of ‘read’,
declared with attribute warn_unused_result [-Wunused-result]
2831 | read (evpipe [1], &counter, sizeof (uint64_t));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../libev/ev.c:2845:11: warning: ignoring return value of ‘read’,
declared with attribute warn_unused_result [-Wunused-result]
2845 | read (evpipe [0], &dummy, sizeof (dummy));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compiling selector.c
selector.c: In function ‘NIO_Selector_synchronize’:
selector.c:301:26: warning: passing argument 1 of ‘rb_ensure’ from
incompatible pointer type [-Wincompatible-pointer-types]
301 | return rb_ensure(func, (VALUE)args,
NIO_Selector_unlock, self);
| ^~~~
| |
| VALUE (</em>)(VALUE <em>) {aka long
unsigned int (</em>)(long unsigned int <em>)}
In file included from
/usr/share/rvm/rubies/ruby-2.7.4/include/ruby-2.7.0/ruby.h:33,
from nio4r.h:10,
from selector.c:6:
/usr/share/rvm/rubies/ruby-2.7.4/include/ruby-2.7.0/ruby/ruby.h:1990:17:
note: expected ‘VALUE (</em>)(VALUE)’ {aka ‘long unsigned int (<em>)(long
unsigned int)’} but argument is of type ‘VALUE (</em>)(VALUE <em>)’ {aka
‘long unsigned int (</em>)(long unsigned int <em>)’}
1990 | VALUE rb_ensure(VALUE(</em>)(VALUE),VALUE,VALUE(*)(VALUE),VALUE);
| ^~~~~~~~~~~~~~~
selector.c: In function ‘NIO_Selector_wakeup’:
selector.c:499:5: warning: ignoring return value of ‘write’, declared
with attribute warn_unused_result [-Wunused-result]
499 | write(selector->wakeup_writer, "\0", 1);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
linking shared-object nio4r_ext.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/nio4r-2.5.8/ext/nio4r
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/nio4r-2.5.8 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/nio4r-2.5.8/gem_make.out

An error occurred while installing nio4r (2.5.8), and
Bundler cannot continue.
Make sure that `gem install nio4r -v '2.5.8' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
rails was resolved to 6.0.4.8, which depends on
actioncable was resolved to 6.0.4.8, which depends on
nio4r

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/websocket-driver-0.7.5/ext/websocket-driver
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-195bxu3.rb extconf.rb
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/websocket-driver-0.7.5/ext/websocket-driver
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/websocket-driver-0.7.5/ext/websocket-driver
make DESTDIR=
compiling websocket_mask.c
linking shared-object websocket_mask.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/websocket-driver-0.7.5/ext/websocket-driver
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/websocket-driver-0.7.5 for
inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/websocket-driver-0.7.5/gem_make.out

An error occurred while installing websocket-driver (0.7.5),
and Bundler cannot continue.
Make sure that `gem install websocket-driver -v '0.7.5' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
rails was resolved to 6.0.4.8, which depends on
actioncable was resolved to 6.0.4.8, which depends on
websocket-driver

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/ffi-1.15.5/ext/ffi_c
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-poujkv.rb extconf.rb
checking for ffi_prep_closure_loc() in -lffi... yes
checking for ffi_prep_cif_var()... yes
checking for ffi_raw_call()... yes
checking for ffi_prep_raw_closure()... yes
checking for whether -pthread is accepted as LDFLAGS... yes
creating extconf.h
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/ffi-1.15.5/ext/ffi_c
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/ffi-1.15.5/ext/ffi_c
make DESTDIR=
compiling AbstractMemory.c
compiling ArrayType.c
compiling Buffer.c
compiling Call.c
compiling ClosurePool.c
compiling DynamicLibrary.c
compiling Function.c
compiling FunctionInfo.c
compiling LastError.c
compiling LongDouble.c
compiling MappedType.c
compiling MemoryPointer.c
compiling MethodHandle.c
compiling Platform.c
compiling Pointer.c
compiling Struct.c
compiling StructByValue.c
compiling StructLayout.c
compiling Thread.c
compiling Type.c
compiling Types.c
compiling Variadic.c
compiling ffi.c
linking shared-object ffi_c.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/ffi-1.15.5/ext/ffi_c
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/ffi-1.15.5 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/ffi-1.15.5/gem_make.out

An error occurred while installing ffi (1.15.5), and Bundler
cannot continue.
Make sure that `gem install ffi -v '1.15.5' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
argon2 was resolved to 2.1.1, which depends on
ffi-compiler was resolved to 1.0.1, which depends on
ffi

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/msgpack-1.4.5/ext/msgpack
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-1jh52n2.rb extconf.rb
checking for ruby/st.h... yes
checking for st.h... yes
checking for rb_enc_interned_str() in ruby.h... no
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/msgpack-1.4.5/ext/msgpack
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/msgpack-1.4.5/ext/msgpack
make DESTDIR=
compiling buffer.c
compiling buffer_class.c
compiling extension_value_class.c
compiling factory_class.c
compiling packer.c
compiling packer_class.c
compiling packer_ext_registry.c
compiling rbinit.c
compiling rmem.c
compiling unpacker.c
compiling unpacker_class.c
compiling unpacker_ext_registry.c
linking shared-object msgpack/msgpack.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/msgpack-1.4.5/ext/msgpack
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.-.msgpack.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/msgpack-1.4.5 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/msgpack-1.4.5/gem_make.out

An error occurred while installing msgpack (1.4.5), and
Bundler cannot continue.
Make sure that `gem install msgpack -v '1.4.5' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
bootsnap was resolved to 1.11.1, which depends on
msgpack

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/unf_ext-0.0.8/ext/unf_ext
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-dyzcrn.rb extconf.rb
checking for -lstdc++... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/unf_ext-0.0.8/ext/unf_ext
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/unf_ext-0.0.8/ext/unf_ext
make DESTDIR=
compiling unf.cc
linking shared-object unf_ext.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/unf_ext-0.0.8/ext/unf_ext
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/unf_ext-0.0.8 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/unf_ext-0.0.8/gem_make.out

An error occurred while installing unf_ext (0.0.8), and
Bundler cannot continue.
Make sure that `gem install unf_ext -v '0.0.8' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
twitter was resolved to 7.0.0, which depends on
http was resolved to 4.4.1, which depends on
http-cookie was resolved to 1.0.4, which depends on
domain_name was resolved to 0.5.20190701, which depends on
unf was resolved to 0.1.4, which depends on
unf_ext

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-etg7at.rb extconf.rb
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
make DESTDIR=
compiling ruby_http_parser.c
compiling ryah_http_parser.c
linking shared-object ruby_http_parser.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/http_parser.rb-0.6.0 for
inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/http_parser.rb-0.6.0/gem_make.out

An error occurred while installing http_parser.rb (0.6.0),
and Bundler cannot continue.
Make sure that `gem install http_parser.rb -v '0.6.0' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
em-websocket was resolved to 0.5.3, which depends on
http_parser.rb

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/hiredis-0.6.3/ext/hiredis_ext
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-18ys76w.rb extconf.rb
checking for sys/socket.h... yes
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes
-Wwrite-strings -g -ggdb net.c
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes
-Wwrite-strings -g -ggdb hiredis.c
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes
-Wwrite-strings -g -ggdb sds.c
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes
-Wwrite-strings -g -ggdb async.c
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes
-Wwrite-strings -g -ggdb read.c
ar rcs libhiredis.a net.o hiredis.o sds.o async.o read.o
checking for rb_thread_fd_select()... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/hiredis-0.6.3/ext/hiredis_ext
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/hiredis-0.6.3/ext/hiredis_ext
make DESTDIR=
compiling connection.c
connection.c: In function ‘connection_read’:
connection.c:458:24: warning: passing argument 2 of ‘__get_reply’
discards ‘volatile’ qualifier from pointer target type
[-Wdiscarded-qualifiers]
458 | if (__get_reply(pc,&reply) == -1)
| ^~~~~~
connection.c:375:55: note: expected ‘VALUE *’ {aka ‘long unsigned int
*’} but argument is of type ‘volatile VALUE *’ {aka ‘volatile long
unsigned int *’}
375 | static int __get_reply(redisParentContext *pc, VALUE *reply)
{
| ~~~~~~~^~~~~
compiling hiredis_ext.c
compiling reader.c
linking shared-object hiredis/ext/hiredis_ext.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/hiredis-0.6.3/ext/hiredis_ext
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.-.hiredis.-.ext.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/hiredis-0.6.3 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/hiredis-0.6.3/gem_make.out

An error occurred while installing hiredis (0.6.3), and
Bundler cannot continue.
Make sure that `gem install hiredis -v '0.6.3' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
hiredis

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/json-2.6.1/ext/json/ext/generator
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-10hgl48.rb extconf.rb
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/json-2.6.1/ext/json/ext/generator
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/json-2.6.1/ext/json/ext/generator
make DESTDIR=
compiling generator.c
linking shared-object json/ext/generator.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/json-2.6.1/ext/json/ext/generator
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.-.json.-.ext.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/json-2.6.1 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/json-2.6.1/gem_make.out

An error occurred while installing json (2.6.1), and Bundler
cannot continue.
Make sure that `gem install json -v '2.6.1' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
koala was resolved to 3.1.0, which depends on
json

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/kgio-2.11.4/ext/kgio
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-1oigc6s.rb extconf.rb
checking for CLOCK_MONOTONIC in time.h... yes
checking for clockid_t in time.h... yes
checking for clock_gettime() in -lrt... yes
checking for t_open() in -lnsl... no
checking for socket() in -lsocket... no
checking for poll() in poll.h... yes
checking for getaddrinfo() in sys/types.h,sys/socket.h,netdb.h... yes
checking for getnameinfo() in sys/types.h,sys/socket.h,netdb.h... yes
checking for struct sockaddr_storage in sys/types.h,sys/socket.h...
yes
checking for accept4() in sys/socket.h... yes
checking for sys/select.h... yes
checking for writev() in sys/uio.h... yes
checking for ruby/io.h... yes
checking for rb_io_t.fd in ruby.h,ruby/io.h... yes
checking for rb_io_t.mode in ruby.h,ruby/io.h... yes
checking for rb_io_t.pathv in ruby.h,ruby/io.h... yes
checking for struct RFile in ruby.h,ruby/io.h... yes
checking size of struct RFile in ruby.h,ruby/io.h... 24
checking for struct RObject... yes
checking size of struct RObject... 40
checking size of int... 4
checking for rb_io_ascii8bit_binmode()... yes
checking for rb_update_max_fd()... yes
checking for rb_fd_fix_cloexec()... yes
checking for rb_cloexec_open()... yes
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for rb_thread_blocking_region()... no
checking for rb_thread_io_blocking_region()... yes
checking for rb_str_set_len()... yes
checking for rb_hash_clear() in ruby.h... yes
checking for rb_time_interval()... yes
checking for rb_wait_for_single_fd()... yes
checking for rb_str_subseq()... yes
checking for rb_ary_subseq()... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/kgio-2.11.4/ext/kgio
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/kgio-2.11.4/ext/kgio
make DESTDIR=
compiling accept.c
compiling autopush.c
compiling connect.c
compiling kgio_ext.c
compiling poll.c
compiling read.c
compiling tryopen.c
compiling wait.c
compiling write.c
compiling writev.c
linking shared-object kgio_ext.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/kgio-2.11.4/ext/kgio
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/kgio-2.11.4 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/kgio-2.11.4/gem_make.out

An error occurred while installing kgio (2.11.4), and
Bundler cannot continue.
Make sure that `gem install kgio -v '2.11.4' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
unicorn was resolved to 6.1.0, which depends on
kgio

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/mysql2-0.5.3/ext/mysql2
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-1tmhdw1.rb extconf.rb
checking for rb_absint_size()... yes
checking for rb_absint_singlebit_p()... yes
checking for rb_wait_for_single_fd()... yes
*** 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.

Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/share/rvm/rubies/ruby-2.7.4/bin/$(RUBY_BASE_NAME)
--with-mysql-dir
--without-mysql-dir
--with-mysql-include
--without-mysql-include=${mysql-dir}/include
--with-mysql-lib
--without-mysql-lib=${mysql-dir}/lib
--with-mysql-config
--without-mysql-config
--with-mysqlclient-dir
--without-mysqlclient-dir
--with-mysqlclient-include
--without-mysqlclient-include=${mysqlclient-dir}/include
--with-mysqlclient-lib
--without-mysqlclient-lib=${mysqlclient-dir}/lib
--with-mysqlclientlib
--without-mysqlclientlib
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/2.7.0/mkmf.rb:1050:in
`block in find_library': undefined method `split' for nil:NilClass
(NoMethodError)
from /usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/2.7.0/mkmf.rb:1050:in
`collect' from /usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/2.7.0/mkmf.rb:1050:in `find_library'
from extconf.rb:87:in `

'

To see why this extension failed to compile, please check the
mkmf.log which can be found here:

/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/mysql2-0.5.3/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/mysql2-0.5.3 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/mysql2-0.5.3/gem_make.out

An error occurred while installing mysql2 (0.5.3), and
Bundler cannot continue.
Make sure that `gem install mysql2 -v '0.5.3' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
mysql2

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/rszr-0.5.2/ext/rszr
/usr/share/rvm/rubies/ruby-2.7.4/bin/ruby -I
/usr/share/rvm/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0 -r
./siteconf20220509-282390-15m4wei.rb extconf.rb
checking for Imlib2.h... yes
checking for imlib_set_cache_size() in -lImlib2... yes
creating Makefile

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/rszr-0.5.2/ext/rszr
make DESTDIR= clean

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/rszr-0.5.2/ext/rszr
make DESTDIR=
compiling errors.c
compiling image.c
compiling rszr.c
linking shared-object rszr/rszr.so

current directory:
/usr/share/rvm/gems/ruby-2.7.4/gems/rszr-0.5.2/ext/rszr
make DESTDIR= install
make: /usr/bin/mkdir: Command not found
make: *** [Makefile:202: .sitearchdir.-.rszr.time] Error 127

make install failed, exit code 2

Gem files will remain installed in
/usr/share/rvm/gems/ruby-2.7.4/gems/rszr-0.5.2 for inspection.
Results logged to
/usr/share/rvm/gems/ruby-2.7.4/extensions/x86_64-linux/2.7.0/rszr-0.5.2/gem_make.out

An error occurred while installing rszr (0.5.2), and Bundler
cannot continue.
Make sure that `gem install rszr -v '0.5.2' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
rszr

I need to upgrade without loose my database of course!
Can someone help me ?
I despair.

Your current Zammad version, is it installed by package or source?

With aptitude, so package.
Since 4.0 I never had a problem with each update.
But this time, the end of the world has arrived :wink:

Is it possible that I have wrong PPA ?

I’m jsut trying sudo apt reinstall zammad

It seems to work… the installation is currently migrating my tickets to postGreSQL (I didn’t ask for anything, and I was on MySQL). Progress : [ 60%]

Here is result of apt reinstall zammad :

zammad@mgc-srv-1:/opt/zammad$ sudo apt reinstall zammad
[sudo] password for zammad: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libevent-2.1-6 libevent-core-2.1-6 libevent-extra-2.1-6 libreadline7 libssl1.0.0 libtinfo5
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 0 not upgraded.
Need to get 145 MB of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 https://dl.packager.io/srv/deb/zammad/zammad/stable/ubuntu 20.04/main amd64 zammad amd64 5.1.1-1651760289.13e3887d.focal [145 MB]
Fetched 145 MB in 11s (13.6 MB/s)                                                                                                                                                                                 
(Reading database ... 250866 files and directories currently installed.)
Preparing to unpack .../zammad_5.1.1-1651760289.13e3887d.focal_amd64.deb ...

Unpacking zammad (5.1.1-1651760289.13e3887d.focal) over (5.1.1-1651760289.13e3887d.focal) .........................................................................................................................

Setting up zammad (5.1.1-1651760289.13e3887d.focal) ...................................# (Re)creating init scripts0%] [###############........................................
Nothing to do.
Nothing to do.
Nothing to do.
# Enabling Zammad on boot
# Stopping Zammad
# Installing zammad on postgresql
# Creating postgresql bootstart
Synchronizing state of postgresql.service with SysV service script with /lib/systemd/sy
stemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable postgresql
# Restarting postgresql server
# Creating zammad postgresql user
CREATE ROLE
# Creating zammad postgresql db
# Grant privileges to new postgresql user
GRANT
# Updating database.yml
# ... Fixing permission database.yml
== 20120101000001 CreateBase: migrating =======================================
-- create_table(:sessions, {:id=>:integer})
   -> 0.3278s
-- add_index(:sessions, :session_id)
   -> 0.1544s
-- add_index(:sessions, :updated_at)

// ....... DB creation and tickets migration truncated in this log because limited to 32'000 chars .......

== 20220329075919 RemoveDuplicateTranslations: migrating ======================
== 20220329075919 RemoveDuplicateTranslations: migrated (0.0034s) =============

== 20220330092945 ObjectManagerUpdateUserPassword: migrating ==================
== 20220330092945 ObjectManagerUpdateUserPassword: migrated (0.0035s) =========

== 20220405133444 Issue4049FixObjectLookup: migrating =========================
== 20220405133444 Issue4049FixObjectLookup: migrated (0.0034s) ================

# Configuring Elasticsearch...
Traceback (most recent call last):
	47: from /opt/zammad/bin/rails:9:in `<main>'
	46: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	45: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	44: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/commands.rb:18:in `<main>'
	43: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command.rb:46:in `invoke'
	42: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/base.rb:69:in `perform'
	41: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor.r
b:392:in `dispatch'
	40: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/i
nvocation.rb:127:in `invoke_command'
	39: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/c
ommand.rb:27:in `run'
	38: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/commands/runner/runner_command.rb:33:in `perform'
	37: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/actions.rb:15:in `require_application_and_environment!'
	36: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/actions.rb:28:in `require_environment!'
	35: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application.rb:339:in `require_environment!'
	34: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:324:in `require'
	33: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:291:in `load_dependency'
	32: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:324:in `block in require'
	31: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/kernel.rb:35:in `require'
	30: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	29: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	28: from /opt/zammad/config/environment.rb:7:in `<main>'
	27: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application.rb:363:in `initialize!'
	26: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:60:in `run_initializers'
	25: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:205:in `t
sort_each'
	24: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:226:in `t
sort_each'
	23: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `e
ach_strongly_connected_component'
	22: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `c
all'
	21: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `e
ach'
	20: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:349:in `b
lock in each_strongly_connected_component'
	19: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:431:in `e
ach_strongly_connected_component_from'
	18: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:350:in `b
lock (2 levels) in each_strongly_connected_component'
	17: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:228:in `b
lock in tsort_each'
	16: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:61:in `block in run_initializers'
	15: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:32:in `run'
	14: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:32:in `instance_exec'
	13: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application/finisher.rb:122:in `block in <module:Finisher>'
	12: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:317:in `eager_load_all'
	11: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:317:in `each'
	10: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:217:in `eager_load'
	 9: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:217:in `synchronize'
	 8: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:232:in `block in eager_load'
	 7: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:18:in `ls'
	 6: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:18:in `each_child'
	 5: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:26:in `block in ls'
	 4: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:237:in `block (2 levels) in eager_load'
	 3: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:95:in `cget'
	 2: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:95:in `const_get'
	 1: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/kernel.rb:28:in `require'
/opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/zeitwerk/loader/cal
lbacks.rb:25:in `on_file_autoloaded': expected file /opt/zammad/app/controllers/
sessions/collection_ticket.rb to define constant Sessions::CollectionTicket, but
 didn't (Zeitwerk::NameError)
-- Nevermind, no es_url is set, leaving Elasticsearch untouched ...!
-- The above is all right if you don't want to use Elasticsearch (locally) - if 
this is not intended, consult https://docs.zammad.org !
Traceback (most recent call last):
	47: from /opt/zammad/bin/rails:9:in `<main>'
	46: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	45: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	44: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/commands.rb:18:in `<main>'
	43: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command.rb:46:in `invoke'
	42: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/base.rb:69:in `perform'
	41: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor.r
b:392:in `dispatch'
	40: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/i
nvocation.rb:127:in `invoke_command'
	39: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/c
ommand.rb:27:in `run'
	38: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/commands/runner/runner_command.rb:33:in `perform'
	37: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/actions.rb:15:in `require_application_and_environment!'
	36: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/command/actions.rb:28:in `require_environment!'
	35: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application.rb:339:in `require_environment!'
	34: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:324:in `require'
	33: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:291:in `load_dependency'
	32: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/activesupport-6.0.4.8
/lib/active_support/dependencies.rb:324:in `block in require'
	31: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/kernel.rb:35:in `require'
	30: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	29: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/b
ootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	28: from /opt/zammad/config/environment.rb:7:in `<main>'
	27: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application.rb:363:in `initialize!'
	26: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:60:in `run_initializers'
	25: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:205:in `t
sort_each'
	24: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:226:in `t
sort_each'
	23: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `e
ach_strongly_connected_component'
	22: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `c
all'
	21: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:347:in `e
ach'
	20: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:349:in `b
lock in each_strongly_connected_component'
	19: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:431:in `e
ach_strongly_connected_component_from'
	18: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:350:in `b
lock (2 levels) in each_strongly_connected_component'
	17: from /opt/zammad/vendor/ruby-2.7.4/lib/ruby/2.7.0/tsort.rb:228:in `b
lock in tsort_each'
	16: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:61:in `block in run_initializers'
	15: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:32:in `run'
	14: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/initializable.rb:32:in `instance_exec'
	13: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/
rails/application/finisher.rb:122:in `block in <module:Finisher>'
	12: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:317:in `eager_load_all'
	11: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:317:in `each'
	10: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:217:in `eager_load'
	 9: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:217:in `synchronize'
	 8: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:232:in `block in eager_load'
	 7: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:18:in `ls'
	 6: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:18:in `each_child'
	 5: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:26:in `block in ls'
	 4: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader.rb:237:in `block (2 levels) in eager_load'
	 3: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:95:in `cget'
	 2: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/loader/helpers.rb:95:in `const_get'
	 1: from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/ze
itwerk/kernel.rb:28:in `require'
/opt/zammad/vendor/bundle/ruby/2.7.0/gems/zeitwerk-2.5.4/lib/zeitwerk/loader/cal
lbacks.rb:25:in `on_file_autoloaded': expected file /opt/zammad/app/controllers/
sessions/collection_ticket.rb to define constant Sessions::CollectionTicket, but
 didn't (Zeitwerk::NameError)
# (Re)building Elasticsearch searchindex...
# Enforcing 0600 on database.yml ...
# Starting Zammad
Module proxy already enabled
Considering dependency proxy for proxy_http:
Module proxy already enabled
Module proxy_http already enabled
Considering dependency proxy for proxy_wstunnel:
Module proxy already enabled
Module proxy_wstunnel already enabled
# Creating webserver bootstart
Synchronizing state of apache2.service with SysV service script with /lib/system
d/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable apache2
# Restarting webserver apache2
################################################################################
####

Add your fully qualified domain name or public IP to servername directive of
apache2, if this installation is done on a remote server. You have to change:
/etc/apache2/sites-available/zammad.conf and restart apache2 process.
Otherwise just open http://localhost/ in your browser to start using Zammad.

################################################################################
####

Result of this last reinstall…

Suspense… I’ll now try accessing the helpdesk.

Here is the same result as the first time I simply used apt upgrade

Service Unavailable :
Sélection_014

Zammad status

zammad@mgc-srv-1:/opt/zammad$ sudo service zammad status
● zammad.service
     Loaded: loaded (/etc/systemd/system/zammad.service; enabled; vendor preset>
     Active: active (running) since Tue 2022-05-10 07:42:56 CEST; 8min ago
   Main PID: 291730 (sleep)
      Tasks: 1 (limit: 9443)
     Memory: 252.0K
     CGroup: /system.slice/zammad.service
             └─291730 /bin/sleep infinity

May 10 07:42:56 mgc-srv-1 systemd[1]: Started zammad.service.

ElasticSearch status

zammad@mgc-srv-1:/opt/zammad$ sudo service elasticsearch status
● elasticsearch.service - Elasticsearch
     Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; ve>
    Drop-In: /etc/systemd/system/elasticsearch.service.d
             └─startup-timeout.conf
     Active: active (running) since Fri 2022-05-06 08:08:07 CEST; 3 days ago
       Docs: https://www.elastic.co
   Main PID: 7695 (java)
      Tasks: 73 (limit: 9443)
     Memory: 3.5G
     CGroup: /system.slice/elasticsearch.service
             ├─7695 /usr/share/elasticsearch/jdk/bin/java -Xshare:auto -Des.net>
             └─8235 /usr/share/elasticsearch/modules/x-pack-ml/platform/linux-x>

May 06 08:04:38 mgc-srv-1 systemd[1]: Starting Elasticsearch...
May 06 08:08:07 mgc-srv-1 systemd[1]: Started Elasticsearch.

I have a load avg of 3.3, it is too much, I think it will calm down.
I have enough memory and swap is empty.
A lot of processes with ES, I think it’s normal because it needs to re-index all.

My Apache config :
(port 4000 → port 3000 → proxy 80)

#
# this is the apache config for zammad 
#
Listen 4000

<VirtualHost *:4000>

    # replace 'localhost' with your fqdn if you want to use zammad from remote
    ServerName mgc-srv-1

    # security - prevent information disclosure about server version
    #ServerTokens Prod

    ## don't loose time with IP address lookups
    HostnameLookups Off

    ## needed for named virtual hosts
    UseCanonicalName Off

    ## configures the footer on server-generated documents
    ServerSignature Off

    ProxyRequests Off

    <Proxy mgc-srv-1:3000>
                Require local
    </Proxy>

    #RewriteEngine On
    #ProxyPass / http://mgc-srv-1:3000/
    #ProxyPassReverse / http://mgc-srv-1:3000/

    ProxyPass /assets !
    ProxyPass /favicon.ico !
    ProxyPass /robots.txt !
    ProxyPass /ws ws://127.0.0.1:6042/
    ProxyPass / http://127.0.0.1:3000/

    DocumentRoot "/opt/zammad/public"

    <Directory "/">
        Options FollowSymLinks
        AllowOverride None
    </Directory>

    <Directory "/opt/zammad/public">

<Directory "/opt/zammad/public">
        Options FollowSymLinks
                Require all granted
    </Directory>

</VirtualHost>

<VirtualHost *:80>

    ServerAdmin                 xxx@mydomain.abc
    ServerName                  hello.mydomain.abc

    HostnameLookups Off
    UseCanonicalName Off
    ServerSignature Off
    ProxyRequests Off

    <Proxy mgc-srv-1:3000>
                Require local
    </Proxy>

    ProxyPass /assets !
    ProxyPass /favicon.ico !
    ProxyPass /robots.txt !
    ProxyPass /ws ws://127.0.0.1:6042/
    ProxyPass / http://127.0.0.1:3000/

    DocumentRoot "/opt/zammad/public"

    <Directory "/">
        Options FollowSymLinks
        AllowOverride None
    </Directory>

    <Directory "/opt/zammad/public">
        Options FollowSymLinks
                Require all granted
    </Directory>

</VirtualHost>

My zammad config :
Ruby is 2.7.0 !

zammad@mgc-srv-1:/opt/zammad$ zammad config
APP_GROUP=zammad
APP_HOME=/opt/zammad
APP_NAME=zammad
APP_RUNNER_CLI=systemctl
APP_RUNNER_TYPE=systemd
APP_SAFE_NAME=zammad
APP_USER=zammad
APP_WIZARDS=
BUNDLE_BIN=vendor/bundle/bin
BUNDLE_DEPLOYMENT=1
BUNDLE_PATH=vendor/bundle
BUNDLE_WITHOUT=development:test
DISABLE_SPRING=1
GEM_PATH=/opt/zammad/vendor/bundle/ruby/2.7.0:
HOME=/home/zammad
LANG=en_US.UTF-8
MALLOC_ARENA_MAX=2
OLDPWD=/opt/zammad
ORIGINAL_PWD=/opt/zammad
PATH=/opt/zammad/vendor/yarn-v1.22.17/bin/:/opt/zammad/bin:/opt/zammad/vendor/bundle/bin:/opt/zammad/vendor/bundle/ruby/2.7.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/sbin
PORT=3000
PWD=/opt/zammad
RACK_ENV=production
RAILS_ENV=production
RAILS_LOG_TO_STDOUT=
RAILS_SERVE_STATIC_FILES=enabled
ROOT_PATH=/
RUBY_GC_MALLOC_LIMIT=1077216
RUBY_GC_MALLOC_LIMIT_MAX=2177216
RUBY_GC_OLDMALLOC_LIMIT=2177216
RUBY_GC_OLDMALLOC_LIMIT_MAX=3000100
RUBY_MALLOC_ARENA_MAX=2
SECRET_KEY_BASE=dca2172ecc6974de4d5d9b57a86045d8ba97cfc707d2dffa94a5140721ce490f5a01367b39ec11ec017f7727338a58dbe274d046ce41c74b147c179b42f4e5b6
SHLVL=0

Nothing change with port 4000 or 3000…
Telnet is responding, so service is up, but doesn’t answer anything (html).

zammad@mgc-srv-1:/opt/zammad$ zammad config:set PORT=4000
zammad@mgc-srv-1:/opt/zammad$ sudo service zammad restart
zammad@mgc-srv-1:/opt/zammad$ telnet 127.0.0.1 4000
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.

Looks like a proxy problem indeed.
Is there a special reason to proxy it twice and/or changing the default ports? :slight_smile:

About your config, although otherwise an Apache user I’m using nginx for Zammad. As it’s the default and just a proxy anyway.

If you compare your vhost conf with the example from /opt/zammad/contrib/apache2/zammad_ssl.conf, do you find any relevant differences?

Please see also: Configure the webserver — Zammad System Documentation documentation

If nothing helps, maybe just disable Apache for a moment and give nginx a try?

In fact, the server is in LAN and accessed on :

It was working great till this upgrade.

So I pushed the default apache zammad.conf configuration and default port=3000, and now the server answers on port 80 with telnet, but I still have the same issue when accessing with browser :

Service Unavailable

The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.

I really don’t understand what’s wrong with my configuration.

I can’t disable Apache2 because other Web services are running on it.

This indicates an upstream problem, the web server can’t connect to the service ‘behind’ the proxy.

You have a custom setup, it’s hard to tell from here.
If Zammad is answering on both localhost:3000 and localhost:6042 (default ports) and apache mod_proxy is configured to use those ports I’m out of ideas for now.

Maybe recreate the Apache vhost config for Zammad from scratch (with the example config), just to be sure?

Yes this is what I wrote yesterday, I now have the default apache zammad.conf installed on Apache and the default port 3000, but I get the same result, this 503 error.

zammad@mgc-srv-1:~$ cat /etc/apache2/sites-enabled/zammad.conf 
#
# this is the apache config for zammad
#

# security - prevent information disclosure about server version
ServerTokens Prod

<VirtualHost *:80>
    # replace 'localhost' with your fqdn if you want to use zammad from remote
    ServerName hello.mydomain.xxx

    ## don't loose time with IP address lookups
    HostnameLookups Off

    ## needed for named virtual hosts
    UseCanonicalName Off

    ## configures the footer on server-generated documents
    ServerSignature Off

    ProxyRequests Off
    ProxyPreserveHost On

    <Proxy 127.0.0.1:3000>
	Require local
    </Proxy>

    ProxyPass /assets !
    ProxyPass /favicon.ico !
    ProxyPass /apple-touch-icon.png !
    ProxyPass /robots.txt !
    ProxyPass /ws ws://127.0.0.1:6042/
    ProxyPass / http://127.0.0.1:3000/

    # change this line in an SSO setup
    # RequestHeader unset X-Forwarded-User

    DocumentRoot "/opt/zammad/public"

    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>

    <Directory "/opt/zammad/public">
        Options FollowSymLinks
	Require all granted
    </Directory>

</VirtualHost>

What I see now is when I try Telnet, my guess is that the proxy is working but not Zammad actually :

zammad@mgc-srv-1:~$ telnet 127.0.0.1 3000
Trying 127.0.0.1...
telnet: Unable to connect to remote host: Connection refused
zammad@mgc-srv-1:~$ telnet localhost 6042
Trying 127.0.0.1...
telnet: Unable to connect to remote host: Connection refused
zammad@mgc-srv-1:~$ telnet 192.168.1.44 3000
Trying 192.168.1.44...
telnet: Unable to connect to remote host: Connection refused
zammad@mgc-srv-1:~$ telnet 192.168.1.44 80
Trying 192.168.1.44...
Connected to 192.168.1.44.
Escape character is '^]'.
^C^[[A
Connection closed by foreign host.

Telnet response on 192.168.1.44 port 80, so Apache it’s answer, but no response from locahost on 3000 or 6042 ports.

However Zammad service is up and running :

zammad@mgc-srv-1:~$ systemctl status zammad
● zammad.service
     Loaded: loaded (/etc/systemd/system/zammad.service; enabled; vendor preset: enabl>
     Active: active (running) since Wed 2022-05-11 07:53:44 CEST; 28min ago
   Main PID: 858 (sleep)
      Tasks: 1 (limit: 9443)
     Memory: 236.0K
     CGroup: /system.slice/zammad.service
             └─858 /bin/sleep infinity

May 11 07:53:44 mgc-srv-1 systemd[1]: Started zammad.service.

Zammad config :

zammad@mgc-srv-1:~$ zammad config get
APP_GROUP=zammad
APP_HOME=/opt/zammad
APP_NAME=zammad
APP_RUNNER_CLI=systemctl
APP_RUNNER_TYPE=systemd
APP_SAFE_NAME=zammad
APP_USER=zammad
APP_WIZARDS=
BUNDLE_BIN=vendor/bundle/bin
BUNDLE_DEPLOYMENT=1
BUNDLE_PATH=vendor/bundle
BUNDLE_WITHOUT=development:test
DISABLE_SPRING=1
GEM_PATH=/opt/zammad/vendor/bundle/ruby/2.7.0:
HOME=/home/zammad
LANG=en_US.UTF-8
MALLOC_ARENA_MAX=2
OLDPWD=/
ORIGINAL_PWD=/home/morpheus
PATH=/opt/zammad/vendor/yarn-v1.22.17/bin/:/opt/zammad/bin:/opt/zammad/vendor/bundle/bin:/opt/zammad/vendor/bundle/ruby/2.7.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/sbin
PORT=3000
PWD=/opt/zammad
RACK_ENV=production
RAILS_ENV=production
RAILS_LOG_TO_STDOUT=
RAILS_SERVE_STATIC_FILES=enabled
ROOT_PATH=/
RUBY_GC_MALLOC_LIMIT=1077216
RUBY_GC_MALLOC_LIMIT_MAX=2177216
RUBY_GC_OLDMALLOC_LIMIT=2177216
RUBY_GC_OLDMALLOC_LIMIT_MAX=3000100
RUBY_MALLOC_ARENA_MAX=2
SECRET_KEY_BASE=dca2172ecc6974de4d5d9b57a86045d8ba97cfc707d2dffa94a5140721ce490f5a01367b39ec11ec017f7727338a58dbe274d046ce41c74b147c179b42f4e5b6
SHLVL=0

I can see that GEM_PATH = …/2.7.0 but Ruby version is 2.7.4 :

zammad@mgc-srv-1:~$ ruby --version
ruby 2.7.4p191 (2021-07-07 revision a21a3b7d23) [x86_64-linux]

Could this be the cause?

Had a simmular problem during my upgrade path.
Check if all the zammad processes are running. ps -ef | grep zammad
example:

$ ps -ef | grep zammad
zammad     85680       1  0 May10 ?        00:00:00 /bin/sleep infinity
zammad     85681       1  0 May10 ?        00:00:19 puma 4.3.12 (tcp://127.0.0.1:3000) [zammad]
zammad     85683       1  0 May10 ?        00:00:28 script/websocket-server.rb -b 127.0.0.1 -p 6042 start
zammad     85868       1  0 May10 ?        00:03:13 scheduler
user+   99316   99224  0 09:02 pts/0    00:00:00 grep --color=auto zammad

First is the ‘service’ that is called from the systemctl script. That will start the other services

Check the zammad logs, i had an issue where the services kept on restarting again and again.
the scheduler log would turncate every moment, spew something out, and the zammad logs would repeat a couple of lines (in different order).

*correct me if i’m wrong, my experience so far.

** edit: i believe during that time the ports 3000 and 6042 where not open either.
netstat -a | grep -E "3000|6042" for example.

1 Like

Hi,

Here is the output of ps, puma is missing but I’ve got script/rails server instead, is it ok ? :

zammad@mgc-srv-1:/var/log/zammad$ ps -ef | grep zammad
root        9943    7262  0 08:23 pts/0    00:00:00 su - zammad
zammad      9987    9943  0 08:23 pts/0    00:00:00 -bash
zammad     35361       1 92 09:46 ?        00:00:18 script/rails server -b 127.0.0.1 -p 3000
zammad     35394       1 93 09:46 ?        00:00:17 script/websocket-server.rb -b 127.0.0.1 -p 6042 start
zammad     35435       1 95 09:46 ?        00:00:09 script/scheduler.rb start -t
postgres   35464    1146 17 09:46 ?        00:00:01 postgres: 12/main: zammad zammad [local] idle
postgres   35466    1146 15 09:46 ?        00:00:01 postgres: 12/main: zammad zammad [local] idle
zammad     35482    9987  0 09:47 pts/0    00:00:00 ps -ef
zammad     35483    9987  0 09:47 pts/0    00:00:00 grep zammad

What is more worrying is that netstat does not find any occurrence of 3000/6042! This confirms my telnet results.

zammad@mgc-srv-1:/var/log/zammad$ netstat -a | grep -E "3000|6042"
zammad@mgc-srv-1:/var/log/zammad$ netstat -a
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State      
tcp        0      0 localhost:mysql         0.0.0.0:*               LISTEN     
tcp        0      0 localhost:11211         0.0.0.0:*               LISTEN     
tcp        0      0 localhost:domain        0.0.0.0:*               LISTEN     
tcp        0      0 0.0.0.0:ssh             0.0.0.0:*               LISTEN     
tcp        0      0 localhost:postgresql    0.0.0.0:*               LISTEN
...

Here is the result of tail -f
It looks like Zammad works fine (but not the interface) :

zammad@mgc-srv-1:/var/log/zammad$ tail -f production.log
I, [2022-05-11T09:43:26.125921 #34155-7480]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:43:35.690737 #34125-6980]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:43:36.600558 #34200-7160]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:43:36.601090 #34200-7160]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:43:38.743625 #34155-7480]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:43:46.043664 #34243-6980]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:43:46.044177 #34243-6980]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:43:50.670783 #34272-7480]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:43:50.671323 #34272-7480]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:43:50.710749 #34200-7160]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:43:59.388690 #34243-6980]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:44:01.975354 #34337-7160]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:01.976830 #34337-7160]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:03.587466 #34272-7480]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:44:10.111873 #34389-6980]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:10.112443 #34389-6980]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:14.342386 #34421-7480]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:14.343147 #34421-7480]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:15.051049 #34337-7160]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:44:22.566757 #34389-6980]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:44:27.157554 #34466-7160]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:27.159817 #34466-7160]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:27.419001 #34421-7480]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])
I, [2022-05-11T09:44:36.008991 #34508-6980]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:36.009854 #34508-6980]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:40.267968 #34545-7480]  INFO -- : Using Zammad's file store as Rails cache store.
I, [2022-05-11T09:44:40.268683 #34545-7480]  INFO -- : Using File as web socket session store.
I, [2022-05-11T09:44:41.567804 #34466-7160]  INFO -- : Setting.set('models_searchable', ["User", "KnowledgeBase::Answer::Translation", "Ticket", "Chat::Session", "Organization"])

What concerns me is the load of the server and especially the processes related to Zammad.

Is this a known problem in the past?

Is there any possibility to get rails or bundle log ?

When I tried to install from source, rszr could not be installed, is it a track to explore? Puma and rszr are related isnt’t ?

So, no one can help me…

Next step for me is to reinstall completely a new VM, install the 5.1.1 freshly and restore the database…

Yea sorry for the no reply, was out of office past day.
i’m no expert so cant aid you on your instance.

What helped me the last time remember i had a dev environment
(Sources installation btw) stop the zammad services, move away the old dir,
extract the working version again to the zamamd directory, copy database.yml back,
chown everything and start zammad.
Never do things without proper backups plz

my EXAMPLE DONT TRY AT HOME plz

cd /opt
mv zammad zammad-4.0.0-err
mkdir zammad
tar -xzf zammad-4.1.1.tar.gz --strip-components 1 -C zammad
cp -r zammad-4.0.0-err/.bash* zammad/
cp -r zammad-4.0.0-err/.bundle zammad/
cp -r zammad-4.0.0-err/.circleci zammad/
cp -r zammad-4.0.0-err/.gem zammad/
cp -r zammad-4.0.0-err/.gnupg zammad/
cp -r zammad-4.0.0-err/.profile zammad/
cp -r zammad-4.0.0-err/.travis.yml zammad/
cp -r zammad-4.0.0-err/.viminfo zammad/
chown -R zammad:zammad zammad

maybe before installing new vm, try to make proper backups, try the apt reinstall. (maybe with purge…)

Also take a look in your DB, if there are no Delayed-jobs anymore. After you’ve made a backup of the DB, empty out the table delayed jobs. Start zammad again.

Did you tried an zammad run rails r 'Cache.clear' (apt) or su zammad -> rails r "Cache.clear" (sources)

1 Like

This morning, I prepared a new fresh VM on Ubuntu 20.04 and installed zammad on it.
All is working as systemctl -xe says.

But when I apply the default zammad.conf on apache2, the Zammad-web service is crashing !

May 13 09:40:24 mgc-srv-1 systemd[1]: zammad-web-1.service: Main process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- An ExecStart= process belonging to unit zammad-web-1.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 1.
May 13 09:40:24 mgc-srv-1 systemd[1]: zammad-web-1.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- The unit zammad-web-1.service has entered the 'failed' state with result 'exit-code'.
May 13 09:40:24 mgc-srv-1 sshd[92514]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=36.129.3.143  user=root

I customeized this apache conf and now I get this :

root@mgc-srv-1:~# journalctl -xe
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/rack-2.2.3/lib/rack/server.rb:422:in `wrapped_app'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/rack-2.2.3/lib/rack/server.rb:312:in `block in start'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/rack-2.2.3/lib/rack/server.rb:379:in `handle_profiling'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/rack-2.2.3/lib/rack/server.rb:311:in `start'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/commands/server/server_command.rb:39:in `sta>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/commands/server/server_command.rb:147:in `bl>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/commands/server/server_command.rb:138:in `ta>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/commands/server/server_command.rb:138:in `pe>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/command.rb:27:in `run'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor/invocation.rb:127:in `invoke_command'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/thor-1.2.1/lib/thor.rb:392:in `dispatch'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/command/base.rb:69:in `perform'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/command.rb:46:in `invoke'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/railties-6.0.4.8/lib/rails/commands.rb:18:in `<main>'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.11.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from script/rails:8:in `<top (required)>'
May 13 13:27:48 mgc-srv-1 systemd[1]: zammad-web-1.service: Main process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- An ExecStart= process belonging to unit zammad-web-1.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 1.
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli/exec.rb:58:in `load'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli/exec.rb:58:in `kernel_load'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli/exec.rb:23:in `run'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli.rb:479:in `exec'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `i>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/vendor/thor/lib/thor.rb:392:in `dispatch'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli.rb:31:in `dispatch'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/vendor/thor/lib/thor/base.rb:485:in `start'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/cli.rb:25:in `start'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/exe/bundle:49:in `block in <top (required)>'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/lib/bundler/friendly_errors.rb:103:in `with_friendly_err>May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/vendor/bundle/ruby/2.7.0/gems/bundler-2.2.33/exe/bundle:37:in `<top (required)>'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/bin/bundle:121:in `load'
May 13 13:27:48 mgc-srv-1 zammad-web-1.service[18940]:         from /opt/zammad/bin/bundle:121:in `<main>'
May 13 13:27:48 mgc-srv-1 systemd[1]: zammad-web-1.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- The unit zammad-web-1.service has entered the 'failed' state with result 'exit-code'.

So,

After a lot of try, here is the solutions :slight_smile: :

  1. apt install apache2 mysql mysql-server certbot elasticsearch python-mysql2
  2. copy database from old server
  3. apt install zammad
  4. modify database.yml with mysql2 (instead of )
  5. apt reinstall zammad

it’s ok.

Great that you found a solution!

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