Uploaded image for project: 'OpenVZ'
  1. OpenVZ
  2. OVZ-7152

ploop not compacting

    XMLWordPrintable

    Details

      Description

      >Description of problem:

      I encountered this fault on several distinct servers on several versions (all VZ7): When I create a CT and set the hdd to a large size (1-2TB) and fill it up aall is well. If I decrease the used space slowly and manually trigger a pcompact, the ploop-file gets reduced in space.

      if however, I delete lots of content inside the CT, dropping the used space from 1900GB (out of 2000GB avail) to 100 or less, pcompact will fail to deflate the ploop file, leaving it at 2tb in size.

      Doing things like decrease/ increase the virtual disk size did not help. Filling the container with a huge "Zero-File" and deleting it does not help either.
      The only thing that will reclaim space is to create a new virtual hdd and rsync the files over.

      >How reproducible & How TO reproduce

      1. Create CT with large hdd (>700gb), install VM and use it.
      2. Fill disk up. In my case I did it on several hosts on several versions (but all inside the OpenVZ7 versions) with Backups (several hundreds of thousands of files using hardlinks (backuppc)) as well as Bareos Volumes (huge single files in the hundreds of GBs).

      3.1. This works: Delete a fraction of the used content and run a pcompact. The sum of the deleted files will be reclaimed and the poop file on the host will shrink accordingly.

      3.2. This does not work: Delete a large portion of the used content and run pcompact. The sum of the delete files will not be reclaimed on the host. device-set size of the hdd will not make the ploop-file shrink.

      So far I encountered this problem during:
      - 2tb hdd, 1.8 tb used, reduced to 200gb
      - 800gb hdd, 750gb used, reduced to 100gb.
      - 1.5tb hdd, 1.2tb used, reduced to 400gb.

      >Actual results:

      pcompact runs for a while, shows no error. Ploop file size on host unchanged but way too large (200gb in real use, 1.8tb ploop file size)

      >Expected results:

      pcompact runs for a while, shows no error. Ploop file size on host reflects actual used size (+- a few gb).

      >Host OS:

      OpenVZ 7, several versions across 7 release.

      >Guest OS:

      Encountered in CTs running CentOS7.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              khorenko Konstantin Khorenko
              Reporter:
              creiss Christian Reiss
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: