Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
content:serverbasics:network-dyndns [2024/01/01 13:25] – angelegt Daniel | content:serverbasics:network-dyndns [2025/02/16 10:42] (aktuell) – [Settings] Daniel | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
====== DynDNS and IPv6 ====== | ====== DynDNS and IPv6 ====== | ||
- | as i have been struggeling for a bit to get IPv6 Working, i am writing down, what i have experienced so far.. this guid may not be complete, so expect things not to work. | + | I found out, that IPv6 is really nice - even if you are behind some firewall or router - as long as you can make them pass the packets |
===== Difference between IPv4 and IPv6 ===== | ===== Difference between IPv4 and IPv6 ===== | ||
- | Also IPv6 is qiute old (released in 1998), it is still not very common as its setup is a bit different. | + | Also IPv6 is quite old (released in 1998), it is still not very common as its setup is a bit different |
- | IPv4 works with NAT, which means, that the Firewall/ | + | IPv4 works with NAT, which means, that the Firewall/ |
- | IPv6 has no NAT. Instead them Modem gets an adress Range, called | + | IPv6 instead, |
- | So basically every Host in the local Network | + | These Device- Adresses are globally unique (GUAs) and are routable over the Internet. |
- | ===== Ddclient ===== | + | So basically every Host in the local Network can be reached from the Internet with ist GUA IPv6 Adress. Its the Modems Firewall, which will prevent exposing all Hosts of the local network directly to the Internet. Thus, the only thing you have to do, is to open the Ports for some Device, which the Firewall will allow to pass from the internet to the local network directly. |
- | DDClient can be used in the local server/host to assign some DNS- Record to an IP. It turned out, that the DDclient V3.8.3 of OpenSuSE Leap 15.5 was not able to work with IPv6 in the Version coming from the main Repositories. | + | ===== Problems |
- | Add the Repository https:// | + | I experienced, |
+ | |||
+ | ==== Problematic Brands ==== | ||
+ | |||
+ | For example, the German Telekom does have a modem / router called " | ||
+ | |||
+ | So - if you did the settings at your Firewall and still you cannot curl some Adress, maybe you have the wrong modem. | ||
+ | |||
+ | ==== Settings ==== | ||
+ | |||
+ | Also check if your modem has some feature called " | ||
+ | |||
+ | e.g. add the fqdn like: | ||
+ | |||
+ | < | ||
+ | cname.domainname.dynv6.net | ||
+ | |||
+ | </ | ||
+ | |||
+ | How the rebind protection work: DNS queries to your Router won't return the IP of the service. So if you experience, that '' | ||
+ | |||
+ | |||
+ | ===== Modem Setup ===== | ||
+ | |||
+ | For IPv4 you would need to setup the Modem to have the DynDNS Record updated - as the Modem knows its own IP best and is the central Point of action. | ||
+ | |||
+ | Not so with IPv6. The Modems IPv6- Adress is irrelevant for your internal Hosts and for the Internet. As the IPv6 adress is assigned to the Device at connection establishment, | ||
+ | |||
+ | So you can skip setting up the dyndns- Account in your Modem/ | ||
+ | |||
+ | ==== Firewall ==== | ||
+ | |||
+ | There is one thing to do in your router: open the Device and the Port to be accessable from the internet. This is nearby the same as it is done at IPv4. After that, genereally the host shpuld be reachable. | ||
+ | |||
+ | ===== Security/ | ||
+ | |||
+ | By default, your IPv6 Adress will contain the MAC of your network card, which is an unique hardware- identifier of the chip. This has the advantage, that this part of your adress is fixed in the internet an will not change, so you can always reach your device anywhere knowing this adress part - even on mobile devices that may change the adress according to the connected network. | ||
+ | |||
+ | The opposite is, that your device can always be identified by that adress for all times - making all network traffic attached to the device directly belonging to it. So someone analysing the traffic of that adress would know exactly when and what has been done with that device. This is very poor as for privacy. | ||
+ | |||
+ | To avoid this, your device can generate an id that will change from time to time, making it impossible to identify the device with that adress. | ||
+ | |||
+ | To turn this on, you can add a line to ''/ | ||
+ | < | ||
+ | sudo sysctl net.ipv6.conf.wlan0.use_tempaddr=2 | ||
+ | |||
+ | </ | ||
+ | |||
+ | Replace wlan0 with the name of your Device. | ||
+ | |||
+ | After that, check if your device has an temporary adress with '' | ||
+ | |||
+ | *** Not finished - i have not found any docs at ddclient, how to get the interface temporary adress working, made up [[https:// | ||
+ | For the time beeing, i will be fine using the non- private adress. | ||
+ | |||
+ | ===== DynDNS Provider ===== | ||
+ | |||
+ | Next Step to choose is a provider for dyndns. There are many dyndns- providers out there - even free of charge. E.g. [[https:// | ||
+ | |||
+ | The opposite of those free registries is, that you can only use a subdomain of the Top-Level domain they offer, which makes your Domain Name fixed at the end. For me personally, i have bought a domain on my own in the tld of my country (costs about 15 Euro in one Year), which i can now use. | ||
+ | |||
+ | ===== Register Subdomains ===== | ||
+ | |||
+ | After you logged into your DynDNS Provider, enable dynDNS for your IPs and add subdomains - each one for one service. If you want to acces your Portainer you created when setting up docker, e.g. use a Subdomain called | ||
+ | |||
+ | portainer.domain.tld | ||
+ | |||
+ | Make sure, that DynDNS is selected for that record again! | ||
+ | |||
+ | ===== DDclient ===== | ||
+ | |||
+ | The Task to update the dyndns- entry to point to the right host can be done best on the host itself as explained before. The Host may detect interface- changes of the Adress and will push out automagically using some client. | ||
+ | |||
+ | DDClient can be used in the local server/host to assign some DNS- Record to an IP. It turned out, that the **DDclient V3.8.3 of OpenSuSE Leap 15.5** was not able to work with IPv6 in the Version coming from the main Repositories. | ||
+ | |||
+ | Add the Repository | ||
The config is in ''/ | The config is in ''/ | ||
< | < | ||
+ | |||
#01.01.2023 dnydns test | #01.01.2023 dnydns test | ||
ssl=yes, | ssl=yes, | ||
Zeile 31: | Zeile 107: | ||
</ | </ | ||
+ | |||
+ | Notes: | ||
+ | |||
+ | * Not using SSL will not work | ||
+ | * DDClients Config is a bit strange to understand. My example is **one server **in the view of ddclient, which is why there are commas seperating the options for that host. | ||
+ | * You can also specify each option without comma, but then the setting will change the **defaults** | ||
+ | |||
+ | ==== Debugging ==== | ||
+ | |||
+ | If something is not working, execute ddclient that way: | ||
+ | |||
+ | '' | ||
+ | |||
+ | ==== Enable the service ==== | ||
+ | |||
+ | If your IP has been sucessfully updated, enable the service: | ||
+ | |||
+ | '' | ||
+ | |||
+ | ==== Check the Connection ==== | ||
+ | |||
+ | you may now have the IPv6 of your Device published at some adress and check this by digging at googles DNS for that IPV6: | ||
+ | |||
+ | < | ||
+ | pcserver2023: | ||
+ | |||
+ | ; <<>> | ||
+ | ; (1 server found) | ||
+ | ;; global options: +cmd | ||
+ | ;; Got answer: | ||
+ | ;; ->> | ||
+ | ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1 | ||
+ | |||
+ | ;; OPT PSEUDOSECTION: | ||
+ | ; EDNS: version: 0, flags:; udp: 512 | ||
+ | ;; QUESTION SECTION: | ||
+ | ; | ||
+ | |||
+ | ;; ANSWER SECTION: | ||
+ | ipa.obel1x.de. | ||
+ | |||
+ | ;; Query time: 44 msec | ||
+ | ;; SERVER: 8.8.8.8# | ||
+ | ;; WHEN: Sat Feb 08 12:49:12 CET 2025 | ||
+ | ;; MSG SIZE rcvd: 70 | ||
+ | |||
+ | </ | ||
+ | |||
+ | Thats it, you shold be able to get some connection. Mind, that IPv6- Adresses in URLs are written in brakets to have ports seperated: | ||
+ | |||
+ | < | ||
+ | protocol:// | ||
+ | |||
+ | </ | ||