[TIP] Mount a Windows share on Linux

To test if your Linux machine sees the shares on the Windows box:
smbclient -L windowsbox -U username
and it prompts you for the password.

Mount the share:
mount -t smbfs -o username=john //winbox/share /mnt
and it prompts you for the password.

Notes:
1) It’s OK to use domain users in both cases ("domainusername"). You need to use quotes to escape the backslash.

2) You can give the password in the commandline options list like this:
-o username="domainusername",password=topsecret
Note that this syntax saves the password. Also, it will be visible in the processes list.

3) The -t smbfs option can usually be omitted. The mount command should detect the type automatically.

See: http://cri.ch/linux/docs/sk0001.html

Advertisements
This entry was posted in console and tagged , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s