[Samba] NT_STATUS_CONNECTION_REFUSED with smbclient and samba 4.0.6 [SOLVED]

GUEI née worou noee wnoee at yahoo.fr
Wed Sep 4 04:26:46 MDT 2013


Hello,
Thank you very much.
It works now.
I delete the slapd file in /etc/portreserve, reboot the entire computer (postreserve was self started), then start the samba service. 
here is the netstat output : 
[root at DC-TEST ~]# netstat -lntp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name
tcp        0      0 127.0.0.1:42                0.0.0.0:*     LISTEN      1491/samba
tcp        0      0 10.67.200.22:42             0.0.0.0:*                   LISTEN      1491/samba
tcp        0      0 10.67.200.22:139            0.0.0.0:*                   LISTEN      1489/smbd
tcp        0      0 127.0.0.1:139               0.0.0.0:*                   LISTEN      1489/smbd
tcp        0      0 0.0.0.0:111                 0.0.0.0:*                   LISTEN      1159/rpcbind
tcp        0      0 127.0.0.1:464               0.0.0.0:*                   LISTEN      1494/samba
tcp        0      0 10.67.200.22:464            0.0.0.0:*                   LISTEN      1494/samba
tcp        0      0 127.0.0.1:53                0.0.0.0:*                   LISTEN      1500/samba
tcp        0      0 10.67.200.22:53             0.0.0.0:*                   LISTEN      1500/samba
tcp        0      0 0.0.0.0:55669               0.0.0.0:*                   LISTEN      1178/rpc.statd
tcp        0      0 0.0.0.0:22                  0.0.0.0:*                   LISTEN      1260/sshd
tcp        0      0 127.0.0.1:88                0.0.0.0:*                   LISTEN      1494/samba
tcp        0      0 10.67.200.22:88             0.0.0.0:*                   LISTEN      1494/samba
tcp        0      0 127.0.0.1:636               0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 10.67.200.22:636            0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 10.67.200.22:445            0.0.0.0:*                   LISTEN      1489/smbd
tcp        0      0 127.0.0.1:445               0.0.0.0:*                   LISTEN      1489/smbd
tcp        0      0 127.0.0.1:1024              0.0.0.0:*                   LISTEN      1488/samba
tcp        0      0 10.67.200.22:1024           0.0.0.0:*                   LISTEN      1488/samba
tcp        0      0 127.0.0.1:3268              0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 10.67.200.22:3268           0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 127.0.0.1:3269              0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 127.0.0.1:389               0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 10.67.200.22:3269           0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 10.67.200.22:389            0.0.0.0:*                   LISTEN      1492/samba
tcp        0      0 127.0.0.1:135               0.0.0.0:*                   LISTEN      1488/samba
tcp        0      0 10.67.200.22:135            0.0.0.0:*                   LISTEN      1488/samba
tcp        0      0 :::111                      :::*                        LISTEN      1159/rpcbind
tcp        0      0 :::22                       :::*                        LISTEN      1260/sshd
tcp        0      0 :::37091                    :::*                        LISTEN      1178/rpc.statd


And this is the smbclient output now :
[root at DC-TEST ~]#  /usr/local/samba/bin/smbclient -L localhost -U%
Domain=[SIEGE] OS=[Unix] Server=[Samba 4.0.6]

        Sharename       Type      Comment
        ---------       ----      -------
        netlogon        Disk
        sysvol          Disk
        test            Disk
        IPC$            IPC       IPC Service (Samba 4.0.6)
Domain=[SIEGE] OS=[Unix] Server=[Samba 4.0.6]

        Server               Comment
        ---------            -------

        Workgroup            Master
        ---------            -------


Thank you very much.

 
MMe GUEI NOEE MELAINE
BP 3108 DAKAR SENEGAL
SERVICE INFORMATIQUE


________________________________
 De : George Itee <george.itee at gmail.com>
À : GUEI née worou noee <wnoee at yahoo.fr> 
Cc : samba at lists.samba.org 
Envoyé le : Mercredi 4 septembre 2013 5h29
Objet : Re: [Samba] NT_STATUS_CONNECTION_REFUSED with smbclient and samba 4.0.6
 


Hello,
When I got that error, it was because portreserve was holding port 636 and samba cannot bind to it. Go to /etc/portreserve and delete the file slapd. Restart the portreserve service and samba as well. May require a full restart, but should work.
Hope it helps !
George
Sent via Android Mobile Device
On Sep 3, 2013 6:55 PM, "GUEI née worou noee" <wnoee at yahoo.fr> wrote:

