smbclient -L //server -U user

Category: Local Network & Public Hosting

smbclient -L //server -U user

List the shares a Samba server offers

smbclient is the command-line client for SMB, the file-sharing protocol used by Windows and Samba, and -L lists every share the server advertises. The -U flag supplies the username, and smbclient prompts for the password. This is the fastest way to inventory what a NAS or Windows box exposes before mounting anything.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.