Skip to content

Unbound - Werbeblocker

Linux
2 1 398
  • Den Unbound DNS-Server kann man auch prima als Werbeblocker benutzen.

    Screenshot_20190729-201229.png

    /usr/bin/wget -N https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
    /usr/bin/wget -N https://download.dnscrypt.info/blacklists/domains/mybase.txt
    /usr/bin/wget -N https://raw.githubusercontent.com/anudeepND/whitelist/master/domains/whitelist.txt
    cat hosts | grep '^0\.0\.0\.0' | awk '{print $2}' > block
    sed '/#/d; /*/d; /^$/d; /^\./d' mybase.txt > mybase
    cat block mybase | sort -u > merged
    touch /home/heat/mywhitelist
    cat whitelist.txt /home/heat/mywhitelist | sort -u > whitelist
    comm -23 merged whitelist > merged_corr
    awk '{print "local-zone: \""$1"\" refuse"}' merged_corr > /etc/unbound/unbound.conf.d/blocklist.conf
    

    Das Script ist leicht angepasst.

    Quelle des Scriptes: https://www.wilderssecurity.com/threads/adblocking-with-unbound.406346/

    Aktuell auf dem Server in der Testphase 🙂

    Links

  • Als Script

    #!/bin/bash
    ###############################################################################$
    #
    ###############################################################################$
    cd /Verzeichnis
    /usr/bin/wget -N https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
    /usr/bin/wget -N https://download.dnscrypt.info/blacklists/domains/mybase.txt
    /usr/bin/wget -N https://raw.githubusercontent.com/anudeepND/whitelist/master/domains/whitelist.txt
    cat hosts | grep '^0\.0\.0\.0' | awk '{print $2}' > block
    sed '/#/d; /*/d; /^$/d; /^\./d' mybase.txt > mybase
    cat block mybase | sort -u > merged
    touch /root/blocklist/mywhitelist
    cat whitelist.txt /root/blocklist/mywhitelist | sort -u > whitelist
    comm -23 merged whitelist > merged_corr
    awk '{print "local-zone: \""$1"\" refuse"}' merged_corr > /etc/unbound/unbound.conf.d/blocklist.conf
    sed -i '1s/.*$/server:\n&/g' /etc/unbound/unbound.conf.d/blocklist.conf
    service unbound restart
    
  • Debian Bookworm 12.11 released

    Linux linux debian
    1
    0 Stimmen
    1 Beiträge
    207 Aufrufe
    Niemand hat geantwortet
  • fail2ban auf einem systemd System (Debian 12)

    Linux linux fail2ban
    2
    0 Stimmen
    2 Beiträge
    270 Aufrufe
    FrankMF
    Auf Debian 13 Trixie fehlt noch folgendes apt install python3-setuptools
  • Minio - Objektspeicher selbst gehostet

    Linux minio linux restic
    1
    1
    0 Stimmen
    1 Beiträge
    218 Aufrufe
    Niemand hat geantwortet
  • Wireguard - Tunnel zur Fritz!Box 6591 Cable Part 3

    Angeheftet Wireguard wireguard dns-leak unbound
    1
    2
    0 Stimmen
    1 Beiträge
    604 Aufrufe
    Niemand hat geantwortet
  • nano - Zeilennummern dauerhaft anzeigen

    Linux linux
    3
    2
    0 Stimmen
    3 Beiträge
    3k Aufrufe
    FrankMF
    @masko Danke für die Ergänzung. Um den Code zu markieren, kannst Du im Texteditor auf </> klicken oder einfach 4 Leerzeichen vor den Code setzen. Dann sieht es besser aus Und Willkommen im Forum!
  • ZFS - Wichtige Befehle

    Linux zfs linux
    3
    0 Stimmen
    3 Beiträge
    1k Aufrufe
    FrankMF
    Heute mal drüber gestolpert, das es auch so was geben kann. root@pve2:~# zpool status pool: pool_NAS state: ONLINE status: Some supported and requested features are not enabled on the pool. The pool can still be used, but some features are unavailable. action: Enable all features using 'zpool upgrade'. Once this is done, the pool may no longer be accessible by software that does not support the features. See zpool-features(7) for details. scan: scrub repaired 0B in 00:20:50 with 0 errors on Sun Apr 13 00:44:51 2025 config: NAME STATE READ WRITE CKSUM pool_NAS ONLINE 0 0 0 mirror-0 ONLINE 0 0 0 ata-WDC_WDS100T1R0A-68A4W0_230520800733 ONLINE 0 0 0 ata-WDC_WDS100T1R0A-68A4W0_230520801376 ONLINE 0 0 0 errors: No known data errors Was machen? Als erstes mal ein Backup angestoßen. Danach root@pve2:~# zpool get all pool_NAS | grep feature pool_NAS feature@async_destroy enabled local pool_NAS feature@empty_bpobj active local pool_NAS feature@lz4_compress active local pool_NAS feature@multi_vdev_crash_dump enabled local pool_NAS feature@spacemap_histogram active local pool_NAS feature@enabled_txg active local pool_NAS feature@hole_birth active local pool_NAS feature@extensible_dataset active local pool_NAS feature@embedded_data active local pool_NAS feature@bookmarks enabled local pool_NAS feature@filesystem_limits enabled local pool_NAS feature@large_blocks enabled local pool_NAS feature@large_dnode enabled local pool_NAS feature@sha512 enabled local pool_NAS feature@skein enabled local pool_NAS feature@edonr enabled local pool_NAS feature@userobj_accounting active local pool_NAS feature@encryption enabled local pool_NAS feature@project_quota active local pool_NAS feature@device_removal enabled local pool_NAS feature@obsolete_counts enabled local pool_NAS feature@zpool_checkpoint enabled local pool_NAS feature@spacemap_v2 active local pool_NAS feature@allocation_classes enabled local pool_NAS feature@resilver_defer enabled local pool_NAS feature@bookmark_v2 enabled local pool_NAS feature@redaction_bookmarks enabled local pool_NAS feature@redacted_datasets enabled local pool_NAS feature@bookmark_written enabled local pool_NAS feature@log_spacemap active local pool_NAS feature@livelist enabled local pool_NAS feature@device_rebuild enabled local pool_NAS feature@zstd_compress enabled local pool_NAS feature@draid enabled local pool_NAS feature@zilsaxattr disabled local pool_NAS feature@head_errlog disabled local pool_NAS feature@blake3 disabled local pool_NAS feature@block_cloning disabled local pool_NAS feature@vdev_zaps_v2 disabled local Das kommt von neuen Funktionen, die zu ZFS hinzugefügt wurden und bei Erstellung des Pools nicht vorhanden waren. Dann upgraden wir mal root@pve2:~# zpool upgrade pool_NAS This system supports ZFS pool feature flags. Enabled the following features on 'pool_NAS': zilsaxattr head_errlog blake3 block_cloning vdev_zaps_v2 Kontrolle root@pve2:~# zpool status pool: pool_NAS state: ONLINE scan: scrub repaired 0B in 00:20:50 with 0 errors on Sun Apr 13 00:44:51 2025 config: NAME STATE READ WRITE CKSUM pool_NAS ONLINE 0 0 0 mirror-0 ONLINE 0 0 0 ata-WDC_WDS100T1R0A-68A4W0_230520800733 ONLINE 0 0 0 ata-WDC_WDS100T1R0A-68A4W0_230520801376 ONLINE 0 0 0 errors: No known data errors Features kontrollieren root@pve2:~# zpool get all pool_NAS | grep feature pool_NAS feature@async_destroy enabled local pool_NAS feature@empty_bpobj active local pool_NAS feature@lz4_compress active local pool_NAS feature@multi_vdev_crash_dump enabled local pool_NAS feature@spacemap_histogram active local pool_NAS feature@enabled_txg active local pool_NAS feature@hole_birth active local pool_NAS feature@extensible_dataset active local pool_NAS feature@embedded_data active local pool_NAS feature@bookmarks enabled local pool_NAS feature@filesystem_limits enabled local pool_NAS feature@large_blocks enabled local pool_NAS feature@large_dnode enabled local pool_NAS feature@sha512 enabled local pool_NAS feature@skein enabled local pool_NAS feature@edonr enabled local pool_NAS feature@userobj_accounting active local pool_NAS feature@encryption enabled local pool_NAS feature@project_quota active local pool_NAS feature@device_removal enabled local pool_NAS feature@obsolete_counts enabled local pool_NAS feature@zpool_checkpoint enabled local pool_NAS feature@spacemap_v2 active local pool_NAS feature@allocation_classes enabled local pool_NAS feature@resilver_defer enabled local pool_NAS feature@bookmark_v2 enabled local pool_NAS feature@redaction_bookmarks enabled local pool_NAS feature@redacted_datasets enabled local pool_NAS feature@bookmark_written enabled local pool_NAS feature@log_spacemap active local pool_NAS feature@livelist enabled local pool_NAS feature@device_rebuild enabled local pool_NAS feature@zstd_compress enabled local pool_NAS feature@draid enabled local pool_NAS feature@zilsaxattr enabled local pool_NAS feature@head_errlog active local pool_NAS feature@blake3 enabled local pool_NAS feature@block_cloning enabled local pool_NAS feature@vdev_zaps_v2 enabled local So, alle neuen Features aktiviert. Jetzt kann der Pool weiterhin seine Arbeit machen.
  • Wireguard - DNS für VPN-Server

    Wireguard unbound wireguard
    2
    2
    0 Stimmen
    2 Beiträge
    871 Aufrufe
    FrankMF
    Und mit wg auf dem Server kann man schön nachsehen, wie viel Daten da so durchlaufen. root@amadeus ~ # wg interface: wg0 public key: fGg7MkjzD6fVqxxxxxxxxxxxxxxxxxGa0NIBaTPRqqzU= private key: (hidden) listening port: 60563 peer: bDTE7Kr7Uw/Xxxxxxxxxxxxxxxxxxxxx46uHFZErWz8SGgI= endpoint: xx.xxx.194.117:58702 allowed ips: 10.10.0.3/32 latest handshake: 14 seconds ago transfer: 56.55 MiB received, 287.67 MiB sent
  • Liste von Linuxbefehlen

    Angeheftet Linux linux
    5
    1
    0 Stimmen
    5 Beiträge
    1k Aufrufe
    FrankMF
    Kurzer IPv6 Ping, ohne viel Tipparbeit root@:~# ping 2600:: PING 2600::(2600::) 56 data bytes 64 bytes from 2600::: icmp_seq=1 ttl=55 time=14.9 ms 64 bytes from 2600::: icmp_seq=2 ttl=55 time=13.0 ms 64 bytes from 2600::: icmp_seq=3 ttl=55 time=15.9 ms