Score:0

How to copy file from smb server

ng flag

I have an air quality monitor which has a smb URL smb://192.168.0.131 and I would like to copy files stored on it but I cannot seem be able to ssh into it using sudo ssh username@192.168.0.131. It keeps saying incorrect password. What search terms would you use to do something like this?

Edit from comment

I'm on Mac but I'm going to see if I can figure out the equivalent commands from Rinzwind's answer.

ru flag
SSH is not SMB. You are not going to be able to SSH into an SMB share/system if it's not exposing SSH. SMB is also Microsoft compatible shares, so I don't know why you're trying to SSH to the box. You need to use the SMB protocol to connect to the device to copy files on the share to your system. This does NOT mean you'll be able to get the system files for the monitor though, only what it puts in the SMB shares
ar flag
Please [edit your question](https://askubuntu.com/posts/1373335/edit) and add which version and flavor of Ubuntu you are using? Are you using the server or the desktop?
HCAI avatar
ng flag
@user68186 I'm on Mac but I'm going to see if I can figure out the equivalent commands from Rinzwind's answer.
Score:3
cn flag
  • ssh (secure shell) is not smb (Samba)
  • you list 2 different IPs for smd and ssh. 1 will be wrong.

You can mount samba with cifs-utils so if not installed install it with ...

sudo apt install cifs-utils

Create a permanent mount point and mount the share:

sudo mkdir /mnt/air_quality_monitor
sudo mount -t cifs -o "domain=DOMAIN,username=USER,password=PASSWORD,sec=ntlm,vers=1.0" //IP /mnt/air_quality_monitor
  • All the words in capitals need to be changed to what you need.
  • sec is the security mode and determines how passwords are encrypted between server and client ( even if you don't require passwords ). ntlm used to be the default so that might work. If not omit it or check man mount.cifs for other supported models.
  • vers=1.0 might need to be changed to a supported version. You can also try it without this option.
  • domainmight not be needed too; if you do not have one remove domain=DOMAIN, from the options.
HCAI avatar
ng flag
Thank you very much for your help, it's much appreciated!
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.