{"id":37953,"date":"2026-01-19T14:31:15","date_gmt":"2026-01-19T11:31:15","guid":{"rendered":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/"},"modified":"2026-01-19T14:31:15","modified_gmt":"2026-01-19T11:31:15","slug":"dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme","status":"publish","type":"post","link":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/","title":{"rendered":"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme"},"content":{"rendered":"<h2>dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme<\/h2>\n<p>Modern Linux da\u011f\u0131t\u0131mlar\u0131nda a\u011f yap\u0131land\u0131rmas\u0131 ve DNS \u00e7\u00f6z\u00fcmlemesi, <code>systemd-resolved<\/code> gibi ara\u00e7lar taraf\u0131ndan y\u00f6netilmektedir. Bu durum, \u00f6zel bir DNS sunucusu, \u00f6zellikle <code>dnsmasq<\/code> gibi hafif ve esnek bir \u00e7\u00f6z\u00fcm kurmak isteyen kullan\u0131c\u0131lar i\u00e7in bazen \u00e7ak\u0131\u015fmalara yol a\u00e7abilir. <code>systemd-resolved<\/code> genellikle 53 numaral\u0131 portu dinleyerek sistemin DNS sorgular\u0131n\u0131 y\u00f6netir ve bu, ayn\u0131 portu kullanmak isteyen <code>dnsmasq<\/code> gibi ba\u015fka bir DNS sunucusunun ba\u015flamas\u0131n\u0131 engeller. Bu makalede, <code>dnsmasq<\/code>&#8216;\u0131 <code>systemd-resolved<\/code> ile \u00e7ak\u0131\u015fmadan, <code>macvlan<\/code> a\u011f aray\u00fcz\u00fcn\u00fc kullanarak ba\u011f\u0131ms\u0131z bir DNS sunucusu olarak nas\u0131l yap\u0131land\u0131raca\u011f\u0131m\u0131z\u0131 detayl\u0131 bir \u015fekilde inceleyece\u011fiz. Bu yakla\u015f\u0131m, sistem DNS \u00e7\u00f6z\u00fcmlemesini etkilemeden, \u00f6zel DNS gereksinimlerinizi kar\u015f\u0131laman\u0131n zarif bir yolunu sunar.<\/p>\n<h3>Giri\u015f: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131 ve dnsmasq \u0130htiyac\u0131<\/h3>\n<p>Linux sistemlerinde DNS \u00e7\u00f6z\u00fcmlemesi, \u00f6zellikle <code>systemd<\/code> tabanl\u0131 da\u011f\u0131t\u0131mlarda, <code>systemd-resolved<\/code> servisi taraf\u0131ndan merkezi olarak y\u00f6netilir. Bu servis, DNS sorgular\u0131n\u0131 \u00f6nbellekler, DNSSEC do\u011frulamas\u0131n\u0131 yapar ve <code>\/etc\/resolv.conf<\/code> dosyas\u0131n\u0131 y\u00f6netir. Ancak, kendi \u00f6zel DNS sunucunuzu (\u00f6rne\u011fin, ev a\u011f\u0131 i\u00e7in \u00f6zel host adlar\u0131, reklam engelleme veya daha geli\u015fmi\u015f \u00f6nbellekleme) \u00e7al\u0131\u015ft\u0131rmak istedi\u011finizde, <code>systemd-resolved<\/code> ile port \u00e7ak\u0131\u015fmas\u0131 ya\u015fanmas\u0131 ka\u00e7\u0131n\u0131lmazd\u0131r.<\/p>\n<h4>systemd-resolved Nedir ve Neden Sorun Yarat\u0131r?<\/h4>\n<p><code>systemd-resolved<\/code>, <code>systemd<\/code> projesinin bir par\u00e7as\u0131 olarak geli\u015ftirilmi\u015f, a\u011f isim \u00e7\u00f6z\u00fcmleme servisi ve DNS \u00f6nbellekleyicisidir. Yerel olarak 53 numaral\u0131 UDP\/TCP portunu dinler ve sistemin t\u00fcm DNS sorgular\u0131n\u0131 bu port \u00fczerinden al\u0131r. Bu yakla\u015f\u0131m, tek bir merkezi DNS \u00e7\u00f6z\u00fcmleyiciye sahip olman\u0131n avantajlar\u0131n\u0131 sunarken, ayn\u0131 portu kullanmak isteyen <code>dnsmasq<\/code> gibi di\u011fer DNS servislerinin ba\u015flamas\u0131n\u0131 engeller. E\u011fer <code>dnsmasq<\/code>&#8216;\u0131 varsay\u0131lan 53 numaral\u0131 portta \u00e7al\u0131\u015ft\u0131rmaya \u00e7al\u0131\u015f\u0131rsan\u0131z, &#8220;Address already in use&#8221; (Adres zaten kullan\u0131mda) hatas\u0131 al\u0131rs\u0131n\u0131z.<\/p>\n<h4>dnsmasq&#8217;\u0131n Avantajlar\u0131 ve Kullan\u0131m Alanlar\u0131<\/h4>\n<p><code>dnsmasq<\/code>, k\u00fc\u00e7\u00fck a\u011flar i\u00e7in tasarlanm\u0131\u015f hafif, h\u0131zl\u0131 ve esnek bir DNS \u00f6nbellekleyicisi, DHCP sunucusu ve TFTP sunucusudur. Basit yap\u0131land\u0131rmas\u0131, d\u00fc\u015f\u00fck kaynak t\u00fcketimi ve geli\u015fmi\u015f \u00f6zellikleri (statik DHCP atamalar\u0131, \u00f6zel DNS kay\u0131tlar\u0131, PXE \u00f6ny\u00fckleme deste\u011fi) sayesinde \u00f6zellikle ev a\u011flar\u0131, k\u00fc\u00e7\u00fck ofisler veya geli\u015ftirme ortamlar\u0131 i\u00e7in ideal bir \u00e7\u00f6z\u00fcmd\u00fcr. Kendi alan adlar\u0131n\u0131z\u0131 \u00e7\u00f6z\u00fcmlemek, belirli alan adlar\u0131n\u0131 engellemek veya a\u011f\u0131n\u0131zdaki cihazlara \u00f6zel isimler atamak i\u00e7in <code>dnsmasq<\/code> vazge\u00e7ilmez bir ara\u00e7t\u0131r.<\/p>\n<h4>macvlan \u00c7\u00f6z\u00fcm\u00fc Neden Gerekli?<\/h4>\n<p><code>systemd-resolved<\/code> ile <code>dnsmasq<\/code> aras\u0131ndaki port \u00e7ak\u0131\u015fmas\u0131n\u0131 \u00e7\u00f6zmek i\u00e7in birka\u00e7 y\u00f6ntem vard\u0131r: <code>systemd-resolved<\/code>&#8216;u devre d\u0131\u015f\u0131 b\u0131rakmak (ki bu \u00f6nerilmez, sistemin genel DNS \u00e7\u00f6z\u00fcmlemesini bozabilir), <code>dnsmasq<\/code>&#8216;\u0131 farkl\u0131 bir portta \u00e7al\u0131\u015ft\u0131rmak (ancak bu durumda istemcilerinizi bu porta y\u00f6nlendirmeniz gerekir) veya <code>dnsmasq<\/code>&#8216;\u0131 farkl\u0131 bir IP adresinde \u00e7al\u0131\u015ft\u0131rmak. <code>macvlan<\/code> aray\u00fcz\u00fc, son se\u00e7ene\u011fi m\u00fcmk\u00fcn k\u0131lar. <code>macvlan<\/code>, fiziksel bir a\u011f aray\u00fcz\u00fc \u00fczerinde birden fazla sanal a\u011f aray\u00fcz\u00fc olu\u015fturman\u0131za olanak tan\u0131r. Her <code>macvlan<\/code> aray\u00fcz\u00fc kendi benzersiz MAC adresine ve IP adresine sahip olabilir, bu da <code>dnsmasq<\/code>&#8216;\u0131 <code>systemd-resolved<\/code>&#8216;dan tamamen izole edilmi\u015f ayr\u0131 bir IP adresinde ve dolay\u0131s\u0131yla ayr\u0131 bir 53 numaral\u0131 portta \u00e7al\u0131\u015ft\u0131rman\u0131za imkan verir.<\/p>\n<h3>macvlan Aray\u00fcz\u00fcn\u00fcn Temelleri ve \u00c7al\u0131\u015fma Prensibi<\/h3>\n<p><code>macvlan<\/code>, Linux \u00e7ekirde\u011finde bulunan bir a\u011f sanalla\u015ft\u0131rma teknolojisidir. Tek bir fiziksel a\u011f aray\u00fcz\u00fc \u00fczerinde birden fazla mant\u0131ksal a\u011f aray\u00fcz\u00fc olu\u015fturman\u0131z\u0131 sa\u011flar. Bu sanal aray\u00fczlerin her biri kendi benzersiz MAC adresine ve IP adresine sahip olabilir ve a\u011fda ayr\u0131 bir cihaz gibi davran\u0131r.<\/p>\n<h4>macvlan Nedir?<\/h4>\n<p><code>macvlan<\/code>, bir ana fiziksel a\u011f aray\u00fcz\u00fcne (\u00f6rne\u011fin <code>eth0<\/code> veya <code>enp0s3<\/code>) ba\u011fl\u0131, ancak ondan ba\u011f\u0131ms\u0131z \u00e7al\u0131\u015fan sanal a\u011f aray\u00fczleri olu\u015fturur. Bu sanal aray\u00fczler, do\u011frudan ana aray\u00fcz \u00fczerinden a\u011fa eri\u015firler ve her biri kendi IP adresine sahip olabilir. Bu sayede, ayn\u0131 fiziksel port \u00fczerinden birden fazla IP adresiyle hizmet verebilirsiniz.<\/p>\n<h4>Bridge, VEPA ve Private Modlar\u0131<\/h4>\n<p><code>macvlan<\/code>&#8216;\u0131n \u00fc\u00e7 temel \u00e7al\u0131\u015fma modu vard\u0131r:<\/p>\n<p>*   <strong>Bridge Modu:<\/strong> Bu en yayg\u0131n moddur. <code>macvlan<\/code> aray\u00fczleri, ana aray\u00fcz \u00fczerinden birbirleriyle ve harici a\u011fla do\u011frudan ileti\u015fim kurabilir. Bir anahtara (switch) ba\u011fl\u0131 birden fazla fiziksel cihaz gibi davran\u0131rlar.<br \/>\n*   <strong>VEPA (Virtual Ethernet Port Aggregator) Modu:<\/strong> <code>macvlan<\/code> aray\u00fczleri aras\u0131ndaki trafik, harici bir anahtar \u00fczerinden y\u00f6nlendirilir. Yani, bir <code>macvlan<\/code> aray\u00fcz\u00fcnden di\u011ferine giden trafik \u00f6nce anahtara gider, sonra geri d\u00f6ner.<br \/>\n*   <strong>Private Modu:<\/strong> Bu modda, <code>macvlan<\/code> aray\u00fczleri birbirleriyle ileti\u015fim kuramazlar. Sadece ana aray\u00fcz \u00fczerinden harici a\u011f ile ileti\u015fim kurabilirler.<\/p>\n<p>Bizim senaryomuz i\u00e7in genellikle &#8220;Bridge&#8221; modu yeterli olacakt\u0131r, \u00e7\u00fcnk\u00fc <code>dnsmasq<\/code>&#8216;\u0131n sadece a\u011fa eri\u015fmesi ve DNS sorgular\u0131n\u0131 yan\u0131tlamas\u0131 gerekmektedir.<\/p>\n<h4>macvlan&#8217;\u0131n A\u011fdaki Yeri<\/h4>\n<p>Bir <code>macvlan<\/code> aray\u00fcz\u00fc olu\u015fturdu\u011funuzda, bu aray\u00fcz fiziksel a\u011f\u0131n\u0131zdaki bir anahtara do\u011frudan ba\u011fl\u0131 yeni bir sanal cihaz gibi g\u00f6r\u00fcn\u00fcr. Ana aray\u00fcz, t\u00fcm bu sanal aray\u00fczlerin trafi\u011fini y\u00f6netir. Bu, \u00f6zellikle konteynerle\u015ftirilmi\u015f uygulamalar (Docker gibi) veya sanal makineler i\u00e7in a\u011f izolasyonu sa\u011flamak veya bizim durumumuzda oldu\u011fu gibi, ayn\u0131 fiziksel makinede farkl\u0131 servisleri farkl\u0131 IP adreslerinde \u00e7al\u0131\u015ft\u0131rmak i\u00e7in \u00e7ok kullan\u0131\u015fl\u0131d\u0131r.<\/p>\n<h3>macvlan Aray\u00fcz\u00fcn\u00fcn Olu\u015fturulmas\u0131 ve Yap\u0131land\u0131r\u0131lmas\u0131<\/h3>\n<p><code>macvlan<\/code> aray\u00fcz\u00fc olu\u015fturmak i\u00e7in <code>ip<\/code> komutunu veya <code>systemd-networkd<\/code> gibi a\u011f y\u00f6neticilerini kullanabiliriz. Burada hem ge\u00e7ici hem de kal\u0131c\u0131 yap\u0131land\u0131rma y\u00f6ntemlerini ele alaca\u011f\u0131z.<\/p>\n<h4>\u00d6n Gereksinimler<\/h4>\n<p>*   Linux tabanl\u0131 bir i\u015fletim sistemi (Ubuntu, Debian, CentOS vb.).<br \/>\n*   <code>iproute2<\/code> paketi kurulu olmal\u0131 (genellikle varsay\u0131lan olarak gelir).<br \/>\n*   Ana fiziksel a\u011f aray\u00fcz\u00fcn\u00fcz\u00fcn ad\u0131 (\u00f6rne\u011fin <code>enp0s3<\/code>, <code>eth0<\/code>). Bu ad\u0131 <code>ip a<\/code> komutuyla \u00f6\u011frenebilirsiniz.<\/p>\n<h4>Ge\u00e7ici macvlan Olu\u015fturma<\/h4>\n<p>A\u015fa\u011f\u0131daki komutlarla ge\u00e7ici bir <code>macvlan<\/code> aray\u00fcz\u00fc olu\u015fturabilir ve ona bir IP adresi atayabilirsiniz. Bu yap\u0131land\u0131rma sistem yeniden ba\u015flat\u0131ld\u0131\u011f\u0131nda kaybolur.<\/p>\n<p>\u00d6ncelikle ana aray\u00fcz\u00fcn\u00fcz\u00fc belirleyin. Diyelim ki <code>enp0s3<\/code>.<\/p>\n<pre><code class=\"language-bash\"># macvlan aray\u00fcz\u00fcn\u00fc olu\u015ftur (bridge modunda)\nsudo ip link add link enp0s3 name macvlan0 type macvlan mode bridge\n\n# macvlan aray\u00fcz\u00fcne bir IP adresi ata (kendi a\u011f\u0131n\u0131za uygun bir IP se\u00e7in)\n# \u00d6rnek: A\u011f\u0131n\u0131z 192.168.1.0\/24 ise, 192.168.1.200 kullanabilirsiniz.\nsudo ip addr add 192.168.1.200\/24 dev macvlan0\n\n# macvlan aray\u00fcz\u00fcn\u00fc etkinle\u015ftir\nsudo ip link set macvlan0 up\n\n# Kontrol et\nip a show macvlan0<\/pre>\n<p><\/code><\/p>\n<p>Bu komutlar, <code>enp0s3<\/code> \u00fczerinde <code>macvlan0<\/code> ad\u0131nda yeni bir aray\u00fcz olu\u015fturur ve ona <code>192.168.1.200<\/code> IP adresini atar. Art\u0131k bu IP adresi \u00fczerinden a\u011fa eri\u015febilirsiniz.<\/p>\n<h4>Kal\u0131c\u0131 macvlan Yap\u0131land\u0131rmas\u0131 (systemd-networkd veya netplan ile)<\/h4>\n<p>Kal\u0131c\u0131 bir <code>macvlan<\/code> yap\u0131land\u0131rmas\u0131 i\u00e7in <code>systemd-networkd<\/code> (\u00e7o\u011fu modern systemd tabanl\u0131 da\u011f\u0131t\u0131mda) veya <code>netplan<\/code> (Ubuntu'da yayg\u0131n) kullanmak en iyisidir.<\/p>\n<p><strong>systemd-networkd ile (\u00d6rnek: Debian\/Ubuntu sunucular, Fedora, Arch)<\/strong><\/p>\n<p><code>\/etc\/systemd\/network\/<\/code> dizininde iki dosya olu\u015fturaca\u011f\u0131z: biri <code>macvlan<\/code> aray\u00fcz\u00fcn\u00fc tan\u0131mlamak i\u00e7in, di\u011feri ise IP adresini atamak i\u00e7in.<\/p>\n<p>Ana aray\u00fcz\u00fcn\u00fcz <code>enp0s3<\/code> ve <code>macvlan<\/code> aray\u00fcz\u00fcn\u00fcz <code>macvlan0<\/code> olacaksa:<\/p>\n<p>1.  <strong><code>\/etc\/systemd\/network\/20-macvlan0.netdev<\/code><\/strong> dosyas\u0131n\u0131 olu\u015fturun:<\/p>\n<pre><code class=\"language-ini\">[Match]\n    # macvlan'\u0131n ba\u011flanaca\u011f\u0131 ana aray\u00fcz\u00fcn ad\u0131n\u0131 buraya yaz\u0131n\n    Name=macvlan0\n\n    [Network]\n    # Ana aray\u00fcz\u00fcn ad\u0131n\u0131 buraya yaz\u0131n\n    MACVLan=enp0s3\n    MACVLanMode=bridge<\/pre>\n<p><\/code><\/p>\n<p>2.  <strong><code>\/etc\/systemd\/network\/25-macvlan0.network<\/code><\/strong> dosyas\u0131n\u0131 olu\u015fturun:<\/p>\n<pre><code class=\"language-ini\">[Match]\n    Name=macvlan0\n\n    [Network]\n    Address=192.168.1.200\/24\n    Gateway=192.168.1.1\n    DNS=8.8.8.8<\/pre>\n<p><\/code><br \/>\n    *   <code>Address<\/code>: <code>macvlan0<\/code> i\u00e7in kullanmak istedi\u011finiz IP adresi ve alt a\u011f maskesi.<br \/>\n    *   <code>Gateway<\/code>: A\u011f\u0131n\u0131z\u0131n varsay\u0131lan a\u011f ge\u00e7idi.<br \/>\n    *   <code>DNS<\/code>: \u0130ste\u011fe ba\u011fl\u0131 olarak bu aray\u00fcz i\u00e7in DNS sunucular\u0131 belirtebilirsiniz.<\/p>\n<p>3.  De\u011fi\u015fiklikleri uygulamak i\u00e7in <code>systemd-networkd<\/code> servisini yeniden ba\u015flat\u0131n:<\/p>\n<pre><code class=\"language-bash\">sudo systemctl enable systemd-networkd\n    sudo systemctl restart systemd-networkd<\/pre>\n<p><\/code><\/p>\n<p><strong>Netplan ile (\u00d6rnek: Ubuntu Masa\u00fcst\u00fc ve Sunucu)<\/strong><\/p>\n<p><code>\/etc\/netplan\/<\/code> dizininde bir <code>.yaml<\/code> dosyas\u0131 olu\u015fturun veya mevcut olan\u0131 d\u00fczenleyin (\u00f6rne\u011fin <code>01-netcfg.yaml<\/code>).<\/p>\n<pre><code class=\"language-yaml\">network:\n  version: 2\n  renderer: networkd # veya NetworkManager\n  ethernets:\n    enp0s3: # Ana fiziksel aray\u00fcz\u00fcn\u00fcz\n      dhcp4: true # Ana aray\u00fcz DHCP ile IP als\u0131n\n  macvlans:\n    macvlan0:\n      link: enp0s3 # macvlan'\u0131n ba\u011flanaca\u011f\u0131 ana aray\u00fcz\n      addresses: [192.168.1.200\/24] # macvlan i\u00e7in statik IP\n      routes:\n        - to: default\n          via: 192.168.1.1 # Varsay\u0131lan a\u011f ge\u00e7idi\n      nameservers:\n        addresses: [8.8.8.8, 8.8.4.4] # Bu aray\u00fcz i\u00e7in DNS sunucular\u0131<\/pre>\n<p><\/code><\/p>\n<p>De\u011fi\u015fiklikleri uygulamak i\u00e7in:<\/p>\n<pre><code class=\"language-bash\">sudo netplan generate\nsudo netplan apply<\/pre>\n<p><\/code><\/p>\n<h4>IP Adresi Atamas\u0131 ve A\u011f Kontrol\u00fc<\/h4>\n<p><code>macvlan<\/code> aray\u00fcz\u00fcn\u00fcz\u00fc yap\u0131land\u0131rd\u0131ktan sonra, <code>ip a<\/code> komutuyla IP adresinin do\u011fru atand\u0131\u011f\u0131n\u0131 kontrol edin:<\/p>\n<pre><code class=\"language-bash\">ip a show macvlan0<\/pre>\n<p><\/code><\/p>\n<p>\u00c7\u0131kt\u0131, <code>macvlan0<\/code> aray\u00fcz\u00fcn\u00fcn do\u011fru IP adresine sahip oldu\u011funu g\u00f6stermelidir. Ayr\u0131ca, bu yeni IP adresine ba\u015fka bir cihazdan <code>ping<\/code> atarak a\u011f eri\u015fimini test edebilirsiniz.<\/p>\n<h3>dnsmasq Kurulumu ve Temel Yap\u0131land\u0131rmas\u0131<\/h3>\n<p><code>macvlan<\/code> aray\u00fcz\u00fcm\u00fcz haz\u0131r oldu\u011funa g\u00f6re, \u015fimdi <code>dnsmasq<\/code>'\u0131 kurup bu aray\u00fcz \u00fczerinde \u00e7al\u0131\u015facak \u015fekilde yap\u0131land\u0131rabiliriz.<\/p>\n<h4>dnsmasq Kurulumu<\/h4>\n<p>\u00c7o\u011fu Linux da\u011f\u0131t\u0131m\u0131nda <code>dnsmasq<\/code> paket y\u00f6neticisi arac\u0131l\u0131\u011f\u0131yla kolayca kurulabilir:<\/p>\n<p><strong>Debian\/Ubuntu tabanl\u0131 sistemler:<\/strong><\/p>\n<pre><code class=\"language-bash\">sudo apt update\nsudo apt install dnsmasq<\/pre>\n<p><\/code><\/p>\n<p><strong>CentOS\/RHEL tabanl\u0131 sistemler:<\/strong><\/p>\n<pre><code class=\"language-bash\">sudo yum install dnsmasq\n# veya modern RHEL\/CentOS'ta\nsudo dnf install dnsmasq<\/pre>\n<p><\/code><\/p>\n<p>Kurulumdan sonra <code>dnsmasq<\/code> servisi otomatik olarak ba\u015flayabilir ve varsay\u0131lan olarak <code>systemd-resolved<\/code> ile \u00e7ak\u0131\u015facakt\u0131r. Bu nedenle, yap\u0131land\u0131rmadan \u00f6nce durdurmak iyi bir fikir olabilir:<\/p>\n<pre><code class=\"language-bash\">sudo systemctl stop dnsmasq\nsudo systemctl disable dnsmasq # Otomatik ba\u015flamas\u0131n\u0131 \u00f6nle<\/pre>\n<p><\/code><\/p>\n<h4>dnsmasq'\u0131 macvlan Aray\u00fcz\u00fcne Ba\u011flama<\/h4>\n<p><code>dnsmasq<\/code>'\u0131n sadece <code>macvlan<\/code> aray\u00fcz\u00fcm\u00fcz\u00fcn IP adresini dinlemesini sa\u011flamak i\u00e7in yap\u0131land\u0131rma dosyas\u0131n\u0131 d\u00fczenlememiz gerekiyor. <code>dnsmasq<\/code>'\u0131n ana yap\u0131land\u0131rma dosyas\u0131 genellikle <code>\/etc\/dnsmasq.conf<\/code>'tur.<\/p>\n<p>Bu dosyay\u0131 bir metin d\u00fczenleyiciyle a\u00e7\u0131n:<\/p>\n<pre><code class=\"language-bash\">sudo nano \/etc\/dnsmasq.conf<\/pre>\n<p><\/code><\/p>\n<p>A\u015fa\u011f\u0131daki sat\u0131rlar\u0131 ekleyin veya mevcut olanlar\u0131 d\u00fczenleyin:<\/p>\n<pre><code class=\"language-ini\"># Sadece macvlan aray\u00fcz\u00fcn\u00fc dinle\nlisten-address=192.168.1.200 # macvlan0'a atad\u0131\u011f\u0131n\u0131z IP adresi\nbind-interfaces # Sadece belirtilen aray\u00fczleri dinle\n\n# Yukar\u0131 ak\u0131\u015f DNS sunucular\u0131 (upstream DNS servers)\n# Bu sunucular, dnsmasq'\u0131n \u00e7\u00f6zemedi\u011fi sorgular\u0131 iletece\u011fi sunuculard\u0131r.\n# Google DNS, Cloudflare DNS veya ISS'nizin DNS'i olabilir.\nserver=8.8.8.8\nserver=1.1.1.1\n\n# \u00d6nbellek boyutunu ayarla (iste\u011fe ba\u011fl\u0131, varsay\u0131lan 150)\ncache-size=1000\n\n# Yerel alan adlar\u0131 i\u00e7in (\u00f6rne\u011fin .home)\n# local=\/home\/\n\n# Yerel host kay\u0131tlar\u0131 i\u00e7in \/etc\/hosts dosyas\u0131n\u0131 kullan\n# addn-hosts=\/etc\/dnsmasq.d\/myhosts.conf # Ek host dosyas\u0131\n\n# DNSSEC deste\u011fi (iste\u011fe ba\u011fl\u0131)\n# dnssec\n# trust-anchor=.,19036,8,2,49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5\n\n# Loglama (iste\u011fe ba\u011fl\u0131)\n# log-queries\n# log-facility=\/var\/log\/dnsmasq.log<\/pre>\n<p><\/code><\/p>\n<p><strong>A\u00e7\u0131klamalar:<\/strong><\/p>\n<p>*   <code>listen-address=192.168.1.200<\/code>: <code>dnsmasq<\/code>'\u0131n sadece bu IP adresindeki 53 numaral\u0131 portu dinlemesini sa\u011flar. <code>systemd-resolved<\/code> hala ana aray\u00fczdeki 127.0.0.53 IP adresini dinleyebilir.<br \/>\n*   <code>bind-interfaces<\/code>: Bu komut, <code>dnsmasq<\/code>'\u0131n sadece <code>listen-address<\/code> ile belirtilen aray\u00fczleri dinlemesini zorlar.<br \/>\n*   <code>server=...<\/code>: <code>dnsmasq<\/code>'\u0131n kendi \u00e7\u00f6zemedi\u011fi sorgular\u0131 y\u00f6nlendirece\u011fi harici DNS sunucular\u0131d\u0131r.<\/p>\n<h4>Temel DNS Yap\u0131land\u0131rmas\u0131 (upstream sunucular, host kay\u0131tlar\u0131)<\/h4>\n<p><code>dnsmasq<\/code>'\u0131 temel bir DNS sunucusu olarak kullanmak i\u00e7in, yukar\u0131 ak\u0131\u015f DNS sunucular\u0131n\u0131 (<code>server=<\/code>) yap\u0131land\u0131rman\u0131n yan\u0131 s\u0131ra, kendi yerel DNS kay\u0131tlar\u0131n\u0131z\u0131 da ekleyebilirsiniz.<\/p>\n<p><strong>Yerel Host Kay\u0131tlar\u0131:<\/strong><br \/>\n<code>\/etc\/hosts<\/code> dosyan\u0131zdaki kay\u0131tlar <code>dnsmasq<\/code> taraf\u0131ndan otomatik olarak okunur. Ek host kay\u0131tlar\u0131 eklemek isterseniz, <code>addn-hosts=\/etc\/dnsmasq.d\/myhosts.conf<\/code> gibi bir sat\u0131r ekleyip, <code>\/etc\/dnsmasq.d\/myhosts.conf<\/code> dosyas\u0131nda \u015fu formatta kay\u0131tlar olu\u015fturabilirsiniz:<\/p>\n<pre><code class=\"language-plaintext\">192.168.1.100    mydevice.home\n192.168.1.101    anotherdevice<\/pre>\n<p><\/code><\/p>\n<p><strong>Yerel Alan Adlar\u0131:<\/strong><br \/>\nA\u011f\u0131n\u0131zda <code>.home<\/code> gibi \u00f6zel bir alan ad\u0131 kullanmak isterseniz, <code>local=\/home\/<\/code> sat\u0131r\u0131n\u0131 aktif edebilirsiniz. Bu, <code>.home<\/code> ile biten t\u00fcm sorgular\u0131n <code>dnsmasq<\/code> taraf\u0131ndan yerel olarak \u00e7\u00f6z\u00fclmeye \u00e7al\u0131\u015f\u0131laca\u011f\u0131 anlam\u0131na gelir.<\/p>\n<h4>DHCP ve PXE (Opsiyonel ama bahsedilebilir)<\/h4>\n<p><code>dnsmasq<\/code> ayn\u0131 zamanda g\u00fc\u00e7l\u00fc bir DHCP sunucusu olarak da g\u00f6rev yapabilir. E\u011fer a\u011f\u0131n\u0131zda DHCP servisini de <code>dnsmasq<\/code> \u00fczerinden y\u00f6netmek isterseniz, <code>\/etc\/dnsmasq.conf<\/code> dosyas\u0131na a\u015fa\u011f\u0131daki gibi sat\u0131rlar ekleyebilirsiniz:<\/p>\n<pre><code class=\"language-ini\"># DHCP aral\u0131\u011f\u0131 ve kiralama s\u00fcresi\ndhcp-range=192.168.1.100,192.168.1.150,12h\n\n# Varsay\u0131lan a\u011f ge\u00e7idi (opsiyonel, dhcp-range ile ayn\u0131 a\u011fda de\u011filse)\ndhcp-option=3,192.168.1.1\n\n# DHCP istemcilerine DNS sunucusu olarak kendi IP adresimizi ver\ndhcp-option=6,192.168.1.200 # macvlan0'\u0131n IP adresi\n\n# Statik DHCP atamalar\u0131\n# dhcp-host=AA:BB:CC:DD:EE:FF,192.168.1.10,mydevice<\/pre>\n<p><\/code><br \/>\nBu yap\u0131land\u0131rma, <code>dnsmasq<\/code>'\u0131n <code>macvlan0<\/code> aray\u00fcz\u00fc \u00fczerinden DHCP hizmeti de sunmas\u0131n\u0131 sa\u011flar. Ancak, a\u011f\u0131n\u0131zda ba\u015fka bir DHCP sunucusu \u00e7al\u0131\u015f\u0131yorsa (\u00f6rne\u011fin modeminiz), \u00e7ak\u0131\u015fmalar\u0131 \u00f6nlemek i\u00e7in <code>dnsmasq<\/code>'\u0131n DHCP \u00f6zelli\u011fini devre d\u0131\u015f\u0131 b\u0131rakman\u0131z veya dikkatlice yap\u0131land\u0131rman\u0131z gerekir.<\/p>\n<p>Yap\u0131land\u0131rma dosyas\u0131n\u0131 kaydettikten sonra <code>dnsmasq<\/code> servisini ba\u015flat\u0131n ve durumunu kontrol edin:<\/p>\n<pre><code class=\"language-bash\">sudo systemctl start dnsmasq\nsudo systemctl status dnsmasq<\/pre>\n<p><\/code><br \/>\nServisin <code>macvlan0<\/code> IP adresini dinledi\u011fini <code>netstat -tulnp | grep 53<\/code> komutuyla da do\u011frulayabilirsiniz.<\/p>\n<h3>dnsmasq'\u0131 systemd-resolved ile \u00c7ak\u0131\u015fmadan \u00c7al\u0131\u015ft\u0131rma<\/h3>\n<p><code>macvlan<\/code> stratejisi, <code>systemd-resolved<\/code> ile <code>dnsmasq<\/code> aras\u0131ndaki \u00e7ak\u0131\u015fmay\u0131 zarif bir \u015fekilde \u00e7\u00f6zer. <code>dnsmasq<\/code>'\u0131 ayr\u0131 bir IP adresinde \u00e7al\u0131\u015ft\u0131rd\u0131\u011f\u0131m\u0131z i\u00e7in, her iki servis de kendi 53 numaral\u0131 portlar\u0131n\u0131 dinleyebilir, ancak farkl\u0131 IP adreslerinde.<\/p>\n<h4>systemd-resolved'u Devre D\u0131\u015f\u0131 B\u0131rakmak (veya Yanl\u0131\u015f Yakla\u015f\u0131m)<\/h4>\n<p>Baz\u0131 rehberlerde <code>systemd-resolved<\/code>'u tamamen devre d\u0131\u015f\u0131 b\u0131rakmak \u00f6nerilir. Bu, <code>sudo systemctl disable systemd-resolved && sudo systemctl stop systemd-resolved<\/code> komutlar\u0131yla yap\u0131labilir. Ancak, bu yakla\u015f\u0131m sistemin genel DNS \u00e7\u00f6z\u00fcmlemesini bozabilir ve baz\u0131 uygulamalar\u0131n beklendi\u011fi gibi \u00e7al\u0131\u015fmamas\u0131na neden olabilir. Ayr\u0131ca, <code>\/etc\/resolv.conf<\/code> dosyas\u0131n\u0131n manuel olarak d\u00fczenlenmesi gerekebilir, bu da <code>systemd<\/code> tabanl\u0131 sistemlerde genellikle \u00f6nerilmez. <code>macvlan<\/code> \u00e7\u00f6z\u00fcm\u00fc, <code>systemd-resolved<\/code>'u oldu\u011fu gibi b\u0131rak\u0131rken <code>dnsmasq<\/code>'\u0131 ba\u011f\u0131ms\u0131z bir \u015fekilde \u00e7al\u0131\u015ft\u0131rmam\u0131z\u0131 sa\u011flar.<\/p>\n<h4>dnsmasq'\u0131 \u00d6zel Bir Portta \u00c7al\u0131\u015ft\u0131rma (macvlan olmadan)<\/h4>\n<p><code>macvlan<\/code> kullanmak istemiyorsan\u0131z, <code>dnsmasq<\/code>'\u0131 farkl\u0131 bir portta (\u00f6rne\u011fin 5353) \u00e7al\u0131\u015ft\u0131rabilirsiniz:<\/p>\n<pre><code class=\"language-ini\">port=5353\nlisten-address=127.0.0.1 # Veya ana aray\u00fcz\u00fcn\u00fcz\u00fcn IP'si<\/pre>\n<p><\/code><br \/>\nBu durumda, DNS sunucusu olarak <code>dnsmasq<\/code>'\u0131 kullanmak isteyen istemcilerinizi (veya <code>\/etc\/resolv.conf<\/code> dosyas\u0131n\u0131) bu \u00f6zel porta y\u00f6nlendirmeniz gerekir. Ancak bu, genellikle a\u011fdaki di\u011fer cihazlar i\u00e7in pratik de\u011fildir ve sistem genelindeki uygulamalar\u0131n bu portu kullanmas\u0131n\u0131 sa\u011flamak zordur.<\/p>\n<h4>macvlan ile \u00c7\u00f6z\u00fcm\u00fcn Avantajlar\u0131<\/h4>\n<p><code>macvlan<\/code> ile <code>dnsmasq<\/code>'\u0131 \u00e7al\u0131\u015ft\u0131rman\u0131n temel avantaj\u0131, <code>dnsmasq<\/code>'\u0131n kendi \u00f6zel IP adresinde standart DNS portu olan 53'\u00fc dinleyebilmesidir. Bu, a\u011f\u0131n\u0131zdaki di\u011fer cihazlar\u0131n (ak\u0131ll\u0131 telefonlar, tabletler, di\u011fer bilgisayarlar) <code>dnsmasq<\/code>'\u0131 DNS sunucusu olarak kolayca yap\u0131land\u0131rabilece\u011fi anlam\u0131na gelir. <code>systemd-resolved<\/code> ise ana IP adresinde kendi 53 numaral\u0131 portunu dinlemeye devam edebilir ve sistemin kendi DNS sorgular\u0131n\u0131 y\u00f6netebilir. Bu iki servis tamamen birbirinden izole edilmi\u015f olur.<\/p>\n<p><strong>\u00d6rnek:<\/strong><br \/>\n*   <strong>Sisteminiz:<\/strong> <code>systemd-resolved<\/code> -> <code>127.0.0.53:53<\/code> (veya ana IP'niz)<br \/>\n*   <strong>dnsmasq:<\/strong> <code>macvlan0<\/code> -> <code>192.168.1.200:53<\/code><\/p>\n<p>Bu sayede, <code>systemd-resolved<\/code>'u devre d\u0131\u015f\u0131 b\u0131rakma veya <code>dnsmasq<\/code>'\u0131 standart olmayan bir portta \u00e7al\u0131\u015ft\u0131rma gibi karma\u015f\u0131k \u00e7\u00f6z\u00fcmlerden ka\u00e7\u0131nm\u0131\u015f olursunuz.<\/p>\n<h4>systemd-resolved'un Dinleyece\u011fi Portu De\u011fi\u015ftirme (alternatif)<\/h4>\n<p>E\u011fer <code>macvlan<\/code> kullanmak istemiyor ve <code>systemd-resolved<\/code>'un portunu de\u011fi\u015ftirmeyi tercih ediyorsan\u0131z, bu da bir se\u00e7enektir. <code>\/etc\/systemd\/resolved.conf<\/code> dosyas\u0131n\u0131 d\u00fczenleyerek <code>DNSStubListenerPort<\/code> ayar\u0131n\u0131 de\u011fi\u015ftirebilirsiniz:<\/p>\n<pre><code class=\"language-ini\">[Resolve]\nDNSStubListenerPort=5353 # Varsay\u0131lan 53 yerine 5353 dinle<\/pre>\n<p><\/code><br \/>\nArd\u0131ndan <code>sudo systemctl restart systemd-resolved<\/code> komutuyla servisi yeniden ba\u015flatman\u0131z gerekir. Bu durumda, <code>dnsmasq<\/code>'\u0131 ana IP adresinde 53 numaral\u0131 portta \u00e7al\u0131\u015ft\u0131rabilirsiniz. Ancak bu, <code>systemd-resolved<\/code>'a ba\u011f\u0131ml\u0131 uygulamalar\u0131n yap\u0131land\u0131rmas\u0131n\u0131 gerektirebilir. <code>macvlan<\/code> \u00e7\u00f6z\u00fcm\u00fc genellikle daha az yan etki yarat\u0131r.<\/p>\n<h3>Geli\u015fmi\u015f dnsmasq Yap\u0131land\u0131rmalar\u0131 ve En \u0130yi Uygulamalar<\/h3>\n<p><code>dnsmasq<\/code>'\u0131 temel bir DNS sunucusu olarak kurduktan sonra, performans\u0131n\u0131 ve i\u015flevselli\u011fini art\u0131rmak i\u00e7in baz\u0131 geli\u015fmi\u015f yap\u0131land\u0131rmalar yapabilirsiniz.<\/p>\n<h4>DNS \u00d6nbellekleme Optimizasyonu<\/h4>\n<p><code>dnsmasq<\/code> varsay\u0131lan olarak DNS sorgular\u0131n\u0131 \u00f6nbellekler. <code>cache-size<\/code> parametresiyle \u00f6nbelle\u011fin boyutunu ayarlayabilirsiniz. Daha b\u00fcy\u00fck bir \u00f6nbellek, daha fazla sorgunun yerel olarak yan\u0131tlanmas\u0131n\u0131 sa\u011flayarak gecikmeyi azalt\u0131r.<\/p>\n<pre><code class=\"language-ini\">cache-size=2048 # Varsay\u0131lan 150 yerine 2048 kay\u0131t \u00f6nbellekle<\/pre>\n<p><\/code><\/p>\n<h4>G\u00fcvenlik ve Eri\u015fim Kontrol\u00fc<\/h4>\n<p><code>dnsmasq<\/code>'\u0131n sadece belirli a\u011flardan gelen sorgular\u0131 kabul etmesini sa\u011flayarak g\u00fcvenli\u011fi art\u0131rabilirsiniz.<\/p>\n<pre><code class=\"language-ini\"># Sadece yerel a\u011fdan gelen sorgular\u0131 kabul et\n# (macvlan IP'si zaten listen-address ile belirtildi\u011fi i\u00e7in bu gereksiz olabilir ama ek g\u00fcvenlik sa\u011flar)\n# E\u011fer listen-address 0.0.0.0 olsayd\u0131 bu \u00f6nemli olurdu.\n# restrict-broadcast\n# no-resolv # \/etc\/resolv.conf dosyas\u0131n\u0131 kullanma\n# no-poll # \/etc\/resolv.conf dosyas\u0131n\u0131 periyodik olarak kontrol etme\n\n# Sadece belirli a\u011flardan gelen sorgulara izin ver\n# Bu, dnsmasq'\u0131n sadece 192.168.1.0\/24 a\u011f\u0131ndan gelen sorgular\u0131 yan\u0131tlamas\u0131n\u0131 sa\u011flar.\n# expand-hosts\n# local-service # Sadece yerel a\u011flardan gelen sorgular\u0131 yan\u0131tla<\/pre>\n<p><\/code><br \/>\n<code>local-service<\/code> parametresi, <code>dnsmasq<\/code>'\u0131n sadece yerel alt a\u011flardan gelen DNS sorgular\u0131n\u0131 yan\u0131tlamas\u0131n\u0131 sa\u011flar, bu da d\u0131\u015far\u0131dan gelebilecek k\u00f6t\u00fc niyetli sorgular\u0131 engeller.<\/p>\n<h4>Loglama ve Sorun Giderme<\/h4>\n<p>DNS sorgular\u0131n\u0131 ve DHCP olaylar\u0131n\u0131 loglamak, sorun giderme ve a\u011f analizi i\u00e7in \u00e7ok faydal\u0131d\u0131r.<\/p>\n<pre><code class=\"language-ini\"># DNS sorgular\u0131n\u0131 logla\nlog-queries\n\n# DHCP olaylar\u0131n\u0131 logla\nlog-dhcp\n\n# Loglar\u0131 ayr\u0131 bir dosyaya yaz\nlog-facility=\/var\/log\/dnsmasq.log<\/pre>\n<p><\/code><br \/>\nBu ayarlar, <code>dnsmasq<\/code>'\u0131n t\u00fcm DNS sorgular\u0131n\u0131 ve DHCP i\u015flemlerini belirtilen log dosyas\u0131na yazmas\u0131n\u0131 sa\u011flar.<\/p>\n<h4>systemd Servisi Olarak Y\u00f6netim<\/h4>\n<p><code>dnsmasq<\/code>'\u0131 <code>systemd<\/code> servisi olarak y\u00f6netmek, ba\u015flatma, durdurma, yeniden ba\u015flatma ve durum kontrol\u00fc gibi i\u015flemleri kolayla\u015ft\u0131r\u0131r. Kurulumdan sonra <code>dnsmasq<\/code> zaten bir <code>systemd<\/code> servisi olarak kaydedilmi\u015f olmal\u0131d\u0131r.<\/p>\n<pre><code class=\"language-bash\">sudo systemctl start dnsmasq       # Servisi ba\u015flat\nsudo systemctl stop dnsmasq        # Servisi durdur\nsudo systemctl restart dnsmasq     # Servisi yeniden ba\u015flat\nsudo systemctl status dnsmasq      # Servisin durumunu kontrol et\nsudo systemctl enable dnsmasq      # Sistem ba\u015flang\u0131c\u0131nda otomatik ba\u015flat\nsudo systemctl disable dnsmasq     # Sistem ba\u015flang\u0131c\u0131nda otomatik ba\u015flamay\u0131 engelle<\/pre>\n<p><\/code><br \/>\n<code>dnsmasq<\/code> yap\u0131land\u0131rma dosyas\u0131nda yapt\u0131\u011f\u0131n\u0131z her de\u011fi\u015fiklikten sonra servisi yeniden ba\u015flatmay\u0131 unutmay\u0131n.<\/p>\n<h3>Sonu\u00e7<\/h3>\n<p><code>dnsmasq<\/code>'\u0131 <code>macvlan<\/code> aray\u00fcz\u00fc ile ba\u011f\u0131ms\u0131z bir DNS sunucusu olarak \u00e7al\u0131\u015ft\u0131rmak, <code>systemd-resolved<\/code> ile ya\u015fanan port \u00e7ak\u0131\u015fmas\u0131 sorununa zarif ve etkili bir \u00e7\u00f6z\u00fcm sunar. Bu y\u00f6ntem sayesinde, sisteminizin varsay\u0131lan DNS \u00e7\u00f6z\u00fcmlemesini bozmadan, kendi \u00f6zel DNS sunucunuzu tam i\u015flevselli\u011fiyle kullanabilirsiniz. <code>macvlan<\/code>'\u0131n sa\u011flad\u0131\u011f\u0131 a\u011f izolasyonu, <code>dnsmasq<\/code>'\u0131n kendi \u00f6zel IP adresinde standart 53 numaral\u0131 portu dinlemesine olanak tan\u0131r, bu da onu a\u011fdaki di\u011fer cihazlar i\u00e7in kolayca eri\u015filebilir k\u0131lar. Bu yap\u0131land\u0131rma, ev a\u011flar\u0131nda \u00f6zel alan adlar\u0131, reklam engelleme veya geli\u015ftirme ortamlar\u0131nda esnek DNS y\u00f6netimi gibi bir\u00e7ok senaryo i\u00e7in ideal bir \u00e7\u00f6z\u00fcmd\u00fcr.<\/p>\n<h3>S\u0131k\u00e7a Sorulan Sorular (SSS)<\/h3>\n<h4>Neden do\u011frudan systemd-resolved'u devre d\u0131\u015f\u0131 b\u0131rakm\u0131yorum?<\/h4>\n<p><code>systemd-resolved<\/code>'u devre d\u0131\u015f\u0131 b\u0131rakmak, sistemin genel DNS \u00e7\u00f6z\u00fcmlemesini olumsuz etkileyebilir. Baz\u0131 uygulamalar ve servisler, <code>systemd-resolved<\/code>'un sa\u011flad\u0131\u011f\u0131 yerel DNS \u00f6nbellekleme ve DNSSEC do\u011frulama gibi \u00f6zelliklere ba\u011f\u0131ml\u0131 olabilir. <code>macvlan<\/code> \u00e7\u00f6z\u00fcm\u00fc, <code>systemd-resolved<\/code>'u oldu\u011fu gibi b\u0131rakarak sistem kararl\u0131l\u0131\u011f\u0131n\u0131 korurken, <code>dnsmasq<\/code>'\u0131 ayr\u0131 bir ortamda \u00e7al\u0131\u015ft\u0131rman\u0131za olanak tan\u0131r.<\/p>\n<h4>macvlan yerine ba\u015fka bir sanalla\u015ft\u0131rma \u00e7\u00f6z\u00fcm\u00fc kullanabilir miyim?<\/h4>\n<p>Evet, teorik olarak ba\u015fka sanalla\u015ft\u0131rma \u00e7\u00f6z\u00fcmleri de kullan\u0131labilir. \u00d6rne\u011fin, bir Docker konteyneri i\u00e7inde <code>dnsmasq<\/code>'\u0131 \u00e7al\u0131\u015ft\u0131r\u0131p konteynere ayr\u0131 bir IP adresi atayabilirsiniz. Ancak <code>macvlan<\/code>, do\u011frudan Linux \u00e7ekirde\u011fi seviyesinde \u00e7al\u0131\u015ft\u0131\u011f\u0131 i\u00e7in daha hafif ve performansl\u0131 bir \u00e7\u00f6z\u00fcm sunar, \u00f6zellikle sadece bir IP adresi izolasyonu gerekti\u011finde.<\/p>\n<h4>dnsmasq ile DHCP sunucusu da \u00e7al\u0131\u015ft\u0131rabilir miyim?<\/h4>\n<p>Evet, <code>dnsmasq<\/code> \u00e7ok yetenekli bir DHCP sunucusudur. <code>dhcp-range<\/code> ve <code>dhcp-option<\/code> gibi parametrelerle kolayca yap\u0131land\u0131r\u0131labilir. Ancak, a\u011f\u0131n\u0131zda zaten ba\u015fka bir DHCP sunucusu (\u00f6rne\u011fin modeminiz) \u00e7al\u0131\u015f\u0131yorsa, \u00e7ak\u0131\u015fmalar\u0131 \u00f6nlemek i\u00e7in <code>dnsmasq<\/code>'\u0131n DHCP \u00f6zelli\u011fini devre d\u0131\u015f\u0131 b\u0131rakman\u0131z veya mevcut DHCP sunucusunu kapatman\u0131z gerekir.<\/p>\n<h4>Performans a\u00e7\u0131s\u0131ndan macvlan'\u0131n bir etkisi var m\u0131?<\/h4>\n<p><code>macvlan<\/code>, Linux \u00e7ekirde\u011fi seviyesinde uygulanan hafif bir sanalla\u015ft\u0131rma teknolojisidir. Genellikle performansa ihmal edilebilir bir etkisi vard\u0131r. A\u011f trafi\u011fi do\u011frudan ana aray\u00fcz \u00fczerinden y\u00f6nlendirildi\u011fi i\u00e7in, ek bir sanalla\u015ft\u0131rma katman\u0131n\u0131n getirdi\u011fi belirgin bir gecikme veya performans d\u00fc\u015f\u00fc\u015f\u00fc ya\u015fanmaz. <code>dnsmasq<\/code>'\u0131n kendisi de \u00e7ok d\u00fc\u015f\u00fck kaynak t\u00fcketimine sahip bir uygulamad\u0131r.<\/p>\n","protected":false},"excerpt":{"rendered":"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme\nModern Linux da\u011f\u0131t\u0131mlar\u0131nda a\u011f &#8230;","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"csco_page_header_type":"","csco_page_load_nextpost":"","csco_page_subscribe_form":"","csco_page_contact_form":"","footnotes":""},"categories":[1],"tags":[],"class_list":{"0":"post-37953","1":"post","2":"type-post","3":"status-publish","4":"format-standard","6":"category-genel","7":"cs-entry","8":"cs-video-wrap"},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v20.5 (Yoast SEO v25.3.1) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>dnsmasq&#039;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme - Kodlar\u0131n Gizemli D\u00fcnyas\u0131<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\" \/>\n<meta property=\"og:locale\" content=\"tr_TR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"dnsmasq&#039;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme\" \/>\n<meta property=\"og:description\" content=\"dnsmasq&#039;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme Modern Linux da\u011f\u0131t\u0131mlar\u0131nda a\u011f ...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\" \/>\n<meta property=\"og:site_name\" content=\"Kodlar\u0131n Gizemli D\u00fcnyas\u0131\" \/>\n<meta property=\"article:published_time\" content=\"2026-01-19T11:31:15+00:00\" \/>\n<meta name=\"author\" content=\"Fatih Soysal\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Yazan:\" \/>\n\t<meta name=\"twitter:data1\" content=\"Fatih Soysal\" \/>\n\t<meta name=\"twitter:label2\" content=\"Tahmini okuma s\u00fcresi\" \/>\n\t<meta name=\"twitter:data2\" content=\"17 dakika\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\"},\"author\":{\"name\":\"Fatih Soysal\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"headline\":\"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme\",\"datePublished\":\"2026-01-19T11:31:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\"},\"wordCount\":2600,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#respond\"]}],\"copyrightYear\":\"2026\",\"copyrightHolder\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\",\"name\":\"dnsmasq'\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme - Kodlar\u0131n Gizemli D\u00fcnyas\u0131\",\"isPartOf\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#website\"},\"datePublished\":\"2026-01-19T11:31:15+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#breadcrumb\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Anasayfa\",\"item\":\"https:\/\/fatihsoysal.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#website\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/\",\"name\":\"Fatihsoysal.com\",\"description\":\"Blog - Yaz\u0131l\u0131m D\u00fcnyas\u0131 Tecr\u00fcbelerim\",\"publisher\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/fatihsoysal.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"tr\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\",\"name\":\"Fatih Soysal\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"tr\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png\",\"contentUrl\":\"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png\",\"width\":512,\"height\":512,\"caption\":\"Fatih Soysal\"},\"logo\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/\"},\"description\":\"Kullan\u0131m ve kodlama m\u00fckemmeliyetini odak alan uygulamalar olu\u015fturma deneyimine sahip, profesyonel olarak 15+ y\u0131l \u00fczeri deneyime sahip bir yaz\u0131l\u0131m m\u00fchendisi.\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/author\/fatihsoysal\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"dnsmasq'\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme - Kodlar\u0131n Gizemli D\u00fcnyas\u0131","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/","og_locale":"tr_TR","og_type":"article","og_title":"dnsmasq'\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme","og_description":"dnsmasq'\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme Modern Linux da\u011f\u0131t\u0131mlar\u0131nda a\u011f ...","og_url":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/","og_site_name":"Kodlar\u0131n Gizemli D\u00fcnyas\u0131","article_published_time":"2026-01-19T11:31:15+00:00","author":"Fatih Soysal","twitter_card":"summary_large_image","twitter_misc":{"Yazan:":"Fatih Soysal","Tahmini okuma s\u00fcresi":"17 dakika"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#article","isPartOf":{"@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/"},"author":{"name":"Fatih Soysal","@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"headline":"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme","datePublished":"2026-01-19T11:31:15+00:00","mainEntityOfPage":{"@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/"},"wordCount":2600,"commentCount":0,"publisher":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"inLanguage":"tr","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#respond"]}],"copyrightYear":"2026","copyrightHolder":{"@id":"https:\/\/fatihsoysal.com\/blog\/#organization"}},{"@type":"WebPage","@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/","url":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/","name":"dnsmasq'\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme - Kodlar\u0131n Gizemli D\u00fcnyas\u0131","isPartOf":{"@id":"https:\/\/fatihsoysal.com\/blog\/#website"},"datePublished":"2026-01-19T11:31:15+00:00","breadcrumb":{"@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#breadcrumb"},"inLanguage":"tr","potentialAction":[{"@type":"ReadAction","target":["https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/fatihsoysal.com\/blog\/dnsmasqi-macvlan-ile-bagimsiz-bir-dns-sunucusu-olarak-calistirmak-systemd-resolved-cakismalarini-onleme\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Anasayfa","item":"https:\/\/fatihsoysal.com\/blog\/"},{"@type":"ListItem","position":2,"name":"dnsmasq&#8217;\u0131 macvlan ile Ba\u011f\u0131ms\u0131z Bir DNS Sunucusu Olarak \u00c7al\u0131\u015ft\u0131rmak: systemd-resolved \u00c7ak\u0131\u015fmalar\u0131n\u0131 \u00d6nleme"}]},{"@type":"WebSite","@id":"https:\/\/fatihsoysal.com\/blog\/#website","url":"https:\/\/fatihsoysal.com\/blog\/","name":"Fatihsoysal.com","description":"Blog - Yaz\u0131l\u0131m D\u00fcnyas\u0131 Tecr\u00fcbelerim","publisher":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/fatihsoysal.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"tr"},{"@type":["Person","Organization"],"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1","name":"Fatih Soysal","image":{"@type":"ImageObject","inLanguage":"tr","@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png","contentUrl":"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png","width":512,"height":512,"caption":"Fatih Soysal"},"logo":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/"},"description":"Kullan\u0131m ve kodlama m\u00fckemmeliyetini odak alan uygulamalar olu\u015fturma deneyimine sahip, profesyonel olarak 15+ y\u0131l \u00fczeri deneyime sahip bir yaz\u0131l\u0131m m\u00fchendisi.","url":"https:\/\/fatihsoysal.com\/blog\/author\/fatihsoysal\/"}]}},"yoast_meta":{"yoast_wpseo_title":"","yoast_wpseo_metadesc":"","yoast_wpseo_canonical":""},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts\/37953","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/comments?post=37953"}],"version-history":[{"count":0,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts\/37953\/revisions"}],"wp:attachment":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/media?parent=37953"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/categories?post=37953"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/tags?post=37953"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}