Re: Any tips for improving the performance of cloning large repositories?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 16 December 2011 17:08, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Alex Bennee <kernel-hacker@xxxxxxxxxx> writes:
>
>> Well that's counter intuitive....
>>
>>  - reverting the original repo to one big pack speeds up the clone
>>  - adding a --local --reference mirror slows it down
>
> Neither is. Read what "--local" says in the help text of clone. It
> disables the git aware clever optimization.

OK that's not how I read the man page:

       --local, -l
           When the repository to clone from is on a local machine,
this flag bypasses the normal "git aware" transport
           mechanism and clones the repository by making a copy of
HEAD and everything under objects and refs directories.

So this says it skips "git aware" (whatever that means)

           The files under .git/objects/ directory are hardlinked to
save space when possible. This is now the default when
           the source repository is specified with /path/to/repo
syntax, so it essentially is a no-op option. To force
           copying instead of hardlinking (which may be desirable if
you are trying to make a back-up of your repository),
           but still avoid the usual "git aware" transport mechanism,
--no-hardlinks can be used.

And this says that objects on the local file-system are hardlinked
(rather than copied) which I assumed was a optimal approach.

       --no-hardlinks
           Optimize the cloning process from a repository on a local
filesystem by copying files under .git/objects
           directory.

I'm not sure how this is an optimization? This means more copying
rather than linking right?

-- 
Alex, homepage: http://www.bennee.com/~alex/
http://www.half-llama.co.uk
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]