Categorized | Linux, Networking, Ubuntu, Windows Vista

Linux Share With Windows Vista

Posted on 02 March 2007 by admin

WebWatcher-Get 40% Off

Do you need to have a Linux Share available to Vista users?  Permanently available, not just for the session and in read-write mode?  Here’s how.

These instructions assume that you’ve set up a password-protected shared folder on the Vista machine in a non-domain environment, that you have already installed Samba server v3.0.22 or later and smbfs on the Linux machine, and that you’ve created a Samba user account and password. All of the following steps are performed on the Linux machine.

1. Choose a name to use for the shared folder on your Linux machine, such as vista_public. Open a Terminal window and issue the command

sudo mkdir /mnt/vista_public

(if you chose a different name to identify the shared folder, substitute it for vista_public). This creates a directory that will be used as the mount point for your shared folder.

2. Using a text editor, create a plain text file containing two lines:

username=windows_username
password=windows_password

Substitute your actual Windows username and password for the italicized text. Save the file in your home folder as .smbpasswd (don’t forget the period at the beginning of the filename).

Finally, change the permissions on the file so only you can open and change it by issuing the following command in a Terminal window:

chmod 600 .smbpasswd

3. On the Linux machine, open /etc/fstab in a text editor.

sudo gedit /etc/fstab

4. At the end of the file, add a new line containing the following:

//vista_pc_name/share_name   mount_folder_name smbfs credentials=/home/linux_username/.smbpasswd,uid=linux_username,gid=users  0 0

Use the UNC path for the Windows share, and replace mount_folder_namewith the full path of the folder you created in Step 1 (in this example, /mnt/vista_public).

Substitute your Linux username for the values. These credentials will be passed to the Vista machine.

Note: there’s no space after the comma and before the uid and gid. You can safely substitute cifs for smbfs in the fstab entry.] 

5. Save the file and, in the Terminal window, issue the command sudo mount -a.
6. Create a link in your Home folder or on the desktop to the location you created in Step 1 (in this example, /mnt/vista_public) and give the link a descriptive name. Click OK to save it.

You now have a shortcut (link, in Linux-speak) that you can use to access files in your shared Vista folder. If you find that subfolders in the shared folder are set as read-only, right-click the folder on the Linux box, choose Properties, and click the Permissions tab.

  • Share/Bookmark

Tags | , , ,

Acronis True Image Home 2010

Comments are closed.

Categories