[Samba] samba-check-db-script python failure

Bob of Donelson Trophy bob at donelsontrophy.net
Thu Apr 23 09:22:35 MDT 2015


 

I went and got the newest (upped recently) script. No love. 

I removed the email address line to get more command line output. 

root at dc01:~# ./samba-check-db-repl.sh
Running with with console output
Running : /usr/bin/samba-tool ldapcmp --filter='whenChanged' ldap://dc01
ldap://dc02.dtsh***m.dt.
Please wait.. this can take a while..
Failed to bind - LDAP error 49 LDAP_INVALID_CREDENTIALS -
<SASL:[GSS-SPNEGO]: NT_STATUS_LOGON_FAILURE> <>
Failed to connect to 'ldap://dc02.dtsh***m.dt.' with backend 'ldap':
(null)
ERROR(ldb): uncaught exception - None
 File "/usr/lib/python2.7/dist-packages/samba/netcmd/__init__.py", line
175, in _run
 return self.run(*args, **kwargs)
 File "/usr/lib/python2.7/dist-packages/samba/netcmd/ldapcmp.py", line
968, in run
 outf=self.outf, errf=self.errf)
 File "/usr/lib/python2.7/dist-packages/samba/netcmd/ldapcmp.py", line
64, in __init__
 options=ldb_options)
 File "/usr/lib/python2.7/dist-packages/samba/__init__.py", line 114, in
__init__
 self.connect(url, flags, options)

.. Next check.. 
Running : samba-tool drs showrepl
./samba-check-db-repl.sh: line 284: [: 0: unary operator expected
./samba-check-db-repl.sh: line 287: [: 0: unary operator expected 

Thoughts? 
---

-------------------------

Bob Wooden of Donelson Trophy

615.885.2846 (main)
www.donelsontrophy.com [1]

"Everyone deserves an award!!"

On 2015-04-23 09:05, L.P.H. van Belle wrote: 

> Hai Bob, 
> 
> ah.. LDAP_INVALID_CREDENTIALS, this is not a python error, but password error.. ;-) 
> 
> i upped a new version of samba-check-db-repl.sh 
> ( direct link : https://secure.bazuin.nl/scripts/samba-check-db-repl.sh [3]) 
> small change in the install of the mail tools section. 
> 
> A bit info for this version.
> ## Version : 1.0.3
> ## release d.d. : 22-04-2015
> ## moved mailx part within checks if an e-mail adres is used.
> 
> ## Samba database checker. ( DB check up to 10 samba DC's ) 
> ## This script wil check for error in the samba databases with samba-tool
> 
> ## NOTICE !! This script does only work with samba DC's 
> ## A samba DC + Windows Dc wont work and is not tested, if you get that to work, 
> ## please share the code ;-) 
> 
> The script wil find the DC with FSMO roles, and matches all other dc's with the one containing the FSMO roles.
> tested with samba 4.1.17 and 4.2.1 ( debian wheezy ) 
> 
> Gr. 
> 
> Louis
> 
>> -----Oorspronkelijk bericht----- Van: bob at donelsontrophy.net [mailto:samba-bounces at lists.samba.org] Namens Bob of Donelson Trophy Verzonden: donderdag 23 april 2015 15:48 Aan: SAMBA MailList Onderwerp: [Samba] samba-check-db-script python failure When I run ./samba-check-db-repl.sh script I am getting the following: root at dc01:~# ./samba-check-db-repl.sh Failed to bind - LDAP error 49 LDAP_INVALID_CREDENTIALS - <SASL:[GSS-SPNEGO]: NT_STATUS_LOGON_FAILURE> <> Failed to connect to 'ldap://dc02.dtsh**m.dt.' with backend 'ldap': (null) ERROR(ldb): uncaught exception - None File "/usr/lib/python2.7/dist-packages/samba/netcmd/__init__.py", line 175, in _run return self.run(*args, **kwargs) File "/usr/lib/python2.7/dist-packages/samba/netcmd/ldapcmp.py", line 968, in run outf=self.outf, errf=self.errf) File "/usr/lib/python2.7/dist-packages/samba/netcmd/ldapcmp.py", line 64, in __init__ options=ldb_options) File "/usr/lib/python2.7/dist-packages/samba/__init__.py", line 114, in __
 init__
self.connect(url, flags, options) ./samba-check-db-repl.sh: line 257: [: 0: unary operator expected What would the "unary operator expected" issue be? -- ------------------------- Bob Wooden of Donelson Trophy 615.885.2846 (main) www.donelsontrophy.com [1] [1 [1]] "Everyone deserves an award!!" Links: ------ [1] http://www.donelsontrophy.com [1] -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba [2]
 

Links:
------
[1] http://www.donelsontrophy.com
[2] https://lists.samba.org/mailman/options/samba
[3] https://secure.bazuin.nl/scripts/samba-check-db-repl.sh


More information about the samba mailing list