2

suboptimal pack - out of memoryリポジトリをgitにプッシュすると、警告が表示されます。

Counting objects: 103, done.
Delta compression using up to 2 threads.
warning: suboptimal pack - out of memory
Compressing objects: 100% (100/100), done.
...

ご覧のとおり、リポジトリは最終的に圧縮され、その後、システムはリポジトリを正常にプッシュします。したがって、最適ではありませんが、問題ないように見えます。私の質問は、リポジトリに潜在的な損傷があるのか​​、それとも少し大きいのかということです。

これはかなり大きなリポジトリであるため、おそらくこのエラーが発生しますが、ファイルが破損していない限り、問題はありません。

4

1 に答える 1

3

いいえ。リポジトリは破損していません。gitが特定のblobのデルタインデックスを生成しようとしてメモリを使い果たした場合、警告がスローされます。これだけでは、リポジトリに害を与えたり、プッシュプロセスをクラッシュさせたりするのに十分ではありません(これが、5年以上前にエラーから警告に変更された理由です...):

commit a588d88aaff312f3afd5713ffcb4e4b1829fb5a6
Author: Martin Koegler <mkoegler@auto.tuwien.ac.at>
Date:   Mon May 28 23:20:57 2007 +0200

    builtin-pack-objects: don't fail, if delta is not possible

    If builtin-pack-objects runs out of memory while finding
    the best deltas, it bails out with an error.

    If the delta index creation fails (because there is not enough memory),
    we can downgrade the error message to a warning and continue with the
    next object.

    Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at>
    Signed-off-by: Junio C Hamano <junkio@cox.net>

解決策と回避策は、この回答とこの回答に記載されています。

于 2012-08-20T12:05:00.017 に答える