Please describe the problem.
git annex merge
goes out of memory on a large repo.
What steps will reproduce the problem?
$ git annex merge
merge git-annex git-annex: out of memory (requested 1048576 bytes)
What version of git-annex are you using? On what operating system?
git-annex version: 4.20130827
build flags: Assistant Webapp Pairing Testsuite S3 WebDAV Inotify DBus XMPP DNS
On debian wheezy i386
Please provide any additional information below.
The repository contains a lot of files:
$ cd .git/objects
$ find . -type f | wc -l
1091548
The pre-commit hook of git annex throws an 'out of memory' error, too.
As a workaround, I've deleted ~/.git/hooks/pre-commit, and use
git merge
manually.Can you run this so I can get a better idea of the size of this repository:
git ls-tree -r git-annex | wc -l
I just fixed a memory leak that occurred when large files were checked directly into git (perhaps by accident by committing files manually when using direct mode). However, I don't think it affected
git annex merge
.Still need information about how to reproduce this bug...
That doesn't look very big, I merge one 3x that large on a 128 mb machine.
I think you will need to either email me privately so I can get a copy of your repository to investigate with ... or you can try to investigate on your own.
I think the first things I would try to debug this are to look over
git annex merge --debug
and see if I see anything unusual, and then I would probablygit checkout git-annex
in the repository, and wc -l on all the files and see if any file has a lot of lines, or is otherwise very large.If that found nothing, my next step would be to rebuild git-annex from source with memory profiling enabled, as explained in this book, and try to get a memory profiling graph that explained what was using up the memory. http://book.realworldhaskell.org/read/profiling-and-optimization.html