A inicialização da tela do GNU é muito lenta

2

Eu me conecto a um servidor RHEL 5.7 via Putty ou VNC (não tenho certeza se importa), mas quando tento executar screen , ele leva para sempre (na ordem de 20 a 30 segundos). A mesma coisa se eu executar screen -ls , demora o mesmo tempo.

Eu não sei se isso tem a ver com onde screen está configurado? Mas quando vou para $HOME , não há nenhum arquivo .screenrc . (Então, onde está? Eu li que posso definir minha própria localização, então talvez seja um ponto menor ...)

screen -vScreen version 4.00.03 (FAU) 23-Oct-06

Alguém tem idéias sobre o que o problema poderia ser ou é apenas do jeito que é?

Atualização 2

  1. Tentei definir variáveis de ambiente $SCREENDIR e $SCREENRC para ~/.screenrc e para um local no servidor /home/myusername = sem alteração
  2. Eu tentei um .screenrc file = no change
  3. Eu tentei adicionar defnonblock on a .screenrc = sem alteração
  4. Também tentei executar o Strace com a opção -f adicional, mas não percebeu nenhuma nova informação?

arquivo strace # 2, snippet 1 , primeira ocorrência desse número engraçado 4294967295

11:24:23 connect(4, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0
11:24:23 sendto(4, "<14>Jun 25 11:24:23 screen: nss_"..., 129, MSG_NOSIGNAL, NULL, 0) = 129
11:24:23 write(3, "
11:24:28 recvfrom(3, "6!10
09:10:05 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor)
09:10:05 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor)
09:10:05 close(4294967295)              = -1 EBADF (Bad file descriptor)
09:10:05 sendto(4, "<14>Jun 25 09:10:05 screen: nss_"..., 89, MSG_NOSIGNAL, NULL, 0) = 89
09:10:05 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
09:10:05 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0
09:10:05 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
09:10:05 nanosleep({4, 0}, {4, 0})      = 0
09:10:12 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0
09:10:12 geteuid()                      = 287621
09:10:12 open("/etc/hosts", O_RDONLY)   = 3
09:10:12 fcntl(3, F_GETFD)              = 0
...
09:10:20 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor)
09:10:20 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor)
09:10:20 close(4294967295)              = -1 EBADF (Bad file descriptor)
09:10:20 sendto(4, "<14>Jun 25 09:10:20 screen: nss_"..., 90, MSG_NOSIGNAL, NULL, 0) = 90
09:10:20 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
09:10:20 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0
09:10:20 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
09:10:20 nanosleep({16, 0}, {16, 0})    = 0
09:10:36 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0
09:10:36 geteuid()                      = 287621
09:10:36 open("/etc/hosts", O_RDONLY)   = 3
09:10:36 fcntl(3, F_GETFD)              = 0
...
09:10:36 write(3, "
11:24:23 connect(4, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0
11:24:23 sendto(4, "<14>Jun 25 11:24:23 screen: nss_"..., 129, MSG_NOSIGNAL, NULL, 0) = 129
11:24:23 write(3, "
11:24:28 recvfrom(3, "6!10
09:10:05 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor)
09:10:05 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor)
09:10:05 close(4294967295)              = -1 EBADF (Bad file descriptor)
09:10:05 sendto(4, "<14>Jun 25 09:10:05 screen: nss_"..., 89, MSG_NOSIGNAL, NULL, 0) = 89
09:10:05 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
09:10:05 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0
09:10:05 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
09:10:05 nanosleep({4, 0}, {4, 0})      = 0
09:10:12 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0
09:10:12 geteuid()                      = 287621
09:10:12 open("/etc/hosts", O_RDONLY)   = 3
09:10:12 fcntl(3, F_GETFD)              = 0
...
09:10:20 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor)
09:10:20 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor)
09:10:20 close(4294967295)              = -1 EBADF (Bad file descriptor)
09:10:20 sendto(4, "<14>Jun 25 09:10:20 screen: nss_"..., 90, MSG_NOSIGNAL, NULL, 0) = 90
09:10:20 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
09:10:20 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0
09:10:20 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
09:10:20 nanosleep({16, 0}, {16, 0})    = 0
09:10:36 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0
09:10:36 geteuid()                      = 287621
09:10:36 open("/etc/hosts", O_RDONLY)   = 3
09:10:36 fcntl(3, F_GETFD)              = 0
...
09:10:36 write(3, "%pre%P4sL-y64%pre%5!hd21Q55K0r22", 32) = 32 
09:10:36 write(3, "%pre%V4{t240k1337V06m1I0xw", 27) = 27 
09:10:36 shutdown(3, 2 /* send and receive */) = 0 
09:10:36 close(3)                       = 0 
09:10:36 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor) 
09:10:36 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 
09:10:36 close(4294967295)              = -1 EBADF (Bad file descriptor) 
09:10:36 sendto(4, "<14>Jun 25 09:10:36 screen: nss_"..., 90, MSG_NOSIGNAL, NULL, 0) = 90 
09:10:36 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 
09:10:36 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 
09:10:36 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 
09:10:36 nanosleep({32, 0}, {32, 0})    = 0 
09:11:08 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 
09:11:08 geteuid()                      = 287621 
09:11:08 open("/etc/hosts", O_RDONLY)   = 3 
09:11:08 fcntl(3, F_GETFD)              = 0 
09:11:08 fcntl(3, F_SETFD, FD_CLOEXEC)  = 0 
...
09:11:08 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 
09:11:08 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 
09:11:08 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 
09:11:08 nanosleep({64, 0}, {64, 0})    = 0 
09:12:12 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 
09:12:12 geteuid()                      = 287621 
09:12:12 open("/etc/hosts", O_RDONLY)   = 3 
09:12:12 fcntl(3, F_GETFD)              = 0 
%pre%%pre%%pre%%pre%%pre%unixauthcscompany"..., 1024, 0, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("987.654.321.09")}, [16]) = 86 11:24:28 close(3) = 0 11:24:28 socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3 11:24:28 fcntl(3, F_SETFD, FD_CLOEXEC) = 0 11:24:28 setsockopt(3, SOL_SOCKET, SO_KEEPALIVE, [1], 4) = 0 11:24:28 setsockopt(3, SOL_TCP, TCP_NODELAY, [1], 4) = 0 11:24:28 fcntl(3, F_GETFL) = 0x2 (flags O_RDWR) 11:24:28 fcntl(3, F_SETFL, O_RDWR|O_NONBLOCK) = 0 11:24:28 connect(3, {sa_family=AF_INET, sin_port=htons(636), sin_addr=inet_addr("123.456.789.01")}, 16) = -1 EINPROGRESS (Operation now in progress) 11:24:28 poll([{fd=3, events=POLLOUT|POLLERR|POLLHUP}], 1, 90000) = 1 ([{fd=3, revents=POLLOUT}]) 11:24:28 getpeername(3, {sa_family=AF_INET, sin_port=htons(636), sin_addr=inet_addr("123.456.789.01")}, [4294967312]) = 0 11:24:28 fcntl(3, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK) 11:24:28 fcntl(3, F_SETFL, O_RDWR) = 0 11:24:28 write(3, "0w%pre%N%pre%%pre%%pre% %pre%%pre%09%pre%%pre%08%pre%%pre%05%pre%%pre%%pre%%pre%%pre%%pre%\n%pre%0"..., 121) = 121 11:24:28 read(3, "%pre%Q%pre%", 7) = 7 11:24:28 read(3, "%pre%M^0737165Q3226@227T4767Jl"..., 79) = 79 11:24:28 read(3, "6", 5) = 5 11:24:28 read(3, "\v%pre%2%pre%7%pre%20260260\v4/0\r\t"..., 3822) = 3822 11:24:28 read(3, "%pre%", 5) = 5 11:24:28 read(3, "%pre%%pre%%pre%", 4) = 4 11:24:28 write(3, "%pre%6%pre%%pre%2%pre%0+JE5344I3g@&m275336"..., 186) = 186 11:24:28 read(3, "%pre%", 5) = 5 11:24:28 read(3, "", 1) = 1 11:24:28 read(3, "%pre%$", 5) = 5 11:24:28 read(3, "j320R473/17062473132=2k%pre%y7\[5"..., 36) = 36 11:24:28 write(3, "%pre%464424p5j?16#d0]1611555jj3"..., 145) = 145 11:24:28 poll([{fd=3, events=POLLIN|POLLPRI|POLLERR|POLLHUP}], 1, 90000) = 1 ([{fd=3, revents=POLLIN}]) 11:24:28 read(3, "%pre%5", 5) = 5 11:24:28 read(3, "s57J32\r13v27729335j*K605,\r5"..., 173) = 173 11:24:28 sendto(4, "<14>Jun 25 11:24:28 screen: nss_"..., 129, MSG_NOSIGNAL, NULL, 0) = 129 11:24:28 write(3, "%pre%Heq7(66i4H2mO7d;&5f20H", 32) = 32 11:24:28 write(3, "%pre%5760a6733e%pre%[3262f67[ ", 27) = 27 11:24:28 shutdown(3, 2 /* send and receive */) = 0 11:24:28 close(3) = 0 11:24:28 read(4294967295, 0xe5d3350, 5) = -1 EBADF (Bad file descriptor) 11:24:28 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 11:24:28 close(4294967295) = -1 EBADF (Bad file descriptor) 11:24:28 sendto(4, "<14>Jun 25 11:24:28 screen: nss_"..., 89, MSG_NOSIGNAL, NULL, 0) = 89 11:24:28 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 11:24:28 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 11:24:28 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 11:24:28 nanosleep({8, 0}, {8, 0}) = 0
114MD4s5ia1!0&570434gz6l", 32) = 32 11:24:23 write(3, "%pre%45w737624.T2;'EQ2z54", 27) = 27 11:24:23 shutdown(3, 2 /* send and receive */) = 0 11:24:23 close(3) = 0 11:24:23 read(4294967295, 0xe5d3350, 5) = -1 EBADF (Bad file descriptor) 11:24:23 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 11:24:23 close(4294967295) = -1 EBADF (Bad file descriptor) 11:24:23 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 11:24:23 geteuid() = 287621 11:24:23 open("/etc/hosts", O_RDONLY) = 3
P4sL-y64%pre%5!hd21Q55K0r22", 32) = 32 09:10:36 write(3, "%pre%V4{t240k1337V06m1I0xw", 27) = 27 09:10:36 shutdown(3, 2 /* send and receive */) = 0 09:10:36 close(3) = 0 09:10:36 read(4294967295, 0xca3b350, 5) = -1 EBADF (Bad file descriptor) 09:10:36 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 09:10:36 close(4294967295) = -1 EBADF (Bad file descriptor) 09:10:36 sendto(4, "<14>Jun 25 09:10:36 screen: nss_"..., 90, MSG_NOSIGNAL, NULL, 0) = 90 09:10:36 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 09:10:36 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 09:10:36 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 09:10:36 nanosleep({32, 0}, {32, 0}) = 0 09:11:08 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 09:11:08 geteuid() = 287621 09:11:08 open("/etc/hosts", O_RDONLY) = 3 09:11:08 fcntl(3, F_GETFD) = 0 09:11:08 fcntl(3, F_SETFD, FD_CLOEXEC) = 0 ... 09:11:08 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 09:11:08 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 09:11:08 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 09:11:08 nanosleep({64, 0}, {64, 0}) = 0 09:12:12 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 09:12:12 geteuid() = 287621 09:12:12 open("/etc/hosts", O_RDONLY) = 3 09:12:12 fcntl(3, F_GETFD) = 0
%pre%%pre%%pre%%pre%%pre%unixauthcscompany"..., 1024, 0, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("987.654.321.09")}, [16]) = 86 11:24:28 close(3) = 0 11:24:28 socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3 11:24:28 fcntl(3, F_SETFD, FD_CLOEXEC) = 0 11:24:28 setsockopt(3, SOL_SOCKET, SO_KEEPALIVE, [1], 4) = 0 11:24:28 setsockopt(3, SOL_TCP, TCP_NODELAY, [1], 4) = 0 11:24:28 fcntl(3, F_GETFL) = 0x2 (flags O_RDWR) 11:24:28 fcntl(3, F_SETFL, O_RDWR|O_NONBLOCK) = 0 11:24:28 connect(3, {sa_family=AF_INET, sin_port=htons(636), sin_addr=inet_addr("123.456.789.01")}, 16) = -1 EINPROGRESS (Operation now in progress) 11:24:28 poll([{fd=3, events=POLLOUT|POLLERR|POLLHUP}], 1, 90000) = 1 ([{fd=3, revents=POLLOUT}]) 11:24:28 getpeername(3, {sa_family=AF_INET, sin_port=htons(636), sin_addr=inet_addr("123.456.789.01")}, [4294967312]) = 0 11:24:28 fcntl(3, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK) 11:24:28 fcntl(3, F_SETFL, O_RDWR) = 0 11:24:28 write(3, "0w%pre%N%pre%%pre%%pre% %pre%%pre%09%pre%%pre%08%pre%%pre%05%pre%%pre%%pre%%pre%%pre%%pre%\n%pre%0"..., 121) = 121 11:24:28 read(3, "%pre%Q%pre%", 7) = 7 11:24:28 read(3, "%pre%M^0737165Q3226@227T4767Jl"..., 79) = 79 11:24:28 read(3, "6", 5) = 5 11:24:28 read(3, "\v%pre%2%pre%7%pre%20260260\v4/0\r\t"..., 3822) = 3822 11:24:28 read(3, "%pre%", 5) = 5 11:24:28 read(3, "%pre%%pre%%pre%", 4) = 4 11:24:28 write(3, "%pre%6%pre%%pre%2%pre%0+JE5344I3g@&m275336"..., 186) = 186 11:24:28 read(3, "%pre%", 5) = 5 11:24:28 read(3, "", 1) = 1 11:24:28 read(3, "%pre%$", 5) = 5 11:24:28 read(3, "j320R473/17062473132=2k%pre%y7\[5"..., 36) = 36 11:24:28 write(3, "%pre%464424p5j?16#d0]1611555jj3"..., 145) = 145 11:24:28 poll([{fd=3, events=POLLIN|POLLPRI|POLLERR|POLLHUP}], 1, 90000) = 1 ([{fd=3, revents=POLLIN}]) 11:24:28 read(3, "%pre%5", 5) = 5 11:24:28 read(3, "s57J32\r13v27729335j*K605,\r5"..., 173) = 173 11:24:28 sendto(4, "<14>Jun 25 11:24:28 screen: nss_"..., 129, MSG_NOSIGNAL, NULL, 0) = 129 11:24:28 write(3, "%pre%Heq7(66i4H2mO7d;&5f20H", 32) = 32 11:24:28 write(3, "%pre%5760a6733e%pre%[3262f67[ ", 27) = 27 11:24:28 shutdown(3, 2 /* send and receive */) = 0 11:24:28 close(3) = 0 11:24:28 read(4294967295, 0xe5d3350, 5) = -1 EBADF (Bad file descriptor) 11:24:28 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 11:24:28 close(4294967295) = -1 EBADF (Bad file descriptor) 11:24:28 sendto(4, "<14>Jun 25 11:24:28 screen: nss_"..., 89, MSG_NOSIGNAL, NULL, 0) = 89 11:24:28 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 11:24:28 rt_sigaction(SIGCHLD, NULL, {SIG_DFL, [], 0}, 8) = 0 11:24:28 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 11:24:28 nanosleep({8, 0}, {8, 0}) = 0
114MD4s5ia1!0&570434gz6l", 32) = 32 11:24:23 write(3, "%pre%45w737624.T2;'EQ2z54", 27) = 27 11:24:23 shutdown(3, 2 /* send and receive */) = 0 11:24:23 close(3) = 0 11:24:23 read(4294967295, 0xe5d3350, 5) = -1 EBADF (Bad file descriptor) 11:24:23 shutdown(4294967295, 2 /* send and receive */) = -1 EBADF (Bad file descriptor) 11:24:23 close(4294967295) = -1 EBADF (Bad file descriptor) 11:24:23 stat("/etc/ldap.conf", {st_mode=S_IFREG|0644, st_size=10681, ...}) = 0 11:24:23 geteuid() = 287621 11:24:23 open("/etc/hosts", O_RDONLY) = 3

Nova teoria : Entre as chamadas nanosleep , vejo que está fazendo algo com um servidor de autenticação unix. O que está fazendo ou porque ... eu não sei. Mas então esta linha aparece

sendto(4, "<14>Jun 25 11:24:28 screen: nss_"..., 129, MSG_NOSIGNAL, NULL, 0) = 129

e não consigo ler a mensagem de erro inteira ?? Então, as linhas "Bad file descriptor" aparecem, e bam , indo dormir novamente. Poder entender o que está fazendo com o servidor unix auth é fundamental para entender esses atrasos?

arquivo strace # 2, snippet 2 , ampliando o que acontece antes de os sleeps ocorrerem. Alterou o nome da empresa e os endereços IP para valores fictícios.

%pre%

Atualização 1 Aqui está o strace bits interessantes ... Eu vejo que está fazendo nanosleep repetidamente (cada um dobrando o tempo de sono), mas por quê?

%pre%     
por user1766760 25.06.2013 / 17:28

1 resposta

0

Quando encontramos isso, nosso gênio de operações residente reduziu-o a um servidor LDAP lento. A correção de curto prazo era remover o servidor LDAP ofensivo do arquivo /etc/ldap.conf .

    
por 08.07.2014 / 22:55