Hello,
>I'm trying to install samba 4 as a DC following this tutorial
>https://wiki.samba.org/index.php/Samba_AD_DC_HOWTO.
>
>Ihave reached the step of testing the connectivity to the DC with smbclient
>
>[root at DC-TEST ~]#  /usr/local/samba/bin/smbclient -L localhost -U%
>session setup failed: NT_STATUS_CONNECTION_REFUSED
>
>Samba 4 has started successfully
>
>[root at DC-TEST ~]# netstat -lntp
>Active Internet connections (only servers)
>Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name
>tcp        0      0 0.0.0.0:139                 0.0.0.0:*                   LISTEN      1906/smbd
>tcp        0      0 0.0.0.0:111                 0.0.0.0:*                   LISTEN      1160/rpcbind
>tcp        0      0 0.0.0.0:51505               0.0.0.0:*                   LISTEN      1178/rpc.statd
>tcp        0      0 0.0.0.0:22                  0.0.0.0:*                   LISTEN      1261/sshd
>tcp        0      0 0.0.0.0:445                 0.0.0.0:*                   LISTEN      1906/smbd
>tcp        0      0 :::139                      :::*                        LISTEN      1906/smbd
>tcp        0      0 :::111                      :::*                        LISTEN      1160/rpcbind
>tcp        0      0 :::22                       :::*                        LISTEN      1261/sshd
>tcp        0      0 :::445                      :::*                        LISTEN      1906/smbd
>tcp        0      0 :::46598                    :::*                        LISTEN      1178/rpc.statd
>
>Here is an output af smbclient in debbuging mode
>
>[root at DC-TEST ~]#  /usr/local/samba/bin/smbclient -d8 -L localhost -U%
>INFO: Current debug levels:
>all: 8
>tdb: 8
>printdrivers: 8
>lanman: 8
>smb: 8
>rpc_parse: 8
>rpc_srv: 8
>rpc_cli: 8
>passdb: 8
>sam: 8
>auth: 8
>winbind: 8
>vfs: 8
>idmap: 8
>quota: 8
>acls: 8
>locking: 8
>msdfs: 8
>dmapi: 8
>registry: 8
>lp_load_ex: refreshing parameters
>Initialising global parameters
>rlimit_max: increasing rlimit_max (1024) to minimum Windows limit (16384)
>INFO: Current debug levels:
>all: 8
>tdb: 8
>printdrivers: 8
>lanman: 8
>smb: 8
>rpc_parse: 8
>rpc_srv: 8
>rpc_cli: 8
>passdb: 8
>sam: 8
>auth: 8
>winbind: 8
>vfs: 8
>idmap: 8
>quota: 8
>acls: 8
>locking: 8
>msdfs: 8
>dmapi: 8
>registry: 8
>params.c:pm_process() - Processing configuration file "/usr/local/samba/etc/smb.conf"
>Processing section "[global]"
>doing parameter workgroup = SIEGE
>doing parameter realm = bceao.int
>doing parameter netbios name = Z00-DC01
>doing parameter server role = active directory domain controller
>doing parameter idmap_ldb:use rfc2307 = yes
>doing parameter logfile = /usr/local/samba/log/samba.log
>doing parameter wins support = yes
>doing parameter hosts allow = 10.67.200.
>doing parameter load printers = no
>pm_process() returned Yes
>lp_servicenumber: couldn't find homes
>added interface eth0 ip=10.67.200.22 bcast=10.67.200.255 netmask=255.255.255.0
>added interface eth1 ip=10.185.200.68 bcast=10.185.201.255 netmask=255.255.254.0
>Netbios name list:-
>my_netbios_names[0]="Z00-DC01"
>Client started (version 4.0.6).
>Opening cache file at /usr/local/samba/var/lock/gencache.tdb
>Opening cache file at /usr/local/samba/var/lock/gencache_notrans.tdb
>sitename_fetch: No stored sitename for BCEAO.INT
>name localhost#20 found.
>Connecting to 127.0.0.1 at port 445
>Socket options:
>SO_KEEPALIVE = 0
>SO_REUSEADDR = 0
>SO_BROADCAST = 0
>TCP_NODELAY = 1
>TCP_KEEPCNT = 9
>TCP_KEEPIDLE = 7200
>TCP_KEEPINTVL = 75
>IPTOS_LOWDELAY = 0
>IPTOS_THROUGHPUT = 0
>SO_SNDBUF = 50748
>SO_RCVBUF = 87584
>SO_SNDLOWAT = 1
>SO_RCVLOWAT = 1
>SO_SNDTIMEO = 0
>SO_RCVTIMEO = 0
>TCP_QUICKACK = 1
>TCP_DEFER_ACCEPT = 0
>session request ok
>session setup failed: NT_STATUS_CONNECTION_REFUSED
>
>Here is the smb.conf file's content
>
># Global parameters
>[global]
>workgroup = SIEGE
>realm = bceao.int
>netbios name = Z00-DC01
>server role = active directory domain controller
>#dcerpc endpoint  servers = remote
>idmap_ldb:use rfc2307 = yes
>logfile = /usr/local/samba/log/samba.log
>wins support = yes
>hosts allow = 10.67.200.
>load printers = no
>
>[netlogon]
>path = /usr/local/samba/var/locks/sysvol/bceao.int/scripts
>read only = No
>
>[sysvol]
>path = /usr/local/samba/var/locks/sysvol
>read only = No
>[test]
>path = /var
>read only = No
>Please may have have you're help
>NB : the smbclient's version is 4.0.6
>
>
>MMe GUEI NOEE MELAINE
>BP 3108 DAKAR SENEGAL
>SERVICE INFORMATIQUE
>--
>To unsubscribe from this list go to the following URL and read the
>instructions:  https://lists.samba.org/mailman/options/samba
>


More information about the samba mailing list