Re: [Samba] Slow winbind lookups
Hiya, Having done horrific things (you don't want to know... believe me) I managed to remove the 'dead' server from my domain. No trace of it anywhere that I can find. The slowdown still remains. Can anyone point me in another direction I can persue? Thanks, Alex On 14/01/2013 11:18, Alex Matthews wrote: Hiya, I _might_ actually know what is causing this slow down. As I posted a while ago. My domain contains a 'dead' server that I am unable to remove. (post here: https://lists.samba.org/archive/samba/2012-December/170331.html) I think winbind is trying to connect to this dead server and timing out. Thus giving the delay. Is there any way to blacklist this server seeing as I am unable to remove it. Or would someone (Andrew??) Be willing to talk me through a way of manually removing it from my domain? Thanks, Alex On 10/01/2013 14:51, Alex Matthews wrote: On 10/01/2013 13:51, Hleb Valoshka wrote: On 1/10/13, Alex Matthews qoole.sa...@lillimoth.com wrote: wbinfo -u takes a long time to return a list of users I guess that if you attach output of strace wbinfo -u or may be even strace -f wbinfo -u you'll find assistance faster :) # strace -ftT wbinfo -u 14:09:01 execve(/usr/bin/wbinfo, [wbinfo, -u], [/* 37 vars */]) = 0 0.000259 14:09:01 brk(0) = 0xd9f000 0.31 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e4000 0.44 14:09:01 access(/etc/ld.so.preload, R_OK) = -1 ENOENT (No such file or directory) 0.30 14:09:01 open(/usr/lib64/tls/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.30 14:09:01 stat(/usr/lib64/tls/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/tls/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.23 14:09:01 stat(/usr/lib64/tls, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.42 14:09:01 open(/usr/lib64/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 stat(/usr/lib64/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = 3 0.28 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\240\347\0\0\0\0\0\0..., 832) = 832 0.29 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=214200, ...}) = 0 0.22 14:09:01 mmap(NULL, 2310096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113f9 0.24 14:09:01 mprotect(0x7f8113fc3000, 2093056, PROT_NONE) = 0 0.35 14:09:01 mmap(0x7f81141c2000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x32000) = 0x7f81141c2000 0.29 14:09:01 close(3) = 0 0.21 14:09:01 open(/usr/lib64/libwbclient.so.0, O_RDONLY|O_CLOEXEC) = 3 0.34 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0P#\0\0\0\0\0\0..., 832) = 832 0.23 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=43160, ...}) = 0 0.22 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e3000 0.23 14:09:01 mmap(NULL, 2145544, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113d84000 0.30 14:09:01 mprotect(0x7f8113d8e000, 2093056, PROT_NONE) = 0 0.33 14:09:01 mmap(0x7f8113f8d000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x9000) = 0x7f8113f8d000 0.26 14:09:01 mmap(0x7f8113f8f000, 3336, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f8113f8f000 0.24 14:09:01 close(3) = 0 0.26 14:09:01 open(/usr/lib64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 open(/usr/lib64/samba/tls/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/samba/tls/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.28 14:09:01 open(/usr/lib64/samba/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.22 14:09:01 stat(/usr/lib64/samba/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.27 14:09:01 open(/usr/lib64/samba/libreplace.so, O_RDONLY|O_CLOEXEC) = 3 0.29 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\220\16\0\0\0\0\0\0..., 832) = 832 0.22 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=10240, ...}) = 0 0.27 14:09:01 mmap(NULL, 2105896, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113b81000 0.30 14:09:01 mprotect(0x7f8113b83000, 2093056, PROT_NONE) = 0 0.45 14:09:01 mmap(0x7f8113d82000, 8192, PROT_READ|PROT_WRITE,
Re: [Samba] Slow winbind lookups
Hiya, I _might_ actually know what is causing this slow down. As I posted a while ago. My domain contains a 'dead' server that I am unable to remove. (post here: https://lists.samba.org/archive/samba/2012-December/170331.html) I think winbind is trying to connect to this dead server and timing out. Thus giving the delay. Is there any way to blacklist this server seeing as I am unable to remove it. Or would someone (Andrew??) Be willing to talk me through a way of manually removing it from my domain? Thanks, Alex On 10/01/2013 14:51, Alex Matthews wrote: On 10/01/2013 13:51, Hleb Valoshka wrote: On 1/10/13, Alex Matthews qoole.sa...@lillimoth.com wrote: wbinfo -u takes a long time to return a list of users I guess that if you attach output of strace wbinfo -u or may be even strace -f wbinfo -u you'll find assistance faster :) # strace -ftT wbinfo -u 14:09:01 execve(/usr/bin/wbinfo, [wbinfo, -u], [/* 37 vars */]) = 0 0.000259 14:09:01 brk(0) = 0xd9f000 0.31 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e4000 0.44 14:09:01 access(/etc/ld.so.preload, R_OK) = -1 ENOENT (No such file or directory) 0.30 14:09:01 open(/usr/lib64/tls/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.30 14:09:01 stat(/usr/lib64/tls/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/tls/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.23 14:09:01 stat(/usr/lib64/tls, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.42 14:09:01 open(/usr/lib64/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 stat(/usr/lib64/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = 3 0.28 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\240\347\0\0\0\0\0\0..., 832) = 832 0.29 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=214200, ...}) = 0 0.22 14:09:01 mmap(NULL, 2310096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113f9 0.24 14:09:01 mprotect(0x7f8113fc3000, 2093056, PROT_NONE) = 0 0.35 14:09:01 mmap(0x7f81141c2000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x32000) = 0x7f81141c2000 0.29 14:09:01 close(3) = 0 0.21 14:09:01 open(/usr/lib64/libwbclient.so.0, O_RDONLY|O_CLOEXEC) = 3 0.34 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0P#\0\0\0\0\0\0..., 832) = 832 0.23 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=43160, ...}) = 0 0.22 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e3000 0.23 14:09:01 mmap(NULL, 2145544, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113d84000 0.30 14:09:01 mprotect(0x7f8113d8e000, 2093056, PROT_NONE) = 0 0.33 14:09:01 mmap(0x7f8113f8d000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x9000) = 0x7f8113f8d000 0.26 14:09:01 mmap(0x7f8113f8f000, 3336, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f8113f8f000 0.24 14:09:01 close(3) = 0 0.26 14:09:01 open(/usr/lib64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 open(/usr/lib64/samba/tls/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/samba/tls/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.28 14:09:01 open(/usr/lib64/samba/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.22 14:09:01 stat(/usr/lib64/samba/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.27 14:09:01 open(/usr/lib64/samba/libreplace.so, O_RDONLY|O_CLOEXEC) = 3 0.29 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\220\16\0\0\0\0\0\0..., 832) = 832 0.22 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=10240, ...}) = 0 0.27 14:09:01 mmap(NULL, 2105896, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113b81000 0.30 14:09:01 mprotect(0x7f8113b83000, 2093056, PROT_NONE) = 0 0.45 14:09:01 mmap(0x7f8113d82000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1000) = 0x7f8113d82000 0.26 14:09:01 close(3) = 0 0.26 14:09:01 open(/usr/lib64/libsamba-hostconfig.so.0, O_RDONLY|O_CLOEXEC) = 3 0.44 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\\347\0\0\0\0\0\0..., 832) = 832
[Samba] Slow winbind lookups
Hi all, I have a Samba 4.0.0 domain running on a Gentoo box with a 3.7.0 kernel. I have added 'winbind' to the passwd and group lines in /etc/nsswitch.conf wbinfo -t returns immediately saying trust checking succeeded. wbinfo -g returns immediately with a list of groups wbinfo -u takes a long time to return a list of users # time wbinfo -u | wc -l 336 real0m4.211s user0m0.000s sys 0m0.000s 4s might not seem like a great deal but this delay seems to occur whenever anything looks up data from winbind. getent passwd also has a similar delay. It returns local users immediately but winbind users are delayed. Whilst gathering data for this post I have noticed that the results also seem to be sporadic. The following 3 commands were run in quick succession: # date time getent passwd | wc -l Thu Jan 10 09:41:22 GMT 2013 376 real0m5.677s user0m0.010s sys 0m0.000s # date time getent passwd | wc -l Thu Jan 10 09:41:29 GMT 2013 220 real0m2.633s user0m0.000s sys 0m0.000s # date time getent passwd | wc -l Thu Jan 10 09:41:32 GMT 2013 235 real0m4.014s user0m0.000s sys 0m0.010s Another example would be samba-tool sysvolreset: # time samba-tool ntacl sysvolreset real5m26.076s user3m7.500s sys 0m13.480s and if I disable winbind in nsswitch.conf # time samba-tool ntacl sysvolreset real1m13.851s user0m46.500s sys 0m3.140s (1m still seems to be a long time for this process to complete but I'll save that for my other post) Is this correct speed? Is there anything I can do to improve performance? Thanks, Alex -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba
Re: [Samba] Slow winbind lookups
On 1/10/13, Alex Matthews qoole.sa...@lillimoth.com wrote: wbinfo -u takes a long time to return a list of users I guess that if you attach output of strace wbinfo -u or may be even strace -f wbinfo -u you'll find assistance faster :) -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba
Re: [Samba] Slow winbind lookups
On 10/01/2013 13:51, Hleb Valoshka wrote: On 1/10/13, Alex Matthews qoole.sa...@lillimoth.com wrote: wbinfo -u takes a long time to return a list of users I guess that if you attach output of strace wbinfo -u or may be even strace -f wbinfo -u you'll find assistance faster :) # strace -ftT wbinfo -u 14:09:01 execve(/usr/bin/wbinfo, [wbinfo, -u], [/* 37 vars */]) = 0 0.000259 14:09:01 brk(0) = 0xd9f000 0.31 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e4000 0.44 14:09:01 access(/etc/ld.so.preload, R_OK) = -1 ENOENT (No such file or directory) 0.30 14:09:01 open(/usr/lib64/tls/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.30 14:09:01 stat(/usr/lib64/tls/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/tls/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.23 14:09:01 stat(/usr/lib64/tls, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.42 14:09:01 open(/usr/lib64/x86_64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 stat(/usr/lib64/x86_64, 0x7fffdba49910) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/libsamba-util.so.0, O_RDONLY|O_CLOEXEC) = 3 0.28 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\240\347\0\0\0\0\0\0..., 832) = 832 0.29 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=214200, ...}) = 0 0.22 14:09:01 mmap(NULL, 2310096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113f9 0.24 14:09:01 mprotect(0x7f8113fc3000, 2093056, PROT_NONE) = 0 0.35 14:09:01 mmap(0x7f81141c2000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x32000) = 0x7f81141c2000 0.29 14:09:01 close(3) = 0 0.21 14:09:01 open(/usr/lib64/libwbclient.so.0, O_RDONLY|O_CLOEXEC) = 3 0.34 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0P#\0\0\0\0\0\0..., 832) = 832 0.23 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=43160, ...}) = 0 0.22 14:09:01 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f81143e3000 0.23 14:09:01 mmap(NULL, 2145544, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113d84000 0.30 14:09:01 mprotect(0x7f8113d8e000, 2093056, PROT_NONE) = 0 0.33 14:09:01 mmap(0x7f8113f8d000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x9000) = 0x7f8113f8d000 0.26 14:09:01 mmap(0x7f8113f8f000, 3336, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f8113f8f000 0.24 14:09:01 close(3) = 0 0.26 14:09:01 open(/usr/lib64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.29 14:09:01 open(/usr/lib64/samba/tls/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.22 14:09:01 open(/usr/lib64/samba/tls/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.28 14:09:01 stat(/usr/lib64/samba/tls, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.28 14:09:01 open(/usr/lib64/samba/x86_64/libreplace.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.22 14:09:01 stat(/usr/lib64/samba/x86_64, 0x7fffdba498b0) = -1 ENOENT (No such file or directory) 0.27 14:09:01 open(/usr/lib64/samba/libreplace.so, O_RDONLY|O_CLOEXEC) = 3 0.29 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\0\220\16\0\0\0\0\0\0..., 832) = 832 0.22 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=10240, ...}) = 0 0.27 14:09:01 mmap(NULL, 2105896, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113b81000 0.30 14:09:01 mprotect(0x7f8113b83000, 2093056, PROT_NONE) = 0 0.45 14:09:01 mmap(0x7f8113d82000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1000) = 0x7f8113d82000 0.26 14:09:01 close(3) = 0 0.26 14:09:01 open(/usr/lib64/libsamba-hostconfig.so.0, O_RDONLY|O_CLOEXEC) = 3 0.44 14:09:01 read(3, \177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\0\1\0\0\\347\0\0\0\0\0\0..., 832) = 832 0.27 14:09:01 fstat(3, {st_mode=S_IFREG|0755, st_size=237984, ...}) = 0 0.21 14:09:01 mmap(NULL, 2333224, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8113947000 0.29 14:09:01 mprotect(0x7f8113979000, 2097152, PROT_NONE) = 0 0.34 14:09:01 mmap(0x7f8113b79000, 32768, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x32000) = 0x7f8113b79000 0.30 14:09:01 close(3) = 0 0.21 14:09:01 open(/usr/lib64/libcliauth.so, O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) 0.24 14:09:01