Cara Install Pi-Hole di Ubuntu



PiHole is an open source project for Raspberry Pi that acts as a DNS server to block known advertising domains. More information on the project can be found here. Pi-Hole can also run on x86 Linux Servers, and is fairly simple to set up.
  • Step 1) 

Install PiHole on your already existing Linux Server. I did not have one, so I chose Ubuntu 14.04 LTS for my server. After dropping at the root prompt, type the following:
Text
curl -L install.pi-hole.net | bash
After downloading, the bash script will begin to run, and install Pi-Hole.


  • Step 2) 

Pi-Hole will walk you through a very easy install process of selecting your upstream DNS servers and configuring your IP addresses statically - I chose 172.16.0.251 as mine.

  • Step 3) 

We now need to ensure DNSMasq and Lighttpd are running on their respective ports, 53 and 80. Type the following:



netstat -anlp | grep -w LISTEN

This should echo a number of responses, but the ones we are looking for are



tcp 0 0 172.16.0.251:53 LISTEN 4489/dnsmasq
tcp 0 0 172.16.0.251:80 LISTEN 7711/lighttpd

If you do not see these, then you can run the following commands for more information



sudo service dnsmasq status
sudo service lighttpd status

If no errors or information is returned, then you can start the services manually with 



sudo service dnsmasq start

sudo service lighttpd start

  •  Step 3)
Verify DNS is working by assigning the IP of your server (172.16.0.251 in this case) to a computer on the network and running an nslookup. You can verify lighttpd status by attempting to access the administration console, which will be at <Ipserver/admin>, or http://172.16.0.251/admin in this case.
  • Step 4)
To begin blocking ads on your network once you have verified it is working, you can point your existing DNS servers to use this server for upstream. Further, you can set this server to be applied through DHCP as a default DNS server.

Enjoy!

1 komentar:

  1. say set ip raspberry 192.168.150.3 (colok pc via lan)
    tp saat dcolok ke mikrrotik
    didhcp server kedetek
    192.168.150.31
    saya bikin static lg lalu sy binding agar dpt koneksi inet.
    yg ingin sy tanyakan.
    acuan sy ip yg mn y mas?
    apkah ip rasp = ip pihole?

    BalasHapus

Tinggalkan komentar anda disini.