Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G gitlabhq1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • gpt
  • large_projects
  • gitlabhq1
  • Issues
  • #6100

Closed
Open
Created Jan 20, 2014 by Administrator@rootOwner

Gitlab doesn't connect to redis over socket.

Created by: bebehei

I experience a problem, that Gitlab connects to the standard redis-server (redis://127.0.0.1:6379) and not to the unix-socket, specified in resque.yml. I followed the installation-instructions, but If I don't run redis over tcp, gitlab gives me a HTTP 500 Error all the time. The issue is quite similar to #4884 (closed).

I'm running on Arch Linux with Gitlab 6.4.

my resuqe.yml-file:

development: unix:/run/redis/redis.sock
test: unix:/run/redis/redis.sock
production: unix:/run/redis/redis.sock

The redis-socket is also available and readable (chmod 777):

[gitlab@bread:config[6-4-stable*]] 34$ ls -l /run/redis/redis.sock
srwxrwxrwx 1 redis redis 0 20. Jan 03:42 /run/redis/redis.sock

This is the log-entry in the logfile:

Redis::CannotConnectError (Error connecting to Redis on 127.0.0.1:6379 (ECONNREFUSED)):
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:278:in `rescue in establish_connection'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:273:in `establish_connection'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:69:in `connect'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:292:in `ensure_connected'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:179:in `block in process'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:258:in `logging'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:178:in `process'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:84:in `call'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:675:in `block in set'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:36:in `block in synchronize'
  /usr/lib/ruby/2.0.0/monitor.rb:211:in `mon_synchronize'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:36:in `synchronize'
  vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:671:in `set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/interface.rb:9:in `set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/ttl.rb:8:in `set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/marshalling.rb:5:in `block in set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/marshalling.rb:29:in `_marshal'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/marshalling.rb:5:in `set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/namespace.rb:5:in `block in set'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/namespace.rb:50:in `namespace'
  vendor/bundle/ruby/2.0.0/gems/redis-store-1.1.4/lib/redis/store/namespace.rb:5:in `set'
  vendor/bundle/ruby/2.0.0/gems/redis-rack-1.5.0/lib/rack/session/redis.rb:31:in `block in get_session'
  vendor/bundle/ruby/2.0.0/gems/redis-rack-1.5.0/lib/rack/session/redis.rb:55:in `with_lock'
  vendor/bundle/ruby/2.0.0/gems/redis-rack-1.5.0/lib/rack/session/redis.rb:28:in `get_session'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:266:in `load_session'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/session/abstract_store.rb:43:in `block in load_session'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/session/abstract_store.rb:51:in `stale_session_check!'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/session/abstract_store.rb:43:in `load_session'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:151:in `load!'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:147:in `load_for_write!'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:73:in `[]='
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/failure_app.rb:183:in `store_location!'
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/failure_app.rb:55:in `redirect'
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/failure_app.rb:37:in `respond'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/abstract_controller/base.rb:189:in `process_action'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/abstract_controller/base.rb:136:in `process'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_controller/metal.rb:195:in `dispatch'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_controller/metal/rack_delegation.rb:13:in `dispatch'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_controller/metal.rb:231:in `block in action'
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/failure_app.rb:20:in `call'
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/failure_app.rb:20:in `call'
  vendor/bundle/ruby/2.0.0/gems/devise-3.0.4/lib/devise/delegator.rb:5:in `call'
  vendor/bundle/ruby/2.0.0/gems/warden-1.2.3/lib/warden/manager.rb:130:in `call_failure_app'
  vendor/bundle/ruby/2.0.0/gems/warden-1.2.3/lib/warden/manager.rb:116:in `process_unauthenticated'
  vendor/bundle/ruby/2.0.0/gems/warden-1.2.3/lib/warden/manager.rb:47:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/etag.rb:23:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/conditionalget.rb:25:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/head.rb:11:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/params_parser.rb:27:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/flash.rb:241:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:225:in `context'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:220:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/cookies.rb:486:in `call'
  vendor/bundle/ruby/2.0.0/gems/activerecord-4.0.2/lib/active_record/query_cache.rb:36:in `call'
  vendor/bundle/ruby/2.0.0/gems/activerecord-4.0.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:626:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
  vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/callbacks.rb:373:in `_run__1519473101458218037__call__callbacks'
  vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/callbacks.rb:80:in `run_callbacks'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/remote_ip.rb:76:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/rack/logger.rb:38:in `call_app'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/rack/logger.rb:20:in `block in call'
  vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/tagged_logging.rb:67:in `block in tagged'
  vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/tagged_logging.rb:25:in `tagged'
  vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/tagged_logging.rb:67:in `tagged'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/rack/logger.rb:20:in `call'
  vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.2/lib/action_dispatch/middleware/request_id.rb:21:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/methodoverride.rb:21:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/runtime.rb:17:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/lock.rb:17:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/sendfile.rb:112:in `call'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/engine.rb:511:in `call'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/application.rb:97:in `call'
  vendor/bundle/ruby/2.0.0/gems/railties-4.0.2/lib/rails/railtie/configurable.rb:30:in `method_missing'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/builder.rb:138:in `call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:65:in `block in call'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `each'
  vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `call'
  vendor/bundle/ruby/2.0.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:552:in `process_client'
  vendor/bundle/ruby/2.0.0/gems/unicorn-worker-killer-0.4.2/lib/unicorn/worker_killer.rb:51:in `process_client'
  vendor/bundle/ruby/2.0.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:632:in `worker_loop'
  vendor/bundle/ruby/2.0.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:500:in `spawn_missing_workers'
  vendor/bundle/ruby/2.0.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:142:in `start'
  vendor/bundle/ruby/2.0.0/gems/unicorn-4.6.3/bin/unicorn_rails:209:in `<top (required)>'
  vendor/bundle/ruby/2.0.0/bin/unicorn_rails:23:in `load'
  vendor/bundle/ruby/2.0.0/bin/unicorn_rails:23:in `<main>'

So, although I defined in resque.yml the right sockets, GitLab wants to connect to the redis-server on localhost and the standard-port. just ask

I can't trace the problem back to the starting-point, cause I don't have any ruby skills. Sorry for that.

If you need further information, because I forgot it, please ask.

Assignee
Assign to
Time tracking