falco: falco failed to run in kind
What happened: falco failed to run in kind.
$ kubectl logs falco-1575678340-6fxr4
* Setting up /usr/src links from host
* Unloading falco-probe, if present
* Running dkms install for falco
Error! echo
Your kernel headers for kernel 4.9.184-linuxkit cannot be found at
/lib/modules/4.9.184-linuxkit/build or /lib/modules/4.9.184-linuxkit/source.
* Running dkms build failed, couldn't find /var/lib/dkms/falco/0.17.1/build/make.log
* Trying to load a system falco-probe, if present
* Trying to find precompiled falco-probe for 4.9.184-linuxkit
Found kernel config at /proc/config.gz
* Trying to download precompiled module from https://s3.amazonaws.com/download.draios.com/stable/sysdig-probe-binaries/falco-probe-0.17.1-x86_64-4.9.184-linuxkit-aa7fd392e72f1a4dcbe68e1d89467b54.ko
curl: (22) The requested URL returned error: 404 Not Found
Download failed, consider compiling your own falco-probe and loading it or getting in touch with the sysdig community
Sat Dec 7 00:26:13 2019: Falco initialized with configuration file /etc/falco/falco.yaml
Sat Dec 7 00:26:13 2019: Loading rules from file /etc/falco/falco_rules.yaml:
Sat Dec 7 00:26:14 2019: Loading rules from file /etc/falco/falco_rules.local.yaml:
Sat Dec 7 00:26:14 2019: Unable to load the driver. Exiting.
Sat Dec 7 00:26:14 2019: Runtime error: error opening device /host/dev/falco0. Make sure you have root credentials and that the falco-probe module is loaded.. Exiting.
What you expected to happen: falco DaemonSet is successfully running.
How to reproduce it (as minimally and precisely as possible):
$ helm install stable/falco --generate-name
# or
$ kubectl create deploy falco --image=falcosecurity/falco:0.17.1
Anything else we need to know?:
Environment:
- Falco version (use
falco --version): 0.17.1 - System info <!-- Falco has a built-in support command you can use “falco --support | jq .system_info” -->
- Cloud provider or hardware configuration: kind v0.6.1
- OS (e.g:
cat /etc/os-release): macOS Catalina 10.15.1 - Kernel (e.g.
uname -a): - Install tools (e.g. in kubernetes, rpm, deb, from source): kubernetes
- Others:
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 1
- Comments: 19 (17 by maintainers)
I have finally found the problem, below the steps to make it work.
1. Install the driver on the host machine
Clone the Falco project and checkout the tag corresponding to the same Falco version used within the helm chart (0.20.0 in my case), then:
2. Mount
/devon kind-control-plane To make the driver work, the host’s/devmust be accessible from within the container. To do that, kind requires the following:kind-config.yaml
Then create the cluster so:
3. DONE! You can now deploy Falco to kind’s cluster as usual. You should notice that the driver will automatically be loaded with modprobe:
@oke-py @markyjackson-taulia can you please take a look and let me know if that works for you too?
At last, it worked fine! Thank you so much. I used ubuntu-18.04 on EC2.
install go
install docker
re-login
set env-var
install kernel module
install kubectl & helm
install kind & create cluster
install & run falco
Hey @yashbhutwala as far as I know, Falco on Docker for Mac has a different kind of issue that’s related to linuxkit and @leodido is working on that. Feel free to open another issue in the falco repo and add more details.
Thanks @leogr for stepping up and helping with this.
I’ll call it solved 😃
/close
@oke-py here you find further details on how to install the kernel module using driverkit. Let me know!
Related to this, I think we want to get the manifests for newer kubernetes versions in the Falco repo.
Also @oke-py thanks for getting this done on the helm charts! 👇 https://github.com/helm/charts/pull/17339