ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Fedora name resolution

    IT Discussion
    5
    28
    1.8k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • ObsolesceO
      Obsolesce
      last edited by

      is it a .local domain?

      siringoS 1 Reply Last reply Reply Quote 1
      • scottalanmillerS
        scottalanmiller
        last edited by

        Welcome to Linux.

        Are you maybe not using DHCP?

        siringoS 1 Reply Last reply Reply Quote 0
        • scottalanmillerS
          scottalanmiller
          last edited by

          Same command as on Windows...

          nslookup sitename
          

          That'll tell us what it is "doing."

          siringoS 1 Reply Last reply Reply Quote 0
          • ObsolesceO
            Obsolesce
            last edited by Obsolesce

            If it's a .local domain, edit the avahi-daemon.conf file:

            Un-comment the following line, and add a . (dot) infront of local:

            domain-name=.local

            Then restart network or reboot.

            black3dynamiteB 1 Reply Last reply Reply Quote 1
            • siringoS
              siringo @Obsolesce
              last edited by

              @obsolesce said in Fedora name resolution:

              is it a .local domain?

              No, I nuked that localhost.localdomain and changed it to just a hostname, hpfed.

              1 Reply Last reply Reply Quote 0
              • siringoS
                siringo @scottalanmiller
                last edited by

                @scottalanmiller said in Fedora name resolution:

                Welcome to Linux.

                Are you maybe not using DHCP?

                No I'm using DHCP.

                1 Reply Last reply Reply Quote 0
                • black3dynamiteB
                  black3dynamite @Obsolesce
                  last edited by

                  @obsolesce said in Fedora name resolution:

                  If it's a .local domain, edit the avahi-daemon.conf file:

                  Un-comment the following line, and add a . (dot) infront of local:

                  domain-name=.local

                  Then restart network or reboot.

                  Why not edit /etc/nsswitch.conf instead?
                  https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                  Change...
                  hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                  To...
                  hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                  ObsolesceO 2 Replies Last reply Reply Quote 0
                  • siringoS
                    siringo @scottalanmiller
                    last edited by

                    @scottalanmiller said in Fedora name resolution:

                    Same command as on Windows...

                    nslookup sitename
                    

                    That'll tell us what it is "doing."

                    If I go "nslookup hostname" I get told that there is no entry for 'hostname' in DNS which looks correct.

                    scottalanmillerS 1 Reply Last reply Reply Quote 0
                    • scottalanmillerS
                      scottalanmiller
                      last edited by

                      Your DNS settings are kept in a file called /etc/resolv.conf, you'll want it to look something like this...

                      nameserver 1.1.1.1
                      nameserver 1.0.0.1
                      
                      ObsolesceO 1 Reply Last reply Reply Quote 1
                      • ObsolesceO
                        Obsolesce @black3dynamite
                        last edited by

                        @black3dynamite said in Fedora name resolution:

                        @obsolesce said in Fedora name resolution:

                        If it's a .local domain, edit the avahi-daemon.conf file:

                        Un-comment the following line, and add a . (dot) infront of local:

                        domain-name=.local

                        Then restart network or reboot.

                        Why not edit /etc/nsswitch.conf instead?
                        https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                        Change...
                        hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                        To...
                        hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                        I wasn't aware of that option.

                        Can you tell me why one solution is better than the other or why one is worse than the other?

                        stacksofplatesS black3dynamiteB 2 Replies Last reply Reply Quote 0
                        • ObsolesceO
                          Obsolesce @scottalanmiller
                          last edited by

                          @scottalanmiller said in Fedora name resolution:

                          Your DNS settings are kept in a file called /etc/resolv.conf, you'll want it to look something like this...

                          nameserver 1.1.1.1
                          nameserver 1.0.0.1
                          

                          If he has to do that something is wrong. Otherwise, won't he need to change that every time he connects to a different LAN?

                          I ran in to that issue before. A reboot solved it, rather than having to manually enter nameservers.

                          1 Reply Last reply Reply Quote 0
                          • scottalanmillerS
                            scottalanmiller @siringo
                            last edited by

                            @siringo said in Fedora name resolution:

                            @scottalanmiller said in Fedora name resolution:

                            Same command as on Windows...

                            nslookup sitename
                            

                            That'll tell us what it is "doing."

                            If I go "nslookup hostname" I get told that there is no entry for 'hostname' in DNS which looks correct.

                            You are doing hostname, not FQDN?

                            1 Reply Last reply Reply Quote 0
                            • scottalanmillerS
                              scottalanmiller
                              last edited by

                              If searching for a hostname, do you have a "search" option in /etc/resolv.conf ?

                              1 Reply Last reply Reply Quote 0
                              • stacksofplatesS
                                stacksofplates @Obsolesce
                                last edited by

                                @obsolesce said in Fedora name resolution:

                                @black3dynamite said in Fedora name resolution:

                                @obsolesce said in Fedora name resolution:

                                If it's a .local domain, edit the avahi-daemon.conf file:

                                Un-comment the following line, and add a . (dot) infront of local:

                                domain-name=.local

                                Then restart network or reboot.

                                Why not edit /etc/nsswitch.conf instead?
                                https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                                Change...
                                hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                                To...
                                hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                                I wasn't aware of that option.

                                Can you tell me why one solution is better than the other or why one is worse than the other?

                                nsswitch defines the default order to look for information. Thats where you define user, group, sudo, DNS, etc lookups.

                                1 Reply Last reply Reply Quote 0
                                • stacksofplatesS
                                  stacksofplates
                                  last edited by

                                  A couple things. As @scottalanmiller pointed out, make sure to check your /etc/resolve.conf. That gives you the DNS servers and search domain to query. If all of that lines up, then I would check your /etc/nsswitch.conf file and make sure dns is after files.

                                  black3dynamiteB 1 Reply Last reply Reply Quote 2
                                  • black3dynamiteB
                                    black3dynamite @Obsolesce
                                    last edited by black3dynamite

                                    @obsolesce said in Fedora name resolution:

                                    @black3dynamite said in Fedora name resolution:

                                    @obsolesce said in Fedora name resolution:

                                    If it's a .local domain, edit the avahi-daemon.conf file:

                                    Un-comment the following line, and add a . (dot) infront of local:

                                    domain-name=.local

                                    Then restart network or reboot.

                                    Why not edit /etc/nsswitch.conf instead?
                                    https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                                    Change...
                                    hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                                    To...
                                    hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                                    I wasn't aware of that option.

                                    Can you tell me why one solution is better than the other or why one is worse than the other?

                                    Has long as dns is after files in the hosts: section in nsswitch.conf file, utilities like nslookup should work correctly.

                                    ObsolesceO 1 Reply Last reply Reply Quote 1
                                    • black3dynamiteB
                                      black3dynamite @stacksofplates
                                      last edited by

                                      @stacksofplates said in Fedora name resolution:

                                      A couple things. As @scottalanmiller pointed out, make sure to check your /etc/resolve.conf. That gives you the DNS servers and search domain to query. If all of that lines up, then I would check your /etc/nsswitch.conf file and make sure dns is after files.

                                      I notice with a clean install of Fedora 28, the nsswitch.conf is auto created and manage by authselect instead authconfig.
                                      https://fedoraproject.org/wiki/Changes/AuthselectAsDefault

                                      The settings in the nsswitch.conf file is different too.

                                      # Generated by authselect on Fri May 11 18:52:54 2018
                                      # Do not modify this file manually.
                                      
                                      passwd:      sss files systemd
                                      group:       sss files systemd
                                      netgroup:   sss files
                                      automount:  sss files
                                      services:   sss files
                                      sudoers:    files
                                      
                                      shadow:     files
                                      ethers:     files
                                      netmasks:   files
                                      networks:   files
                                      protocols:  files
                                      rpc:        files
                                      hosts:      files dns myhostname
                                      
                                      aliases:    files nisplus
                                      bootparams: nisplus [NOTFOUND=return] files
                                      publickey:  nisplus
                                      ~                   
                                      

                                      By default the order for hosts is now files, dns, myhostname instead of hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname from the previous Fedora releases.

                                      1 Reply Last reply Reply Quote 0
                                      • ObsolesceO
                                        Obsolesce @black3dynamite
                                        last edited by

                                        @black3dynamite said in Fedora name resolution:

                                        @obsolesce said in Fedora name resolution:

                                        @black3dynamite said in Fedora name resolution:

                                        @obsolesce said in Fedora name resolution:

                                        If it's a .local domain, edit the avahi-daemon.conf file:

                                        Un-comment the following line, and add a . (dot) infront of local:

                                        domain-name=.local

                                        Then restart network or reboot.

                                        Why not edit /etc/nsswitch.conf instead?
                                        https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                                        Change...
                                        hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                                        To...
                                        hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                                        I wasn't aware of that option.

                                        Can you tell me why one solution is better than the other or why one is worse than the other?

                                        Has long as dns is after files in the hosts: section in nsswitch.conf file, utilities like nslookup should work correctly.

                                        Un-commenting the .local line in the other file seems to do the job just fine. Still not seeing any advantages to doing it the other way, or disadvantages to keep doing it how I am.

                                        black3dynamiteB 1 Reply Last reply Reply Quote 0
                                        • black3dynamiteB
                                          black3dynamite @Obsolesce
                                          last edited by black3dynamite

                                          @obsolesce said in Fedora name resolution:

                                          @black3dynamite said in Fedora name resolution:

                                          @obsolesce said in Fedora name resolution:

                                          @black3dynamite said in Fedora name resolution:

                                          @obsolesce said in Fedora name resolution:

                                          If it's a .local domain, edit the avahi-daemon.conf file:

                                          Un-comment the following line, and add a . (dot) infront of local:

                                          domain-name=.local

                                          Then restart network or reboot.

                                          Why not edit /etc/nsswitch.conf instead?
                                          https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                                          Change...
                                          hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                                          To...
                                          hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                                          I wasn't aware of that option.

                                          Can you tell me why one solution is better than the other or why one is worse than the other?

                                          Has long as dns is after files in the hosts: section in nsswitch.conf file, utilities like nslookup should work correctly.

                                          Un-commenting the .local line in the other file seems to do the job just fine. Still not seeing any advantages to doing it the other way, or disadvantages to keep doing it how I am.

                                          Only disadvantage or more of an inconvenience that I can see, is that you would have to keep changing the domain name because of each network uses a different domain like .local, .lan, or .home.

                                          But I don't see anything wrong with un-commenting domain-name=local

                                          stacksofplatesS 1 Reply Last reply Reply Quote 0
                                          • stacksofplatesS
                                            stacksofplates @black3dynamite
                                            last edited by

                                            @black3dynamite said in Fedora name resolution:

                                            @obsolesce said in Fedora name resolution:

                                            @black3dynamite said in Fedora name resolution:

                                            @obsolesce said in Fedora name resolution:

                                            @black3dynamite said in Fedora name resolution:

                                            @obsolesce said in Fedora name resolution:

                                            If it's a .local domain, edit the avahi-daemon.conf file:

                                            Un-comment the following line, and add a . (dot) infront of local:

                                            domain-name=.local

                                            Then restart network or reboot.

                                            Why not edit /etc/nsswitch.conf instead?
                                            https://ask.fedoraproject.org/en/question/90486/cannot-resolve-local-domain-name-on-fedora-23/?answer=90625#post-id-90625

                                            Change...
                                            hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname

                                            To...
                                            hosts: files dns mdns4_minimal [NOTFOUND=return] myhostname

                                            I wasn't aware of that option.

                                            Can you tell me why one solution is better than the other or why one is worse than the other?

                                            Has long as dns is after files in the hosts: section in nsswitch.conf file, utilities like nslookup should work correctly.

                                            Un-commenting the .local line in the other file seems to do the job just fine. Still not seeing any advantages to doing it the other way, or disadvantages to keep doing it how I am.

                                            Only disadvantage or more of an inconvenience that I can see, is that you would have to keep changing the domain name because of each network uses a different domain like .local, .lan, or .home.

                                            But I don't see anything wrong with un-commenting domain-name=local

                                            Right, /etc/nsswitch defines where you're looking. So correcting that fixes all scenarios vs fixing only one specific thing.

                                            ObsolesceO 1 Reply Last reply Reply Quote 1
                                            • 1
                                            • 2
                                            • 1 / 2
                                            • First post
                                              Last post