diff options
author | irina <irinagomez@us.es> | 2017-11-16 11:51:29 +0000 |
---|---|---|
committer | irina <irinagomez@us.es> | 2017-11-16 11:51:29 +0000 |
commit | f2696594bf06cb117673e916bcc93a31cd038e97 (patch) | |
tree | 8b6c5e778c5162aa6f1f56b87ce90c2d518f7d7f /client/engine/Image.lib | |
parent | 8ff4bd513a21c2f56d425e79214b94e074b0c763 (diff) |
#815 #770 Se resuelve errata por la que calculaba el espacio necesario para las sincronizadas como si fueran monolĂticas
git-svn-id: https://opengnsys.es/svn/branches/version1.1@5511 a21b9725-9963-47de-94b9-378ad31fedc9
Diffstat (limited to 'client/engine/Image.lib')
-rwxr-xr-x | client/engine/Image.lib | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/client/engine/Image.lib b/client/engine/Image.lib index b160c350..e1f1f9cf 100755 --- a/client/engine/Image.lib +++ b/client/engine/Image.lib @@ -474,7 +474,9 @@ dd if="$DISK" of="$IMGFILE" bs=446 count=1 || ogRaiseError $OG_ERR_IMAGE "$1 $IM #*/ ## function ogGetSizeParameters () { -local MNTDIR SIZEDATA KERNELVERSION SIZEREQUIRED FACTORGZIP FACTORLZOP SIZEFREE +local REPO MNTDIR SIZEDATA KERNELVERSION SIZEREQUIRED FACTORGZIP FACTORLZOP FACTORSYNC SIZEFREE +local IMGTYPE IMGDIR IMGFILE IMGEXT IMGSIZE + # Si se solicita, mostrar ayuda. if [ "$*" == "help" ]; then ogHelp "$FUNCNAME" "$FUNCNAME num_disk num_part str_repo str_imgname [monolit|sync|diff]" \ @@ -496,7 +498,7 @@ if [ "$MNTDIR" == "" ]; then fi # Datos contenidos en la particion o en la lista de archivos de contiene la diferencial. -if [ "_${4^^}_" == "_DIFF_" ]; then +if [ "$IMGTYPE" == "_DIFF_" ]; then [ -r /tmp/ogimg.info ] || return $(ogRaiseError session $OG_ERR_NOTFOUND "/tmp/ogimg.info"; echo $?) cd $MNTDIR SIZEDATA=$(grep -v "\/$" /tmp/ogimg.info | tr '\n' '\0'| du -x -c --files0-from=- 2>/dev/null|tail -n1 |cut -f1) @@ -505,7 +507,7 @@ else fi #Aplicar factor de compresion -if [ "_$IMGTYPE_" == "_SYNC_" -o "_$IMGTYPE_" == "_DIFF_" ]; then +if [ "$IMGTYPE" == "_SYNC_" -o "$IMGTYPE" == "_DIFF_" ]; then # Sistema de fichero de la imagen segĂșn kernel, menor que 3.7 EXT4. comparamos revision KERNELVERSION=$(uname -r| awk '{printf("%d",$1);sub(/[0-9]*\./,"",$1);printf(".%02d",$1)}') |