1 / 23

Zone transfer and dns -express

Zone transfer and dns -express. Jing Lin 2011.9.19 V1.0. Zone transfer. Slave name server pull zone files from master name server There are two types of zone transfer, AXFR and IXFR AXFR means full zones transfer IXFR means incremental transfer. Zone transfer.

debbie
Télécharger la présentation

Zone transfer and dns -express

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Zone transfer and dns-express Jing Lin 2011.9.19 V1.0

  2. Zone transfer • Slave name server pull zone files from master name server • There are two types of zone transfer, AXFR and IXFR • AXFR means full zones transfer • IXFR means incremental transfer

  3. Zone transfer • An initial slave name server starts up, it will request AXFR to master server. • After the first transfer finished, slave server will check if there is update on master server by send IXFR, the checking interval is according the refresh value of SOA. It will change to AXFR if the master does not support IXFR. • The default bind behavior supports AXFR and IXFR.

  4. notify • To make slave server knows update from master asap, master server will send out notify to all slave servers, default, master will only send notify message to all slave servers that are defined in zone file. • “Also-notify {ip port}” statement will let master server aslo send notify to those servers in addition to slave server which in zone. • If slave server get a notify, it will send a soa query to master server, and compare serial number to himself, if the master server’s serial number greater than self, slave server will starts IXFR, if IXFR is failed, will use AXFR.

  5. Master • Master server: • zone "cnadn.net" { • type master; • allow-transfer {192.168.209.72;192.168.209.188;}; • //file "/etc/bind/db.cnadn.net.signed"; • file "/etc/bind/db.cnadn.net"; • }; • BIND default allow all host to run AXFR to him, need be careful on this.

  6. slave • zone "cnadn.net" { • type slave; • masters {192.168.209.71;}; • //file "/etc/bind/db.cnadn.net.signed"; • file "slave.db.cnadn.net"; • };

  7. DNS Express

  8. GTM DNS express • Pull dns into memory. Respond answer from RAM directly, this will improve performance significantly. • It is a LTM function, not only for GTM module. • Support all kinds of RR type but AXFR and IXFR, which means you cant run AXFR/IXFR to dns express • Support TSIG, and support to be notified. • DO NOT support view. • Support ipv6 and tcp/udp/ • Support dnssec??? (Should be, will verify it in another ppt)

  9. How dns express works • It lives in TMM actually • Zxfrd which a new process in v11 control zxfrd.bin file. • TMM reads a binary db file from /var/db/tmmdns.bin • When update happens, zxrfd.bin will be updated first, then some times later tmmdns.bin will be wrote by zxfrd. • At last these 2 files should be same

  10. How dns express works

  11. Zxfrd state transitions

  12. Dns request match rule • When bigip receives a dns request: • 1. If it matches a wideip (gtm module), if yes, follow wideip configuration to answer the request.If no, go to step 2 • 2.Check if matches dns express zone, if yes, tmm respond answer from dns express zone directly. If no, go to step 3. • 3. Check the listener vs, decide if the request need to be sent to backend dns server (pool member)

  13. DNS express troubleshooting • Check /var/log/ltm, grep logs of zxfrd • Check zxfrd process status with bigstart status zxfrd • Zxfrd listen on ::1:5353 • Zone transfer uses tcp:53

  14. Sample logs • When master refuse bigip’saxfr/ixfr: • Sep 18 10:46:31 ltm6900-1 err zxfrd[6393]: 01531010:3: Transfer of zone cnadn.net failed b/c there are no records. • Sep 18 10:46:31 ltm6900-1 err zxfrd[6393]: 01531015:3: Failed to retrieve next RR in XFR for zone cnadn.net. • Sep 18 10:46:31 ltm6900-1 err zxfrd[6393]: 01531018:3: Failed to transfer zone cnadn.net from 192.168.209.71, will attempt AXFR. • Sep 18 10:46:31 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 5s for cnadn.net from 192.168.209.71. • Sep 18 10:46:36 ltm6900-1 err zxfrd[6393]: 01531010:3: Transfer of zone cnadn.net failed b/c there are no records. • Sep 18 10:46:36 ltm6900-1 err zxfrd[6393]: 01531015:3: Failed to retrieve next RR in XFR for zone cnadn.net. • Sep 18 10:46:36 ltm6900-1 err zxfrd[6393]: 01531018:3: Failed to transfer zone cnadn.net from 192.168.209.71, will attempt AXFR. • Sep 18 10:46:36 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 5s for cnadn.net from 192.168.209.71.

  15. Sample logs-continue • After the master allow bigip transfer: • Sep 18 10:47:06 ltm6900-1 notice zxfrd[6393]: 0153101f:5: AXFR Transfer of zone cnadn.net from 192.168.209.71 succeeded. • Sep 18 10:47:06 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 180s for cnadn.net from 192.168.209.71. • Regular checking with soa-refresh time interval: • Sep 18 10:56:06 ltm6900-1 notice zxfrd[6393]: 01531025:5: Serials equal (2011091901); transfer for zone cnadn.net complete. • Sep 18 10:56:06 ltm6900-1 debug zxfrd[6393]: 01531008:7: Resetting transfer state for zone cnadn.net. • Sep 18 10:56:06 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 180s for cnadn.net from 192.168.209.71.

  16. Sample logs-continue • When bigip finds the master’s serial number is greater: • Sep 18 11:05:06 ltm6900-1 debug zxfrd[6393]: 01531206:7: Cleared zone cnadn.net from db. • Sep 18 11:05:06 ltm6900-1 notice zxfrd[6393]: 0153101f:5: AXFR Transfer of zone cnadn.net from 192.168.209.71 succeeded. • Sep 18 11:05:06 ltm6900-1 debug zxfrd[6393]: 01531203:7: Scheduling DB dump with zone cnadn.net. • Sep 18 11:05:06 ltm6900-1 debug zxfrd[6393]: 01531008:7: Resetting transfer state for zone cnadn.net. • Sep 18 11:05:06 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 180s for cnadn.net from 192.168.209.71.

  17. Sample logs-continue • When receive notify message: • Sep 18 11:21:23 ltm6900-1 notice zxfrd[6393]: 0153101c:5: Handling NOTIFY for zone cnadn.net. • Sep 18 11:21:23 ltm6900-1 debug zxfrd[6393]: 01531008:7: Resetting transfer state for zone cnadn.net. • Sep 18 11:21:23 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 5s for cnadn.net from 192.168.209.71. • Sep 18 11:21:28 ltm6900-1 debug zxfrd[6393]: 01531206:7: Cleared zone cnadn.net from db. • Sep 18 11:21:28 ltm6900-1 notice zxfrd[6393]: 0153101f:5: AXFR Transfer of zone cnadn.net from 192.168.209.71 succeeded. • Sep 18 11:21:28 ltm6900-1 debug zxfrd[6393]: 01531203:7: Scheduling DB dump with zone cnadn.net. • Sep 18 11:21:28 ltm6900-1 debug zxfrd[6393]: 01531008:7: Resetting transfer state for zone cnadn.net. • Sep 18 11:21:28 ltm6900-1 notice zxfrd[6393]: 01531023:5: Scheduling zone transfer in 60s for cnadn.net from 192.168.209.71.

  18. Verify dns-express status • Check statistics of the dns-express zone from GUI, set data format as unformatted. • Check dns-express zone color, it should be green. • Tmsh show ltmdnsdns-express

  19. Dump dns-express to a file • Run below command, will show result on terminal. • dnsxdump

  20. Debug zxfrd • Trun on zxfrd debug • tmsh modify sys dblog.zxfrd.level value debug • (defautl is notice) • Output will be in /var/tmp/zxfrd.out

  21. How to configdns-express • Create a dns profile and enable dns-express from LTM menu. • Create a gtm listener or dns-vs and associate it with the dns profile • Create a dns-express zone: • Target ip is the master server, if using TSIG, select a TSIG KEY for the zone. • Notify , keep as consume.

More Related