Given a set of XML files available on a Windows Share \\server\share contains spaces\direcory\, I need a bash command to download one specific file from that share.

Neither wget nor curl support any smb:// URI, and I'd like to avoid the mount command. Solutions?

1 Answer 1


smbclient can be scripted to upload or download files using the -c option. Syntax is similar to ftp.


smbclient -I [server IP] "//servername/path with spaces/" -c "get [filename]"

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .