How to mount remote samba shares...

Started by armus2112, October 06, 2008, 09:10:02 pm

Previous topic - Next topic


Well I installed Samba:

I am able to share local directories in OpenStep 4.2 and get into my OpenStep directories from other Windows / Mac servers. Works great.

HOWEVER the question is: how to I mount a remote samba file share in OpenStep 4.2 itself? There is no 'smbmount' command included in the Samba package. The mount command does not recognize the 'smbfs' file system type on the mount command.

So I found 'rumba':

and also 'Sharity Light' which appears to be identical to 'rumba':

The command I use to mount a remote Windows share is this. Note you have to add the remote host as a machine (with an IP address) in NetInfoManager first. My host is 'MyWinXP'. I placed 'shlight' in /bin for ease of access. I had to chmod 'shlight' as suid root by doing 'chmod 4755 /bin/shlight' also in order for non root users to perform the mount. Of course you need to create the directory /mnt/music first:

/bin/shlight //MyWinXP/iTunes /mnt/music -w -U dummy -P dummy

My iTunes folder in WinXP is setup for 'Everyone' to have read access to the folder. Specifying '-U dummy -P dummy' seems to work just fine! The user 'dummy' is just gibberish, no such user exists on WinXP. Wierd huh. I tried specifying a valid WinXP user/pass but always get '[13] Permission Denied' error. The option '-w' means read-only.

After this command, 'ls /mnt/music' will show the files on WinXP.

To unmount, type:  /bin/unshlight /mnt/music

1- Workspace Manager cannot list the files under /mnt/music.  Have no idea why. It just shows an icon for /mnt/music but cannot peruse the directory.

2- I can run apps and Open files on /mnt/music just fine (like by using XS3mod to play mp3s)

3- I have Mac OS X Tiger server here, and I cannot for the life of me use Sharity Light / rumba to connect to a 'Windows Sharing' share there. Sharity Light will connect and open a port, but 'ls' on the directory will hang with error 'NFS readdir failed for server shlight: RPC: Timed out'

4- Windows share names with a dash in the name will NOT work.

5- the mount seems to be persistent. I can log out and log back in and still see the remote directory. Of course rebooting will make it go away.

6- As I mentioned in #3, I can only mount to Windows shares. Do not fully understand what I'm doing wrong if anything.

Is there an easier way to mount remote Samba shares that I'm missing here?   If not, maybe this info will be useful to you guys.



The shlight command works pretty okay as mentioned above. But I had to manually initiate it from Terminal. I wanted a way to just double click the .sh file in Workspace Manager, have Terminal execute it, and then just move on.

Well, I had to wrap the shlight command around the csh command AND the nohup command - this was the only way I could get this to work.  Other various attempts at this would launch shlight in the background, but after that, wouldn't be UN-launchable. Double clicking the Terminal icon would do nothing. Not sure...

Anyways, this approach below works for me... FYI

I have these commands in a file called "". Double clicking it opens Terminal and executes the command. Then you can just exit Terminal. Then shlight runs in background as a deamon. The mount persists.

csh -c "nohup /bin/shlight //MyWinXP/music /mnt/music -w -U root -P dummy &"

There's probably a more elegant way to do this... but again this works for me..



Six years later. I tried to reinstall samba just to get Openstep to share a folder so that my Windows 7 computer can see it. (I'm not sure, but I think I negated samba by resetting my network settings).

I had forgotten all about this command:


Apparently back in 2008, I had used this command to setup a samba password.

I had forgotten and could not figure out why I could not connect Win7 to Openstep samba (authentication failure)..
Then I happened (luckily) to remember the password from 2008 and was able to connect finally.

I think smbpasswd is located here:


For the record, this is my condensed copy (i.e. just the lines which are used, not showing all the commented out lines) of /usr/samba/lib/smb.conf. I can connect to samba on Openstep in Win7 by going to Start->Run and typing


You have to at least run /usr/local/samba/install_samba once to setup the samba deamons (which writes them into /etc/inetd.conf I think).

I also ended up running /usr/local/samba/bin/smbpasswd to setup a password.

EDIT: I deleted all of /usr/samba. That must have been an older version. It's all running under /usr/local/samba. Version "samba.".


# workgroup = NT-Domain-Name or Workgroup-Name
  workgroup = WORKGROUP

# server string is the equivalent of the NT Description field
  server string = flight_samba

# If you want to automatically load your printer list rather
# than setting them up individually then you'll need this
  load printers = yes

# this tells Samba to use a separate log file for each machine
# that connects
  log file = /usr/local/samba/var/log.%m
  log level = 3

# Put a capping on the size of the log files (in Kb).
  max log size = 50

# Security mode. Most people will want user level security. See
# security_level.txt for details.
  security = user

# You may wish to use password encryption. Please read
# ENCRYPTION.txt, Win95.txt and WinNT.txt in the Samba documentation.
# Do not enable this option unless you have read those documents
encrypt passwords = yes

# Most people will find that this option gives better performance.
# See speed.txt and the manual pages for details
  socket options = TCP_NODELAY

# DNS Proxy - tells Samba whether or not to try to resolve NetBIOS names
# via DNS nslookups. The built-in default for versions 1.9.17 is yes,
# this has been changed in version 1.9.18 to no.
  dns proxy = no

# NeXT compat section
 locking = no
 share modes = no
 oplocks = False

#============================ Share Definitions ==============================
  comment = Home Directories
  browseable = yes
  writable = yes

  comment = sw_dir
  path = /software
  valid users = me gf GF guest nobody
  public = yes
  writable = yes
  printable = no