Online privacy is a hot issue. In this short tutorial I will show how to use adsuck to block loads of online tracking sites.

First install adsuck

$ sudo pkg_add adsuck

Now it’s time to configure adsuck. Adsuck needs to know about a dns server. I have put down two (one as backup):

$ cat /var/adsuck/files/resolv.conf

Of course you want to find some evil sites to block. The default file contains over 16000 domains, but you can add your own. Open /var/adsuck/files/hosts.small with your favorite text editor and add a few lines like this:

# Personal

Now make sure adsuck start on boot. Edit ``/etc/rc.cof.localand add adsuck torc_scripts`. So it looks like this:

$ cat /etc/rc.conf.local
ntpd_flags= # enabled during install
rc_scripts="gdm adsuck"

And start adsuck right now: sudo /etc/rc.d/adsuck start.

Finally configure your system to use adsuck as your dns resolver. Change /etc/resolv.conf and set nameserver If you want your setting to remain intact, even after using dhclient you also need to edit /etc/dhclient.conf and add the line

prepend domain-name-servers;

And now try it out. Grab your favorite webbrowser and go to If all is right Facebook should be gone from your internet. Much more pleasant browsing if you ask me.