wagoodman / dive

A tool for exploring each layer in a docker image
MIT License
44.64k stars 1.69k forks source link

Image analysis fails after "building cache" and only prints "killed" #389

Open HanschDennis opened 2 years ago

HanschDennis commented 2 years ago

Hi, I'm not able to analyze a pretty big image (~30GB). The output is: Image Source: docker://myImage
Fetching image... (this can take a while for large images)
Analyzing image...
Building cache...
Killed

Is there an option to get more details why it fails? I have enough disk space, I think that should't be a problem. Thank you.

dsajanice commented 2 years ago

+1

mark2185 commented 2 years ago

Is it a public image, so it can be reproduced?

HanschDennis commented 2 years ago

@mark2185 No, unfortunately not. I also have not tried to reproduce it with another image.

mark2185 commented 2 years ago

Is yours a public image, so it can be reproduced?

How much RAM does your machine have?

emacdona commented 1 year ago

I encountered this error today. ~45 GB image, unfortunately not public :-(

My machine has 64 GB of memory, and after reading your question regarding memory, I brought up Resource Monitor (I'm running docker in WSL2 on Windows 10) -- and watched it chew through all remaining memory.

Some context: this image contains an entire development environment with lots of tools installed. Its built using one big Dockerfile -- with a bunch of sequential "RUN"s. I wanted to use dive so I could see what each layer (RUN command) adds... in hopes that I could find a common base to be refactored into a multi stage build.

Which leads me to my question...

I suspect that finding a way to use less memory will be hard (if not impossible). In leiu of that, would you consider a feature that let one specify the "Last n layers" to be analyzed by dive? That would help my use case, at least :-)

I could optimize my HUGE docker image, say, 10 layers at a time.

Thanks for making dive!

IssacKramer commented 5 months ago

I encountered this error today. ~45 GB image, unfortunately not public :-(

My machine has 64 GB of memory, and after reading your question regarding memory, I brought up Resource Monitor (I'm running docker in WSL2 on Windows 10) -- and watched it chew through all remaining memory.

Some context: this image contains an entire development environment with lots of tools installed. Its built using one big Dockerfile -- with a bunch of sequential "RUN"s. I wanted to use dive so I could see what each layer (RUN command) adds... in hopes that I could find a common base to be refactored into a multi stage build.

Which leads me to my question...

I suspect that finding a way to use less memory will be hard (if not impossible). In leiu of that, would you consider a feature that let one specify the "Last n layers" to be analyzed by dive? That would help my use case, at least :-)

I could optimize my HUGE docker image, say, 10 layers at a time.

Thanks for making dive!

+1 same here. Cannot analyze image based on windows Server Core (5G) - telling me : " path error at layer index Index(0-47:48): unable to add ......" So maybe a feature to analyze only X top numbers of layers (I won't optimize microsoft layers.....) Thx.