I run on a Debian machine, and I’m in a Windows environment. So from time to time I have to map some share on a machine and upload or download some file. Every time I panic because I don’t remember how to do this smbclient stuff, so I’m just going to post it here. First, I have a file called authfile, which has in it 3 lines:
username = myusername
password = mypassword
domain = thedomain
Then say we have a server MX20 and a “share” called “Shared”, then all I have to do is
smbclient //MX20/Shared -A authfile
This logs me in, and then I can drill down to whatever folder they want and get and put the required files.