[PYTHON] Possible bugs revealed by socket_wrapper

Noel Power nopower at suse.com
Tue Nov 13 14:38:53 UTC 2018


hmm, I get something similar and believe I can reproduce this on leap 15

using your branch

tmux

make testenv SELFTEST_TESTENV=chgdcpass SCREEN=1

exit # exiting without running any test

and then I get...


[...]

127.0.0.32 CHGDCPASS<00>
waiting for working LDAP and a RID Set to be allocated
checking the NETLOGON for domain[CHDCDOMAIN] dc connection to 
"chgdcpass.chgdcpassword.samba.example.com" succeeded
SAMBA LOG of: CHGDCPASS pid 25248
SWRAP_ERROR[tmux (25261)] - find_socket_info_index: The max socket index 
limit of 262140 has been reached, trying to add 2147483647
SWRAP_ERROR[tmux (25320)] - find_socket_info_index: The max socket index 
limit of 262140 has been reached, trying to add 2147483647
teardown_env(chgdcpass)
samba child process 25248 exited with value 0


ALL OK (0 tests in 0 testsuites)

A summary with detailed information can be found in:
   ./st/summary
TOP 10 slowest tests
'testonly' finished successfully (30.167s)

On 12/11/2018 17:42, Andreas Schneider via samba-technical wrote:
> Hi,
>
> we have socket_wrapper 1.2.0 with threading support ready. So I've 
> pushed the
> changes to the gitlab CI to see if everything is working.
>
> It doesn't work and revealed some bugs :-)
>
> New in socket_wrapper 1.2.0 is that we have a default limit of 
> handling 65535
> open sockets! This can be increased if needed. However if we try to 
> setup the
> chgdcpass environment samba-tool wants to open 1 million sockets!
>
> It is running:
>
> python ./bin/samba-tool domainprovision --configfile=/home/gitlab-runner/
> samba/st/chgdcpass/etc/smb.conf --host-name=chgdcpass 
> --host-ip=127.0.0.32 --
> quiet --domain=CHDCDOMAIN --realm=CHGDCPASSWORD.SAMBA.EXAMPLE.COM 
> --domain-
> sid=S-1-5-21-1879926001-2232171230-2460190490 --adminpass=chgDCpass1 --
> krbtgtpass=krbtgtchgDCpass1 --machinepass=machinechgDCpass1 --root=gitlab-
> runner --server-role=domain controller --function-level=2008 --dns-
> backend=BIND9_DLZ
>
> Which after some time starts to report that it reached the limit!
>
> ...
> SWRAP_ERROR[python (20259)] - find_socket_info_index: The max socket index
> limit of 65535 has been reached, trying to add 65855
> SWRAP_ERROR[python (20259)] - find_socket_info_index: The max socket index
> limit of 65535 has been reached, trying to add 65856
> ...
>
>
> This is either a python bug in Ubuntu 14.04 leaking file descriptors 
> (sockets)
> or an issue with our code and that python version.
>
>
>
> I'm not able to reproduce this locally on a modern Linux system, 
> Fedora 29!
>
>
>
>
> Reproducer:
> docker run -ti registry.gitlab.com/samba-team/samba:latest /bin/bash
>
> sudo -i
> apt-get install tmux
> logout
>
> tmux
> git clone git://git.samba.org/asn/samba.git
> cd samba
> git checkout master-swrap
> ./configure --enable-developer
> make -j8
>
> make -j8 testenv SELFTEST_TESTENV=chgdcpass SCREEN=1
>
>
>



More information about the samba-technical mailing list