CKS Lab Challange 4 - Can't install Falco due to key issues

The Lab challenge referred can be accessed at

https://kodekloud.com/topic/lab-challenge-4/

The sources.list.d has this content which is an issue as the version of linux is bionic and not xenial as expected in below file. Changing it to bionic in kubernetes.list does not help either

root@controlplane ~ ➜  cat /etc/apt/sources.list.d/kubernetes.list
deb [signed-by=/usr/share/keyrings/kubernetes-archive-keyring.gpg] https://apt.kubernetes.io/ kubernetes-xenial main

apt update -y gives this below error

Please note that I have give space between https and :// in link as the post in this forum allows only two links so to workaround that I have given the space after copying and pasting the error from terminal in lab

Fetched 20.2 MB in 5s (3,963 kB/s)
Reading package lists… Done
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
N: Skipping acquire of configured file ‘main/binary-i386/Packages’ as repository ‘https ://download.falco.org/packages/deb stable InRelease’ doesn’t support architecture ‘i386’
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: Index of /apt// kubernetes-xenial InRelease: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY B53DC80D13EDEF05
W: Failed to fetch https://apt.kubernetes.io/dists/kubernetes-xenial/InRelease The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY B53DC80D13EDEF05
W: Some index files failed to download. They have been ignored, or old ones used instead.
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list.d/falcosecurity.list:1 and /etc/apt/sources.list.d/falcosecurity.list:2

I get below error when I remove the duplicate in /etc/apt/sources.list.d/falcosecurity.list

Hit:2 https ://download.docker.com/linux/ubuntu bionic InRelease
Hit:3 http ://archive.ubuntu.com/ubuntu bionic InRelease
Hit:4 http ://security.ubuntu.com/ubuntu bionic-security InRelease
Hit:5 https ://download.falco.org/packages/deb stable InRelease
Hit:6 http ://archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:7 http ://archive.ubuntu.com/ubuntu bionic-backports InRelease
Get:1 https ://packages.cloud.google.com/apt kubernetes-xenial InRelease [8,993 B]
Err:1 https ://packages.cloud.google.com/apt kubernetes-xenial InRelease
The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY B53DC80D13EDEF05
Fetched 8,993 B in 1s (12.0 kB/s)
Reading package lists… Done
N: Skipping acquire of configured file ‘main/binary-i386/Packages’ as repository ‘https ://download.falco.org/packages/deb stable InRelease’ doesn’t support architecture ‘i386’
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https ://packages.cloud.google.com/apt kubernetes-xenial InRelease: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY B53DC80D13EDEF05
W: Failed to fetch https ://apt.kubernetes.io/dists/kubernetes-xenial/InRelease The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY B53DC80D13EDEF05
W: Some index files failed to download. They have been ignored, or old ones used instead.

Install falco like this

# Set up the apt repo for Falco
curl -s https://falco.org/repo/falcosecurity-3672BA8F.asc | apt-key add -
echo "deb https://download.falco.org/packages/deb stable main" | tee -a /etc/apt/sources.list.d/falcosecurity.list

# Update apt indexes
apt-get update -y

# Install prerequiste and falco
apt-get -y install linux-headers-$(uname -r) falco
1 Like

That worked, thanks.

How do we get the list of repos available like the suffix “-3672BA8F.asc”?

We don’t.

The current version of Falco doesn’t work in this lab. When the lab was created, falco 0.31.0 was current and the above repo and key selects that. I have asked the lab team to update the lab, but so far they have not.

1 Like

Thanks for timely response as it saves lot of wasted time for me

I already spent many hours trying to troubleshoot