dodopizza/kubectl-shovel

Feature request: store dump on host machine

m00lecule opened this issue · 3 comments

Hello,

Currently I am exploring your kubectl plugin but faced weird issues when making big gcdump.

$ kubectl shovel dump --pod-name XXXX -n YYYY  -o ./dump.dump
Spawning diagnostics job
Waiting for a job to start
Looking for and mapping container fs
Running command: dotnet-dump collect --process-id 1 --type Full
Gathering completed
Getting results from job
Error: Error while getting results: unexpected EOF

Its probably related with the dump size - ~2.7 GB's that is not efficient to copy it using kubectl cp.

du

pod logs:
eof

I would like to request an additional feature - in which scenario the dump would be stored on host machine - for example /tmp. Later on I could copy it outside machine using aws s3 cp or to other storage.

Hi! We also facing sometimes with this behavior.
Feature to leave dump on host machine will be implemented soon

Hi @m00lecule !
Requested feature available with this beta version
Now, you can add flag --store-output-on-host (or -t shortcut) to commands.
With this option, output will be stored in /tmp/kubectl-shovel folder of k8s node

Feature available since 0.6.0 release. Can be installed with krew plugin manager.
Also, with additional flag --output-host-path default location (/tmp/kubectl-shovel) can be changed.
This issue can be closed now. Feel free to reopen or create a new one, if any bugs discovered