Note that there are some explanatory texts on larger screens.

plurals
  1. POWhy is a cloned repo 10x larger than a fetched repo?
    text
    copied!<p>We have a remote repo that has exploded in size (1.4G to 14G). We are trying to work out why this repo has increased in size and fix the problem. </p> <p>In the process we have noticed a significant difference between git clone and git fetch.</p> <p>If we clone the repo, the cloned repo is also 14G. </p> <pre><code>git clone &lt;remote&gt; </code></pre> <p>If instead, we init and fetch from the remote, the local repo is back to the expected 1.4G.</p> <pre><code>git init git remote add origin &lt;remote&gt; git fetch </code></pre> <p>I think those two sets of commands should be similar if not the same.</p> <p>This indicates a significant difference between clone and fetch. How are these commands different?</p> <p>We are looking for ways of determining a fix for the remote. </p> <p>Note that the remote is on a github enterprise server, so we have limited access to the remote repo.</p> <hr> <p>Some additional statistics</p> <pre><code>$ git clone git@$REMOTE/main.git . Initialized empty Git repository in $HOME/cloned/.git/ remote: Counting objects: 439172, done. remote: Compressing objects: 100% (238472/238472), done. Receiving objects: 100% (439172/439172), 13.82 GiB | 19.92 MiB/s, done. remote: Total 439172 (delta 186192), reused 436323 (delta 183501) Resolving deltas: 100% (186192/186192), done. </code></pre> <hr> <pre><code>$ git fetch remote: Counting objects: 246663, done. remote: Compressing objects: 100% (80057/80057), done. remote: Total 246663 (delta 159364), reused 238800 (delta 153402) Receiving objects: 100% (246663/246663), 1.13 GiB | 12.25 MiB/s, done. Resolving deltas: 100% (159364/159364), done. </code></pre> <p>Those are some pretty different numbers.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload