Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I install / use tcpdump on minikube?

Tags:

minikube

I'm trying to investigate a network issue and would like to install tcpdump / tshark.

What package manager does minikube use? How can I install tcpdump?

like image 370
Chris Stryczynski Avatar asked Oct 17 '25 10:10

Chris Stryczynski


2 Answers

It is not an easy task.

Minikube VM is based on Buildroot distribution.

Usually minikube uses docker to build a buildroot image, but you can clone buildroot repo and configure it to include tcpdump package using specific targets (make iso-minikube, make iso-menuconfig).

Then you need to build a minikube image and run minikube using that image.
The manual is not full, but gives you the main idea of what to do.

Alternatively you may try to copy tcpdump and all its dependencies to minikube VM using scp.

like image 63
VASャ Avatar answered Oct 21 '25 09:10

VASャ


I would run a container with my favorite os and use host network then install tcpdump inside the container

minikube$docker run --network host -it ubuntu
ubuntu#apt update && apt install tcpdump
like image 45
mounir boukhalfa Avatar answered Oct 21 '25 10:10

mounir boukhalfa



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!