<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>I just found that one of my systems that uses systemd-networkd<br>
      did not have DNS setup.</p>
    <p>Below is the all the commands I ran to debug this problem that
      showed up<br>
      after the system was dnf updated and rebooted.<br>
    </p>
    <p>This is what I found:</p>
    <p>$ host google.com<br>
      Host google.com not found: 2(SERVFAIL)<br>
    </p>
    <p><span style="font-family:monospace">$ more /etc/resolv.conf <br>
        # This is /run/systemd/resolve/stub-resolv.conf managed by
        <a class="moz-txt-link-freetext" href="man:systemd-resolved(8)">man:systemd-resolved(8)</a>.<br>
        # <snip><br>
        nameserver 127.0.0.53<br>
        options edns0 trust-ad<br>
        search .<br>
      </span></p>
    <p><span style="font-family:monospace">$ resolvectl <br>
        Global<br>
               Protocols: LLMNR=resolve -mDNS -DNSOverTLS
        DNSSEC=no/unsupported<br>
        resolv.conf mode: stub<br>
        <br>
        Link 2 (internal)<br>
        Current Scopes: LLMNR/IPv4 LLMNR/IPv6<br>
             Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS
        DNSSEC=no/unsupported</span></p>
    <p><span style="font-family:monospace"><br>
      </span></p>
    <p><span style="font-family:monospace">DNS will not work - next to
        figure out why resolved is not setup.</span></p>
    <p><span style="font-family:monospace">$ ip addr<br>
        1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue
        state UNKNOWN group default qlen 1000<br>
            link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00<br>
            inet 127.0.0.1/8 scope host lo<br>
               valid_lft forever preferred_lft forever<br>
            inet6 ::1/128 scope host <br>
               valid_lft forever preferred_lft forever<br>
        2: internal: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500
        qdisc mq state UP group default qlen 1000<br>
            link/ether ac:1f:6b:f6:e0:94 brd ff:ff:ff:ff:ff:ff<br>
            inet 172.16.2.200/24 brd 172.16.2.255 scope global internal<br>
               valid_lft forever preferred_lft forever<br>
            inet6 fe80::ae1f:6bff:fef6:e094/64 scope link <br>
               valid_lft forever preferred_lft forever<br>
      </span></p>
    <p><span style="font-family:monospace"><br>
      </span></p>
    <p><span style="font-family:monospace">$ more 10-internal.link <br>
        [Link]<br>
        Description=Set internal ethernet interface name<br>
        <br>
        Name=internal<br>
        <br>
        [Match]<br>
        # eno1<br>
        MACAddress=ac:1f:6b:f6:e0:94</span></p>
    <p><span style="font-family:monospace">$ more internal-if.network<br>
        [Match]<br>
        Name=internal<br>
        <br>
        [Network]<br>
        Description=Internal network<br>
        Address=172.16.2.200/24<br>
        Gateway=172.16.2.254<br>
        DNS=172.16.2.254<br>
        Domains=chelsea.private</span></p>
    <p><span style="font-family:monospace">$ networkctl <br>
        IDX LINK     TYPE     OPERATIONAL SETUP      <br>
          1 lo       loopback carrier     unmanaged<br>
          2 internal ether    routable    configuring<br>
      </span></p>
    <p><span style="font-family:monospace">Odd - configuring!</span></p>
    <p><span style="font-family:monospace">$ networkctl status<br>
        ●          State: routable                             <br>
            Online state: online                               <br>
                 Address: 172.16.2.200 on internal<br>
                          fe80::ae1f:6bff:fef6:e094 on internal<br>
                 Gateway: 172.16.2.254 on internal<br>
                     DNS: 172.16.2.254<br>
          Search Domains: chelsea.private<br>
        <br>
        Mar 18 09:20:41 fender.chelsea.private systemd-networkd[573]:
        internal: Gained IPv6LL<br>
        Mar 21 08:50:15 fender.chelsea.private systemd[1]: Starting
        systemd-networkd.service - Network Configuration...<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        internal: Link UP<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        internal: Gained carrier<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        lo: Link UP<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        lo: Gained carrier<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        internal: Gained IPv6LL<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        Enumeration completed<br>
        Mar 21 08:50:15 fender.chelsea.private systemd[1]: Started
        systemd-networkd.service - Network Configuration.<br>
        Mar 21 08:50:15 fender.chelsea.private systemd-networkd[63749]:
        internal: Configuring with
        /etc/systemd/network/internal-if.network.<br>
      </span></p>
    <p><span style="font-family:monospace">$ networkctl status internal<br>
        ● 2:
        internal                                                                
         <br>
                             Link File:
        /etc/systemd/network/10-internal.link<br>
                          Network File:
        /etc/systemd/network/internal-if.network<br>
                                  Type: ether<br>
                                  Kind: n/a<br>
                                 State: routable (configured)<br>
                          Online state:
        online                                         <br>
                                  Path: pci-0000:01:00.0<br>
                                Driver: igb<br>
                                Vendor: Intel Corporation<br>
                                 Model: I210 Gigabit Network Connection<br>
                      Hardware Address: ac:1f:6b:f6:e0:94 (Super Micro
        Computer, Inc.)<br>
                                   MTU: 1500 (min: 68, max: 9216)<br>
                                 QDisc: mq<br>
          IPv6 Address Generation Mode: eui64<br>
              Number of Queues (Tx/Rx): 8/8<br>
                      Auto negotiation: yes<br>
                                 Speed: 1Gbps<br>
                                Duplex: full<br>
                                  Port: tp<br>
                               Address: 172.16.2.200<br>
                                        fe80::ae1f:6bff:fef6:e094<br>
                               Gateway: 172.16.2.254<br>
                                   DNS: 172.16.2.254<br>
                        Search Domains: chelsea.private<br>
                     Activation Policy: up<br>
      </span></p>
    <p><span style="font-family:monospace">$ resolvectl <br>
        Global<br>
               Protocols: LLMNR=resolve -mDNS -DNSOverTLS
        DNSSEC=no/unsupported<br>
        resolv.conf mode: stub<br>
        <br>
        Link 2 (internal)<br>
            Current Scopes: DNS LLMNR/IPv4 LLMNR/IPv6<br>
                 Protocols: +DefaultRoute +LLMNR -mDNS -DNSOverTLS
        DNSSEC=no/unsupported<br>
        Current DNS Server: 172.16.2.254<br>
               DNS Servers: 172.16.2.254<br>
                DNS Domain: chelsea.private<br>
      </span></p>
    <p><span style="font-family:monospace">What?!?!? Configured!</span></p>
    <p><span style="font-family:monospace">$ networkctl <br>
        IDX LINK     TYPE     OPERATIONAL SETUP     <br>
          1 lo       loopback carrier     unmanaged<br>
          2 internal ether    routable    configured</span></p>
    <p><span style="font-family:monospace">Now configured!</span></p>
    <p><span style="font-family:monospace">So after 3 days of being
        stuck in configured it working now<br>
        that I run only the above commands. One of the status commands<br>
        unstuck networkd?</span></p>
    <p><span style="font-family:monospace">The last event on the system
        was a dns update 2023-03-18 that includes these packages:<br>
      </span></p>
    <p><span style="font-family:monospace">---> Package
        systemd.x86_64 251.13-5.fc37 will be upgraded<br>
        ---> Package systemd.x86_64 251.13-6.fc37 will be an upgrade<br>
        ---> Package systemd-boot-unsigned.x86_64 251.13-5.fc37 will
        be upgraded<br>
        ---> Package systemd-boot-unsigned.x86_64 251.13-6.fc37 will
        be an upgrade<br>
        ---> Package systemd-libs.x86_64 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-libs.x86_64 251.13-6.fc37 will be an
        upgrade<br>
        ---> Package systemd-networkd.x86_64 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-networkd.x86_64 251.13-6.fc37 will be an
        upgrade<br>
        ---> Package systemd-oomd-defaults.noarch 251.13-5.fc37 will
        be upgraded<br>
        ---> Package systemd-oomd-defaults.noarch 251.13-6.fc37 will
        be an upgrade<br>
        ---> Package systemd-pam.x86_64 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-pam.x86_64 251.13-6.fc37 will be an
        upgrade<br>
        ---> Package systemd-resolved.x86_64 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-resolved.x86_64 251.13-6.fc37 will be an
        upgrade<br>
        ---> Package systemd-rpm-macros.noarch 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-rpm-macros.noarch 251.13-6.fc37 will be
        an upgrade<br>
        ---> Package systemd-udev.x86_64 251.13-5.fc37 will be
        upgraded<br>
        ---> Package systemd-udev.x86_64 251.13-6.fc37 will be an
        upgrade<br>
      </span></p>
    <p><span style="font-family:monospace">Why was the interface stuck
        in configuring?</span></p>
    <p><span style="font-family:monospace">Barry</span></p>
    <p><span style="font-family:monospace"><br>
      </span><span style="font-family:monospace"></span></p>
  </body>
</html>