Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I need to be able mount SAMBA (SMB sharing) from terminal. For MAC OS versions (10.5,10.6,10.7) . How can I do that?

share|improve this question

1 Answer 1

up vote 7 down vote accepted

Just like you would do in any common *nix system:

mount -t smbfs //host/share ~/some/folder

… or even more specifically:

mount_smbfs //host/share ~/some/folder

… or when you use a password and a domain:

mount_smbfs //domain;user:password@host/share

Check out man mount for a list of common options to pass to the -o switch. For storing authentication, see nsmb.conf.

To unmount, just call:

umount ~/some/folder
share|improve this answer
    
Thanks a lot. It's really helpfull. I'm just new in MAC OSX and Cocoa. What I need is to create some user, and enable SMB sharing on that user, so it will be accessible only for that user (make that user hide if possible) Is it possible to do? –  User1234 Oct 9 '11 at 0:30
    
I tried but it won't work for me. I need to mount SMB for user, like you can do it from System Preferences, with choosing users. –  User1234 Oct 10 '11 at 11:04
    
@User1234 What do you mean? Which "SMB for user"? What does "mount SMB for user" mean, exactly? From System Preferences, you can enable a SMB share, which will be available to the network, not mount it. –  slhck Oct 10 '11 at 11:06
    
I will try to explain , what I want. I need help really ASAP. And I'm new in all this bash commands. I want to create user from APP (hidden if possible ) and after share folders (already know how to do it from terminal) . After I want to enable SMB sharing on that user account. So server, can access my shared folders, with that user, that I created. Help is really appreciated Thanks –  User1234 Oct 10 '11 at 11:10
    
@User1234 Then this is the wrong question – here, I explained you how to connect to a given share, not how to enable it. Finally you explained your real situation to me, so thank you for that. You already asked that question here: How to enable User Account SMB sharing from terminal on MAC OSX? –  slhck Oct 10 '11 at 11:13

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.