Accessing Samba from a UNIX client session

To test access to Samba shares on a Linux or UNIX computer, users should do the following:

To access Samba from a UNIX client session:

  1. Log on to the Linux or UNIX computer using the Active Directory account that has been granted access to the local computer’s zone.
  2. Run the following command:

    smbclient -k -L host_name

    The smbclient program displays information about Samba and the SMB shares that are available on the local computer. For example, you should see a listing similar to the following (where s.s.s is the Samba version):

    OS=[Unix] Server=[Samba s.s.s]

    Sharename Type Comment
    --------- ---- -------
    samba-test Disk
    IPC$ IPC IPC Service (Samba-CDC)
    sara Disk Home directories

    OS=[Unix] Server=[Samba s.s.s]

    Server Comment
    --------- -------
    Workgroup Master
    -------- -------

If you are able to see the Samba shares as an Active Directory user logged on to the Linux or UNIX computer that is acting as the Samba server, you should next test accessing the Samba shares from a Windows desktop. For information about performing this test, see Accessing Samba shares from a Windows desktop.

Purging and reissuing Kerberos tickets on UNIX computers

If you see an error such as NT_STATUS_LOGIN_FAILURE instead of the expected results when you run the smbclient program, you may need to purge your existing Kerberos tickets and have them reissued. Try running the following command to remove all of your Kerberos tickets:


Then run the following command to reissue tickets after you provide your Active Directory password:


You can then run the following command to list the Kerberos tickets that have been issued to you:


After verifying the Kerberos tickets you have been issued, try running the smbclient program again.

Verifying the version of Samba you are using

If purging and reissuing tickets does not resolve the problem, confirm the version of the smbstatus that is currently running using the following command:

smbstatus | grep version

The command should display the Samba version you have installed. For example:

Samba version s.s.s

(where s.s.s is the installed Samba version)

If the correct version of Samba is installed, run smbstatus again and note the names of any *.tdb files that do not exist, and try restoring them from your backup, then try running the smbclient program again.

If you don’t see the correct Samba shares

If the smbclient program does not display the Samba shares you have defined in the configuration file, you should review the settings in the smb.conf file and then restart the DirectControl agent and run the adflush command.