Ever since I dumped Gnome for pure WMs and heavy file managers for their lighter counterparts, my only problem was with samba shares. I used to mount them with Nautilus, Gnome's native file manager, but unfortunately, this doesn't work with Thunar or PCManFM.
A bit of googling reveals that many people asked the question:
- Mount the share manually, using mount.cifs
- Mount the whole network with fuse
- Use a specializes application like LinNeighborhood or pyNeighborhood
In the end, I wrote my own solution. See it in action.
It is a simple bash scripts which takes the URL and mounts all available shares. The current version of the smbmounter script can be found on github.
Download the script and place it somewhere. Then edit it and change the variable FM to your preferred file manager (default is thunar) and variable MOUNT_ROOT to the root directory where all shares shall be placed (default is /media/samba).
mount.cifs needs to run as root, so to be able to let the script run unattended (which is important if you want to use it from firefox) you need to set passwordless permission for either mount.cifs or this script. This can be done in /etc/sudoers. This is an example which will allow this for all members of group wheel.
%wheel ALL=NOPASSWD: /sbin/mount.cifs
For an extra paranoia, modify the script to use gksudo instead of sudo.
Setting it as a protocol handler in firefox is a bit tricky. Following steps apply for Firefox 3.0.*, Firefox 2 configuration is slightly different and I never managed to set it in Firefox 3.5b4 (but hey, it's beta).
Open about:config and create new boolean property
network.protocol-handler.external.smb = true
and new string property
network.protocol-handler.app.smbLeave this one empty -- for now. Now click the smb:// link, the format should be smb://hostname_or_ip/ The dialog will appear, asking for external application to launch. Select this script and check remember. Now go and mount.