Re: Large repo and pack.packsizelimit

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

 



Thomas <th.acker66@xxxxxxxx> writes:

> (1) all objects to be transferred to another repo 
> (2) all loose objects when starting a local repack
> Case (1) can be fixed by transfer.unpacklimit but there is no fix for (2).

Technically (1) is putting everything in a single pack to transfer, and it
is only the receiving end that does the chopping.

For (2), you could do something like

	keep=$( git rev-list --objects $some_rev |
	        git pack-objects --delta-base-offset pack ) &&
	mv pack-$keep.pack pack-$keep.idx .git/objects/pack/ &&
	echo "keep $some_rev" >.git/objects/pack/pack-$keep.keep

after finding a suitable $some_rev that is old enough so that it will be
an ancestor of anything that matters in the future and gives small enough
packfiles.  You may want to try doing the above multiple times, by picking
a few strategic ranges, e.g.

	for some_rev in v1.0 v1.0..v2.0 v2.0..v2.4 v2.4..v3.0
	do
		... the above four lines come here ...
	done

The objects stored in .keep packs won't participate in future repack so
your "git repack -a -d" after that will put everything that is needed only
for versions newer than v3.0 in a single new pack.
--
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]