Tengo un repositorio git que reside en un servidor con memoria limitada. Cuando intento de clonar un repositorio existente desde el servidor me sale el siguiente errorEl reposicionamiento del repositorio Git falla
[email protected]:$ git clone ssh://[email protected]/home/hemi/repos/articles
Initialized empty Git repository in /home/hemi/Skrivebord/articles/.git/
[email protected]'s password:
remote: Counting objects: 666, done.
remote: warning: suboptimal pack - out of memory
remote: fatal: Out of memory, malloc failed
error: git upload-pack: git-pack-objects died with error.
fatal: git upload-pack: aborting due to possible repository corruption on the remote side.
remote: aborting due to possible repository corruption on the remote side.
fatal: early EOF
fatal: index-pack failed
[email protected]:$
Para controlar este error he intentado volver a embalar el repositorio inicial (según this forum post). Pero en lugar de volver a empaquetar el repositorio, describe cómo usar el comando "git pack-objects".
[email protected]:~/repos/articles$ git repack -a -d --window-memory 10m --max-pack-size 100m
usage: git pack-objects [{ -q | --progress | --all-progress }]
[--all-progress-implied]
[--max-pack-size=N] [--local] [--incremental]
[--window=N] [--window-memory=N] [--depth=N]
[--no-reuse-delta] [--no-reuse-object] [--delta-base-offset]
[--threads=N] [--non-empty] [--revs [--unpacked | --all]*]
[--reflog] [--stdout | base-name] [--include-tag]
[--keep-unreachable | --unpack-unreachable
[<ref-list | <object-list]
Git 1.6.5.7 está instalado en el servidor.
Gracias por las opciones de configuración, no era consciente de ellos antes. El repositorio contiene un gran conjunto de archivos pdf. El tamaño total del repositorio (incluidos el directorio .git y los archivos rastreados) es aproximadamente 1.1 GB. Así que supongo que es un gran repositorio ;-) – midtiby
@MarkLongair: ¡salvaste mi día, señor! Estaba a punto de ir a la tienda y comprar algo de actualización de RAM: D –
@MarkLongair: ¡¡¡Gran respuesta !!! Gracias por tal información útil. – nish