docker-archive / docker-registry

This is **DEPRECATED**! Please go to https://github.com/docker/distribution
Apache License 2.0
2.89k stars 877 forks source link

push a same image to the registry:2.0 and registry:0.9 ,the registry:2.0's growing size is more bigger than registry:0.9 #1021

Open liuwanzhi opened 9 years ago

liuwanzhi commented 9 years ago
we pulled two images from registry0.9, imageA and imageB , imageA is imageB's base image

1 run registry2.0 container docker run -d --privileged=true --net=host --name registry-2 -e SETTINGS_FLAVOR=local -e REGISTRY_HOST=localhost -e REGISTRY_PORT=5000 registry:2.0

2 firstly, wo commit the empty rigisty2.0 and see the virtual size is 548.6 MB (1)docker commit registry2.0-containerID registry2.0 localhost:5000/registry 2.0 ec94325cd2c4 4 weeks ago 548.6 MB (2) then push imageA ,and commit and see the virtual size is 1.039G docker push localhost:5000/imageA docker commit registry2.0-containerID registry2.0 the grow size is 491M (3) push imageB , commit and see th virtual size is 1.119 GB the grow size is 70M

3 then I run registy0.9 container and do the same thing (1) when the registry is empty, we commit and see the virtual size is 413.8 MB (2) after pushed imageA, commit and see the virtaul size is 903.5 MB, the grow size is 389.7M , the grow size is as same as regisry2.0 growed (3)but when I pushed imageB , commit and see th virtual size is 920.6 MB the grow size only 17M

so why imageB's grow size in registry2.0 is bigger than in registry0.9 ?

tonton1728 commented 8 years ago

Hello, I'm facing the issue while migrating old registry to new registry v2 Is it some normal behaviour or do I miss something ? Thanks for the answer

Gilles