Issue installation Samba - Ubuntu 14.04

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

GCM

Active Member
Aug 24, 2015
133
42
28
I followed the wiki exactly, and every time I try to test the new install I get the following:

smbclient -L localhost -U%
Connection to localhost failed (Error NT_STATUS_CONNECTION_REFUSED)

I've confirmed that samba is running, and have confirmed that there are no iptables rules blocking any ports.

My samba config is as follows:

# Global parameters
[global]
workgroup = INTERNAL
realm = INTERNAL.GENERIC.COM
netbios name = BUS-NY-SAMBA-01
server role = active directory domain controller
dns forwarder = 8.8.8.8
interfaces = eth0 lo
bind interfaces only = yes

[netlogon]
path = /var/lib/samba/sysvol/internal.generic.com/scripts
read only = No

[sysvol]
path = /var/lib/samba/sysvol
read only = No

DNS as follows:

127.0.0.1 localhost.localdomain localhost
192.168.1.225 BUS-NY-SAMBA-01.internal.generic.com BUS-NY-SAMBA-01

# The following lines are desirable for IPv6 capable hosts
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters


After a reboot I get the following:
BUS-NY-SAMBA-01:~$ smbclient -L localhost -U% session setup failed: NT_STATUS_OBJECT_NAME_NOT_FOUND
 

GCM

Active Member
Aug 24, 2015
133
42
28
I'm testing it locally though. It shouldn't matter if it's bound to my loop back.
 

pricklypunter

Well-Known Member
Nov 10, 2015
1,708
515
113
Canada
I know Samba 2 was buggy, and that was one of the things it threw up, but it was fixed (if you can ever call Samba fixed) in ver 2.1.1 as far as I know, but this also raised it's head again in Samba 4. Binding issues aside for a mo, I take it your permissions are set correctly?
 
Apr 13, 2016
56
7
8
54
Texas
I tried this weekend to "quickly" get Samba running on a fresh install of Ubuntu 16.04, and at the moment still haven't gotten it working... I found several forums complaining of similar issues, as well as the permissions one. Several have noted setting security = user resolves the CONNECTION_REFUSED error.

Sent via Tapatalk
 
Last edited:

pricklypunter

Well-Known Member
Nov 10, 2015
1,708
515
113
Canada
Samba is great when it works and a mare when it doesn't. I seem to recall having all sort of issues with Samba and ext4. I tried every version, tweaking, setting this and that, beginning each time from a clean install. I finally gave up banging my head with it and went back to using ext3 just to get up and running :)
 

GCM

Active Member
Aug 24, 2015
133
42
28
Yeah, I think I may switch over to CentOS. Seems a lot of people have issues with Ubuntu and Samba 4.
 

pricklypunter

Well-Known Member
Nov 10, 2015
1,708
515
113
Canada
Debian 8 and CentOS 5.11 are the only ones I have really been successful with getting Samba stable-ish, I haven't tried on CentOS 7, but even then its flaky sometimes :D
 

EffrafaxOfWug

Radioactive Member
Feb 12, 2015
1,394
511
113
I've been running samba 4 as a domain controller (under jessie) for 2 years now and would definitely call it stable; what steps did you go through with regards to doing your dcpromo? Presumably you're using internal DNS rather than BIND? FWIW I had way less trouble with BIND than I did with samba.

This was done under samba 4.1 and I'm now on 4.2, but it worked at the time:
Code:
samba-tool domain provision --use-rfc2307 --interactive --dns-backend=BIND9_DLZ
Corresponding entries in the globals for smb.conf were (I think you need winbindd instead of winbind for samba 4.2):
Code:
[global]
        workgroup = MAGRAMAL
        realm = MAGRAMAL.LOCAL
        netbios name = WUG
        server role = active directory domain controller
        server services = s3fs, rpc, nbt, wrepl, ldap, cldap, kdc, drepl, winbind, ntp_signd, kcc, dnsupdate
        idmap_ldb:use rfc2307 = yes
 

GCM

Active Member
Aug 24, 2015
133
42
28
Pretty much did the same as you, but I did use the internal.
 

EffrafaxOfWug

Radioactive Member
Feb 12, 2015
1,394
511
113
Then all I can suggest is trying to drop the `bind interfaces` option; I'd originally inherited an `allow hosts` option in my smb.conf and when samba was converted into a DC, it all fell over in a big heap - from ramping up the debug level in the logs it seemed that samba was using a lot of weird internal names that didn't match hosts allow and were therefore dropped.

You also don't mention your `server services` config, when I set mine up at least it was needed, checking now the defaults are
Code:
s3fs rpc nbt wrepl ldap cldap kdc drepl winbind ntp_signd kcc dnsupdate dns
...which would seem to match your intended configuration so it doesn't look like that is something to worry about.

Presumably your resolv.conf is all in order and dig is happy as a sandboy for forward and reverse...? Can you locate the DC SRV records with host? Iffy DNS behaviour when samba was misbehaving was my biggest reason for going the BIND DLZ route so that even when samba got its knickers in a twist I'd still have a functional DNS server.

Assume your krb5.conf config is all in order?
 

GCM

Active Member
Aug 24, 2015
133
42
28
I'll try that.

And yep, DNS records are perfectly in order and tests good.

Same with kerberos.