Skip to main content

Samba share not working for osx users, but fine for windows users? [Resolved]

Using webmin on a linux box I setup a few samba shares. I can access them fine using any windows machine, but when I connect to the server using osx, finder prompts me for a username and password then tells me no dice. Is there something specific that needs to be setup for osx to access a share vs windows?

NOTE: After I enter my credentials it shows me the shares, but when I select any of them it then give me a general error connecting to server message.

My smb.conf is as follows:

[global]
    log file = /var/log/samba/samba.log
    guest account = nobody
    passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
    add group script = /usr/sbin/groupadd '%g'
    admin users = root
    obey pam restrictions = yes
    delete group script = /usr/sbin/groupdel '%g'
    socket options = TCP_NODELAY
    add user to group script = /usr/sbin/usermod -G '%g' '%u'
    encrypt passwords = yes
    passdb backend = tdbsam
    passwd program = /usr/bin/passwd %u
    wins support = true
    dns proxy = no
    netbios name = FILESERVER
    server string = Company FileServer
    unix password sync = yes
    workgroup = OfficeWG
    os level = 20
    add user script = /usr/sbin/useradd -m '%u' -g users -G users
    auto services = global
    security = share
    syslog = 0
    panic action = /usr/share/samba/panic-action %d
    delete user script = /usr/sbin/userdel -r '%u'
    max log size = 1000
    pam password change = yes

[officemain]
    writeable = yes
    path = /mainstorage/officemain

[homes]
    browseable = no
    comment = Home Directory
    writeable = yes
    path = /mainstorage/home/%S

[markshome]
    browseable = no
    comment = Marks Home Folder
    writeable = yes
    path = /mainstorage/home/markepstien

I have cleared the samba log and tried to reconnect. Here are the contents of the log. I see it says incorrect password, but I can connect fine using the user/pass from a windows machine.

[2013/05/06 14:57:52.261776,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:52.263770,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:52.264188,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:52.266115,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:52.268249,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:52.271604,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.265867,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.267877,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.268336,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.270168,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.272388,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:57:55.275714,  0] printing/print_cups.c:108(cups_connect)
  Unable to connect to CUPS server localhost:631 - Connection refused
[2013/05/06 14:58:02.073941,  1] smbd/service.c:678(make_connection_snum)
  create_connection_server_info failed: NT_STATUS_WRONG_PASSWORD
[2013/05/06 14:58:02.076238,  1] smbd/service.c:678(make_connection_snum)
  create_connection_server_info failed: NT_STATUS_WRONG_PASSWORD
[2013/05/06 14:58:08.104229,  0] param/loadparm.c:8445(check_usershare_stat)
  check_usershare_stat: file /var/lib/samba/usershares/ owned by uid 0 is not a regular file

Question Credit: MindWire
Question Reference
Asked October 11, 2017
Tags: mac-osx, samba
Posted Under: Network
23 views
4 Answers

It turns out to have been something in the global section of the smbd.conf file. As soon as I removed everything in the global section, then replaced it with simply a workgroup = officeWG then everything started working on osx.


credit: MindWire
Answered October 11, 2017

I think I have had this issue in a test environment before. As best I can remember, I had to add the workgroup (like you have) and then connect to server.workgroup.local from my Mac.

Another thing to try is authenticating with the user name in the format user@server.domain.local.

I will try to find any notes from the issue I had.


credit: dotbat
Answered October 11, 2017
 
Gave it a try and no dice. I have added some notes above if it helps. – MindWire May 6 '13 at 21:13
 CanDoerz  2 months ago

The problem was in your security = share setting. I had a similar situation where my OS X clients could not connect to my Samba share. I resolved it by using security = user


credit: Jenny D
Answered October 11, 2017

I've got this issue and solved it by making sure the shared directory was owned by samba user and mod was 774 for the directory .


credit: Glamdring
Answered October 11, 2017
Your Answer
D:\Adnan\Candoerz\CandoProject\vQA