Monday, February 2, 2009

Mounting a Windows share on Linux

I created a share on Windows desktop at work and wanted to access it from my Ubuntu 8.10 virtual machine served up by VMWare Server but ran into a roadblock:
$ sudo mount -t smbfs -o username=myWindowsLogin,password=myWindowsPassword,uid=prystasj,gid=prystasj,file_mode=000,dir_mode=000 //myWindowsBox/share /share
mount: wrong fs type, bad option, bad superblock on //prystash-j.mycompany.org/share,
missing codepage or helper program, or other error
(for several filesystems (e.g. nfs, cifs) you might
need a /sbin/mount. helper program)
In some cases useful info is found in syslog - try
dmesg | tail or so

$ dmesg | tail
...
[19838.333431] smb_fill_super: missing data argument
...
The answer was to install smbfs.
$ sudo apt-get install smbfs
$ sudo mount -t smbfs -o username=myWindowsLogin,password=myWindowsPassword,uid=prystasj,gid=prystasj,file_mode=000,dir_mode=000 //myWindowsBox/share /share
Unfortunately, as myself or root, I'm not able to write anything to /share from my Linux host, but I can read just fine.
$ sudo ls -ld /share
d--------- 1 prystasj prystasj 0 2009-02-02 15:41 /share
Will have to investigate more later.

1 comment:

  1. Hello.
    Maybe, your user don't have any permissions to write in this folder.
    So you might want to check the NTFS rights of this folder.

    Here is a link : http://technet.microsoft.com/fr-fr/magazine/2005.11.howitworksntfs(en-us).aspx

    ReplyDelete