nerdexam
Linux_Foundation

LFCS · Question #59

Which of the following keywords can be used in the file /etc/nsswitch.conf to specify a source for host name lookups? (Choose TWO correct answers.)

The correct answer is B. dns D. files. This question identifies the keywords used in /etc/nsswitch.conf to specify sources for hostname lookups, defining the order of resolution.

Submitted by yuriko_h· Apr 18, 2026Networking

Question

Which of the following keywords can be used in the file /etc/nsswitch.conf to specify a source for host name lookups? (Choose TWO correct answers.)

Options

  • Aresolv
  • Bdns
  • Cremote
  • Dfiles
  • Ehosts

How the community answered

(29 responses)
  • A
    3% (1)
  • B
    93% (27)
  • E
    3% (1)

Why each option

This question identifies the keywords used in `/etc/nsswitch.conf` to specify sources for hostname lookups, defining the order of resolution.

Aresolv

`resolv` is not a valid keyword in `/etc/nsswitch.conf` for host lookups; `dns` is used instead.

BdnsCorrect

The `dns` keyword indicates that host information should be obtained from DNS servers, as configured in `/etc/resolv.conf`.

Cremote

`remote` is not a standard keyword used in `/etc/nsswitch.conf` to specify a source for host name lookups.

DfilesCorrect

The `files` keyword specifies that host information should be obtained from local static files, specifically `/etc/hosts` for hostname resolution.

Ehosts

`hosts` is the database *entry* in `/etc/nsswitch.conf` (e.g., `hosts: files dns`), not a source keyword that follows the colon.

Concept tested: /etc/nsswitch.conf host lookup sources

Source: https://man7.org/linux/man-pages/man5/nsswitch.conf.5.html

Topics

#/etc/nsswitch.conf#Hostname resolution#Name Service Switch#DNS

Community Discussion

No community discussion yet for this question.

Full LFCS Practice