On Fri, Apr 02, 2021 at 10:48:09PM -0400, Dan Norton wrote:
> # cat /etc/resolv.conf
> domain attlocal.net
> search attlocal.net
> nameserver 1.1.1.1
> nameserver 1.0.0.1
> ...and this works very well. I like it because it cuts out more
> of google's monitoring of my browsing (I use Brave browser and
> DuckDuckGo).
> 
> Now what about the first two lines? What purpose? Can I cut out AT&T
> also? ;)

man resolv.conf

       search Search list for host-name lookup.
              By default, the search list contains one entry, the local domain
              name.   It  is  determined  from  the local hostname returned by
              gethostname(2); the local domain name is taken to be  everything
              after  the first '.'.  Finally, if the hostname does not contain
              a '.', the root domain is assumed as the local domain name.

              [...]

              The  domain  directive is an obsolete name for the search direc‐
              tive that handles one search list entry only.

Those lines do nothing, unless you routinely type commands like
"ssh lemon" or "ping pineapple" with no dots in the hostname.  In that
case, assuming the hosts are not defined in /etc/hosts, the resolver
will try to look up "lemon.attlocal.net" or "pineapple.attlocal.net" or
whatever.

Remember that something will probably overwrite your changes to the
resolv.conf file, unless you take preemptive steps.

Reply via email to