Mount Shared windows drive as folder in OSX 10.6+
Okay, I'm familiar with the basics, use sudo mount_smbfs
smb://domain;user:password@server/sharename /mountpoint ... but this
doesn't work, thought I had it working and now it's not again...
Opps... Remembered
Okay, I figured out what I was doing wrong while I was typing this post,
but for the sake of the past 2 hours that I've spent figuring this out
I'll go ahead and try to list out what I've learned
First of all, make sure that you don't have the Shared folder already
mounted somewhere or you'll get the dreaded mount error: file exists. The
df command may help here. Heads up to Mark for his post that helped me
figure that one out, will link to that post at the end.
Another error that you're likely to run into is "could not find mount
point: no such file or folder", just make a folder that is the same as
/mountpoint that you're trying to mount your shared folder to. mkdir
$HOME/the rest of your path/yourmountpointname or mkdir
/yourmountpointname will fix that. $HOME is a variable that expands to
/Users/ComputerName which is different for every system.
Finally, the problem that killed me was Apple's insanity or whoever
programmed this command, sudo, su, and even the straight command will fail
with the error "server rejected the connection: Authentication error"
which is very misleading and probably has nothing to do with the real
error. I finally figured out what I was doing wrong when I read Ward's
post on how to use this command, linked at the end of this post. Basically
you have to use "sudo -u UserNamewithAdminRights Command" in order for it
to work. The following is an example of what it should look like.
mkdir /mountpoint sudo -u UserName mount_smbfs
smb://domain;networkuser:networkpassword@servername/sharename /mountpoint
If you're interested in using this seriously, you may want to research
autofs some, or at least that's the direction I'm heading with it.
Correction, I'm looking to replace this with autofs not use it with
autofs.
Link to Mark's post:
http://www.markhneedham.com/blog/2011/01/15/mount_smbfs-mount-error-file-exists/
Link to Ward's post:
http://www.oakgrounds.com/blogbriask-the-experti/item/183-smb-mount-mount-t-smbfs-on-a-mac-osx-headache
No comments:
Post a Comment