[DRE-maint] Bug#894272: gitlab: Problem migrating database from old installation

David López Zajara (Er_Maqui) er_maqui at darkbolt.net
Wed Mar 28 12:39:19 UTC 2018


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Hi praveen,

I've deleted the binary specified. Now installation are completed.

Installation give me a error checking gitlab API. There is it:


Running /usr/share/gitlab-shell/bin/check
Check GitLab API access: FAILED. code: 401
gitlab-shell self-check failed
  Try fixing it:
  Make sure GitLab is running;
  Check the gitlab-shell configuration file:
  sudo -u gitlab -H editor /usr/share/gitlab-shell/config.yml
  Please fix the error above and rerun the checks.

Checking GitLab Shell ... Finished


On gitlab-shell.log, I can see this:

W, [2018-03-28T14:31:28.741930 #3712]  WARN -- : Failed to connect to
internal API <GET http://localhost:8080/api/v4/internal/check>:
#<Errno::ECONNREFUSED: Failed to open TCP connection to localhost:8080
(Connection refused - connect(2) for "localhost" port 8080)>
I, [2018-03-28T14:31:28.742069 #3712]  INFO -- : GET
http://localhost:8080/api/v4/internal/check 0.00064

Starting gitlab process, I got another error message on log (but same
message on installation check)

I, [2018-03-28T14:33:41.122894 #4023]  INFO -- : GET
http://localhost:8080/api/v4/internal/check 0.00060
I, [2018-03-28T14:35:20.820469 #4425]  INFO -- : GET
http://localhost:8080/api/v4/internal/check 0.15840
E, [2018-03-28T14:35:20.828084 #4425] ERROR -- : API call <GET
http://localhost:8080/api/v4/internal/check> failed: 401 =>
<{"message":"401 Unauthorized"}>.


I have only one question more. I think, this problem can appears on a
migration from 8.13 to 10.5.

The setup are as follows:

I've installed gitlab 10.5.6 clean (with a uninstall and purge).
I've restored the old database, ssh keys, uploads and repositories folder
(following your guide on
https://salsa.debian.org/ruby-team/gitlab/blob/master/debian/README.Debian).
I've do all aditional steps (fixes, migration, etc).


On installation check (step 13 of the guide) I get these errors:


Checking GitLab Shell ...

GitLab Shell version >= 6.0.3 ? ... OK (6.0.4)

Running /usr/share/gitlab-shell/bin/check
Check GitLab API access: FAILED: Failed to connect to internal API
gitlab-shell self-check failed
  Try fixing it:
  Make sure GitLab is running;
  Check the gitlab-shell configuration file:
  sudo -u gitlab -H editor /usr/share/gitlab-shell/config.yml
  Please fix the error above and rerun the checks.

Checking GitLab Shell ... Finished

Checking Sidekiq ...

Running? ... no
  Try fixing it:
  sudo -u gitlab -H RAILS_ENV=production bin/background_jobs start
  For more information see:
  doc/install/installation.md in section "Install Init Script"
  see log/sidekiq.log for possible errors
  Please fix the error above and rerun the checks.

Checking Sidekiq ... Finished


First one (gitlab-shell) are the same received finishing installation. I
didn't modified any gitlab config yet, and gitlab-shell/config appears to
be ok.
Second one (sidekiq) are resolved running the specified command line order
(bin/background_jobs start).

Now, Gitlab web returns a 500 internal server error. On log file
(/var/log/gitlab/production.log), I find this error:


Started GET "/users/sign_in" for x.x.x.x at 2018-03-28 14:02:34 +0200
Processing by SessionsController#new as HTML
Completed 500 Internal Server Error in 408ms (ActiveRecord: 9.0ms)

ActionView::Template::Error (uninitialized constant Redcarpet::Renderer):
    17:                 = brand_title
    18:               = brand_image
    19:               - if brand_item&.description?
    20:                 = brand_text
    21:               - else
    22:                 %h3 Open source software to collaborate on code
    23:
  lib/banzai/filter/markdown_filter.rb:29:in `renderer'
  lib/banzai/filter/markdown_filter.rb:22:in `call'
  lib/banzai/pipeline/base_pipeline.rb:21:in `block (2 levels) in singleton
class'
  lib/banzai/renderer.rb:108:in `render_result'
  lib/banzai/renderer.rb:139:in `block in cacheless_render'
  lib/gitlab/metrics/influx_db.rb:98:in `measure'
  lib/banzai/renderer.rb:138:in `cacheless_render'
  lib/banzai/renderer.rb:50:in `cacheless_render_field'
  app/models/concerns/cache_markdown_field.rb:69:in `block in
refresh_markdown_cache'
  app/models/concerns/cache_markdown_field.rb:66:in `map'
  app/models/concerns/cache_markdown_field.rb:66:in `refresh_markdown_cache'
  app/models/concerns/cache_markdown_field.rb:78:in
`refresh_markdown_cache!'
  lib/banzai/renderer.rb:40:in `render_field'
  lib/banzai.rb:7:in `render_field'
  app/helpers/markup_helper.rb:102:in `markdown_field'
  app/helpers/appearances_helper.rb:11:in `brand_text'
  app/views/layouts/devise.html.haml:20:in
`_app_views_layouts_devise_html_haml___3277498639612331446_4337444095880'
  app/controllers/sessions_controller.rb:21:in `new'
  lib/gitlab/i18n.rb:47:in `with_locale'
  lib/gitlab/i18n.rb:53:in `with_user_locale'
  app/controllers/application_controller.rb:325:in `set_locale'
  lib/gitlab/middleware/multipart.rb:95:in `call'
  lib/gitlab/request_profiler/middleware.rb:14:in `call'
  lib/gitlab/middleware/go.rb:17:in `call'
  lib/gitlab/etag_caching/middleware.rb:11:in `call'
  lib/gitlab/middleware/read_only.rb:31:in `call'
  lib/gitlab/request_context.rb:18:in `call'
  lib/gitlab/metrics/requests_rack_middleware.rb:27:in `call'


Redirection from / to /users/sign_in works ok. But I cannot see the page.
Before restoring database, these error didn't appear. Maybe is a problem
migrating database.


Really thanks for your help about this.
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEYf0F71OtDykDsKZdCU2zE9sy6H8FAlq7jKEACgkQCU2zE9sy
6H+QAQ//ZqF68dJNJogGcPwx0Qv1D+8IYgnrRK/sOnkgjKfUKsgwMls5iu2HHq48
6aPtGpJBaAAn0EWpB2TlB4/WVz7UzR+uNc0A6hZQgOPP6hbl+5FI/VCS0MQOPnsp
5biTYqdCQOdOcaLOtgcr13SEeZfTNFrdd21pUwDbPA7+RCXYxHTE0cdF1ueGdRA1
mHGWKHGQHV/DSZVeWvy2FgcM5p+1pU74IfVyUJi7XNmIO0LaB+5GtNkukcCj6uzS
MaOIUwCFDdKq7TdUAO7ezPwkLkQ2xhlflrXDzf1eixp3zmdgVIcDyblKEOXaMjGg
usb6Py3nS9MuBo3nPUqCoWDmcSi7VrUtSZpEGJgmTne6zGKYxXoTudb59Bh2hqZZ
tJoM9lmWVSRrZUWRBitENADMseshptj+QlphP5rK7X5RdPlzzeOXzBK0LDbr1fdC
jC0k/BosOD/rSHFiBwOBCdaJBgv1lo6OswM6FObvlh7spHogrOtVpqj6834Q3VJI
UgaUha8S/z+GUAIJ827z4pRQJIhqmsdzpj/H77vZuPnK210i8U/v0FiySwBWAUj9
aMDUVzEDCpVKKKhJenA/+DnW62k5amjgYFrAMLfamazf9pYJvLwTyTTYQs4S00fS
m0fzUDQpnkI7Q1x7Nu3UG233+R4ydo7kBwdhI4TguMpslNj4pgk=
=Y4i2
-----END PGP SIGNATURE-----


https://maqui.darkbolt.net/
Linux registered user ~#363219
PGP keys avaiables at KeyServ. ID: 0x4233E9F2
Los hombres somos esclavos de la historia
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-ruby-extras-maintainers/attachments/20180328/37b3dc84/attachment.html>


More information about the Pkg-ruby-extras-maintainers mailing list