How to install Pi-hole on Kali linux 2021 using RaspberryPi

Hi, I'm trying to install PiHole but it is not detecting Netcat installed.

Netcat is already installed. The package is netcat-traditional 1.10-47 but anyway PiHole is trying to install it with an error "The package has no installation candidate".

What can I do?

Thanks.

Solved:

wget -O basic-install.sh https://install.pi-hole.net
nano basic-install.sh

Edit line 332:

-    PIHOLE_DEPS=(cron curl iputils-ping lsof netcat psmisc sudo unzip idn2 sqlite3 libcap2-bin dns-root-data libcap2)
+    PIHOLE_DEPS=(cron curl iputils-ping lsof netcat-traditional psmisc sudo unzip idn2 sqlite3 libcap2-bin dns-root-data libcap2)

Comment line 2544 with #:

-   os_check
+   #os_check

sudo bash basic-install.sh

Now is installed and working flawlessly.

What OS are you using?

I'm using Kali Linux 2021.3 ARM64 on my RaspberryPi 4B. It's working really well.

Regards.

Kali is not a supported OS, that's why you needed to make modifications

https://docs.pi-hole.net/main/prerequisites/

But the only modification is change netcat by netcat-traditional and it can be supported, so it's working well.

Only adding a condition that if netcat-traditional is present, so change the prerequisite.

Regards.

Not's not only the small change in the installation script. If we decide to support it, people will start asking for help to troubleshoot their installations. None of the developers or moderators is running Kali which makes it hard for us to provide the level of support users are expecting and we are usually able to give.

Thanks for figuring out how to install Pi-hole on Kali. Others running also Kali will benefit from this. To be even more helpful to others, you might move your topic to the "general" category and change the title to something like "How to install Pi-hole on Kali linux"

I need to check but I don't think we even need netcat anymore. It was used to do fallback tricorder uploads and that fallback was removed a release or two ago. It could potentially upload a debug log over unencrypted http and that wasn't a great option.

Edit:
Yeah Update debug for new back end. by dschaper · Pull Request #4263 · pi-hole/pi-hole · GitHub

Ok, now I understand.

I can't find where I can move this topic to general and change the title. You, as moderator, if you can do it, feel you free to do it.

On title, i would be a bit more specific and I would put it as "How to install Pi-hole on Kali linux 2021 using RaspberryPi" because this method is not tested by me using AMD64 architecture, only ARM64.

Thanks and regards.

This will remove netcat from install dependencies:


Done.

Thanks!

Just FYI - set environment variable PIHOLE_SKIP_OS_CHECK=true and it will skip that function without needing to modify the source...

            printf "\\n"
            printf "      %bhttps://docs.pi-hole.net/main/prerequesites/#supported-operating-systems%b\\n" "${COL_LIGHT_GREEN}" "${COL_NC}"
            printf "\\n"
            printf "      If you wish to attempt to continue anyway, you can try one of the following commands to skip this check:\\n"
            printf "\\n"
            printf "      e.g: If you are seeing this message on a fresh install, you can run:\\n"
            printf "             %bcurl -sSL https://install.pi-hole.net | PIHOLE_SKIP_OS_CHECK=true sudo -E bash%b\\n" "${COL_LIGHT_GREEN}" "${COL_NC}"
            printf "\\n"
            printf "           If you are seeing this message after having run pihole -up:\\n"
            printf "             %bPIHOLE_SKIP_OS_CHECK=true sudo -E pihole -r%b\\n" "${COL_LIGHT_GREEN}" "${COL_NC}"
            printf "           (In this case, your previous run of pihole -up will have already updated the local repository)\\n"
            printf "\\n"
            printf "      It is possible that the installation will still fail at this stage due to an unsupported configuration.\\n"
            printf "      If that is the case, you can feel free to ask the community on Discourse with the %bCommunity Help%b category:\\n" "${COL_LIGHT_RED}" "${COL_NC}"
            printf "      %bhttps://discourse.pi-hole.net/c/bugs-problems-issues/community-help/%b\\n" "${COL_LIGHT_GREEN}" "${COL_NC}"
            printf "\\n"