nerdexam
CompTIA

LX0-104 · Question #126

Which option below shows the correct command line to list the shares exported by the Samba server called NAME?

The correct answer is C. smbclient -L NAME. To list the shares exported by a Samba server named NAME, the smbclient -L NAME command is used. This command queries the specified Samba server for its available shares.

Shells, Scripting and Data Management

Question

Which option below shows the correct command line to list the shares exported by the Samba server called NAME?

Options

  • Asmbcontrol -L
  • Bsmbclient -N NAME
  • Csmbclient -L NAME
  • Dsmbmount -L NAME

How the community answered

(60 responses)
  • A
    3% (2)
  • B
    2% (1)
  • C
    90% (54)
  • D
    5% (3)

Why each option

To list the shares exported by a Samba server named NAME, the `smbclient -L NAME` command is used. This command queries the specified Samba server for its available shares.

Asmbcontrol -L

`smbcontrol` is used to send commands to `smbd` or `nmbd` daemons, not to list shares from a remote server.

Bsmbclient -N NAME

`smbclient -N NAME` would attempt to connect to the server 'NAME' without a password, but it would not list the shares; the `-L` option is necessary for listing.

Csmbclient -L NAMECorrect

The `smbclient -L NAME` command is the correct way to list the shares exported by a Samba server named 'NAME'. The `-L` option specifically requests a list of services (shares) from the target host.

Dsmbmount -L NAME

`smbmount` is a command used to mount Samba shares on a Linux system, not to list them.

Concept tested: Listing Samba shares

Source: https://www.samba.org/samba/docs/current/manpages/smbclient.1.html

Topics

#Samba client#smbclient#listing shares#command-line tools

Community Discussion

No community discussion yet for this question.

Full LX0-104 Practice