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
  • #3077

Closed
Open
Created Feb 23, 2013 by Administrator@rootOwner

problem with restore (undefined method `path_to_repo' for nil:NilClass)

Created by: YenZi

I have a running version 4.1 on one server. Now I set up gitlab version 4.1 on another server and wanted to restore a backup done on the 1st server. However, it fails with this error :

projects ... done
schema_migrations ... done
users_projects ... done
merge_requests ... done
Restoring repositories ... 
project/project1 ... [DONE]
project/project2 ... rake aborted!
undefined method `path_to_repo' for nil:NilClass
/home/gitlab/gitlab/lib/tasks/gitlab/backup.rake:161:in `block (5 levels) in <top (required)>'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/relation/batches.rb:21:in `block (2 levels) in find_each'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/relation/batches.rb:21:in `each'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/relation/batches.rb:21:in `block in find_each'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/relation/batches.rb:72:in `find_in_batches'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/relation/batches.rb:20:in `find_each'
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.11/lib/active_record/querying.rb:8:in `find_each'
/home/gitlab/gitlab/lib/tasks/gitlab/backup.rake:151:in `block (4 levels) in <top (required)>'
/home/gitlab/gitlab/lib/tasks/gitlab/backup.rake:101:in `block (3 levels) in <top (required)>'
Tasks: TOP => gitlab:backup:repo:restore
(See full trace by running task with --trace)

What's interesting is this: As you can see above, it did restore project/project1. But only because I manually created that directory with following user/group and access rights :

drwsrws--- 7 git git 4096 2013-02-23 13:08 /home/git/repositories/project/project1.git

Before that manual mkdir it the restore already failed on project1. So, I would expect from a restore that it will actually restore a repository if not found in the filesystem, right ?

Assignee
Assign to
Time tracking