I used smbclient while running my virtual Linux on the same computer.
Here ‘s what I do
1. connect using smbclient //dest ip/folder -Uuser
2. The windows box will ask the password. Answer it!
3. After you connected do this step by step
4. type tarmode
5. type recurse
6. type prompt
7. mget foldertocopy\
8. the whole folder will be copied to your home folder.

Thats it πŸ™‚

14 thoughts on “Getting whole folder using Smbclient

  1. Save my day today. I needed to move files from a read only file system to another host with no GUI. This worked great!

  2. – tarmode is not necessary
    – recurse tells the smbclient to get all sub-directories too (You want this)
    – prompt tells smbclient not to prompt you about every single file. (You want this)

    If you only have a few files, prompt doesn’t matter. If you have a lot, use prompt.
    Also note that prompt is a toggle. By default it will prompt, so you toggle it off. If you type “prompt” again, it will start prompting about each file.

    Thanks for the tip! This really helped.

Leave a comment