Connect to SMB Server over command line

18.1k views Asked by At

What is the equivalent to "Connect To Server" on the mac for the command line?

Connect to Server

I would like to automate the process rather than summon the dialog every time I need to connect to a server.

1

There are 1 answers

3
hrishikesh chaudhari On BEST ANSWER

There are multiple ways to connect to remote server! I am assuming you have server running on windows OS. Mac OS X includes the SMB protocol for networking with Windows computers; some Linux and Unix systems can also share files with this protocol as well. You can easily mount a shared SMB volume using the mount command. Steps to be followed as below

1) mkdir /temp
2) chmod 777
3) mount -t smbfs //username@ip/nameOfSharefolder /temp

After this you can browse to/temp directory and browse

You can also use sshssh or ftp command to access the remote server but you need to run the ftp server in case of ftp command or remote access must be enable in case of ssh