From owner-freebsd-current Fri Mar 21 15: 0:39 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9A2CF37B401 for ; Fri, 21 Mar 2003 15:00:35 -0800 (PST) Received: from h00609772adf0.ne.client2.attbi.com (h00609772adf0.ne.client2.attbi.com [24.61.43.152]) by mx1.FreeBSD.org (Postfix) with ESMTP id BEEF743F75 for ; Fri, 21 Mar 2003 15:00:34 -0800 (PST) (envelope-from rodrigc@attbi.com) Received: from h00609772adf0.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by h00609772adf0.ne.client2.attbi.com (8.12.7/8.12.7) with ESMTP id h2LN0ZOM042015 for ; Fri, 21 Mar 2003 18:00:35 -0500 (EST) (envelope-from rodrigc@h00609772adf0.ne.client2.attbi.com) Received: (from rodrigc@localhost) by h00609772adf0.ne.client2.attbi.com (8.12.7/8.12.7/Submit) id h2LN0ZZq042014 for freebsd-current@freebsd.org; Fri, 21 Mar 2003 18:00:35 -0500 (EST) Date: Fri, 21 Mar 2003 18:00:35 -0500 From: Craig Rodrigues To: freebsd-current@freebsd.org Subject: Apache Portable Runtime testcase hangs -current Message-ID: <20030321230035.GA41982@attbi.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="vtzGhvizbBRQ85DL" Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --vtzGhvizbBRQ85DL Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, I am using a system which I cvsup'd a few weeks ago: FreeBSD 5.0-CURRENT FreeBSD 5.0-CURRENT #18: Mon Feb 24 06:06:47 EST 2003 rodrigc@h00609772adf0.ne.client2.attbi.com:/usr/obj/usr/src/sys/MYKERNEL1 i386 I tried to compile the latest beta version of the Apache Portable Runtime library. As part of the configure process, the attached testcase is run. When the testcase runs, my machine locks up *HARD*. - keyboard is totally unresponsive - network connectivity to machine is lost and I cannot telnet or ssh into the box Does anyone have any idea what the problem could be? How stable is -current to work with if I cvsup and rebuild? Thanks. -- Craig Rodrigues http://home.attbi.com/~rodrigc rodrigc@attbi.com --vtzGhvizbBRQ85DL Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="apr_network_test.c" #if 0 dnl dnl see if TCP_NODELAY setting is inherited from listening sockets dnl AC_DEFUN(APR_CHECK_TCP_NODELAY_INHERITED,[ AC_CACHE_CHECK(if TCP_NODELAY setting is inherited from listening sockets, ac_cv_tcp_nodelay_inherited,[ AC_TRY_RUN( [ #endif /* if 0 */ #define HAVE_SYS_TYPES_H 1 #define HAVE_SYS_SOCKET_H 1 #define HAVE_NETINET_IN_H 1 #define HAVE_NETINET_TCP_H 1 #define HAVE_SOCKLEN_T 1 #include #ifdef HAVE_SYS_TYPES_H #include #endif #ifdef HAVE_SYS_SOCKET_H #include #endif #ifdef HAVE_NETINET_IN_H #include #endif #ifdef HAVE_NETINET_TCP_H #include #endif #ifndef HAVE_SOCKLEN_T typedef int socklen_t; #endif int main(void) { int listen_s, connected_s, client_s; int listen_port, rc; struct sockaddr_in sa; socklen_t sa_len; socklen_t option_len; int option; listen_s = socket(AF_INET, SOCK_STREAM, 0); if (listen_s < 0) { perror("socket"); exit(1); } option = 1; rc = setsockopt(listen_s, IPPROTO_TCP, TCP_NODELAY, &option, sizeof option); if (rc < 0) { perror("setsockopt TCP_NODELAY"); exit(1); } memset(&sa, 0, sizeof sa); sa.sin_family = AF_INET; #ifdef BEOS sa.sin_addr.s_addr = htonl(INADDR_LOOPBACK); #endif /* leave port 0 to get ephemeral */ rc = bind(listen_s, (struct sockaddr *)&sa, sizeof sa); if (rc < 0) { perror("bind for ephemeral port"); exit(1); } /* find ephemeral port */ sa_len = sizeof(sa); rc = getsockname(listen_s, (struct sockaddr *)&sa, &sa_len); if (rc < 0) { perror("getsockname"); exit(1); } listen_port = sa.sin_port; rc = listen(listen_s, 5); if (rc < 0) { perror("listen"); exit(1); } client_s = socket(AF_INET, SOCK_STREAM, 0); if (client_s < 0) { perror("socket"); exit(1); } memset(&sa, 0, sizeof sa); sa.sin_family = AF_INET; sa.sin_port = listen_port; #ifdef BEOS sa.sin_addr.s_addr = htonl(INADDR_LOOPBACK); #endif /* leave sin_addr all zeros to use loopback */ rc = connect(client_s, (struct sockaddr *)&sa, sizeof sa); if (rc < 0) { perror("connect"); exit(1); } sa_len = sizeof sa; connected_s = accept(listen_s, (struct sockaddr *)&sa, &sa_len); if (connected_s < 0) { perror("accept"); exit(1); } option_len = sizeof option; rc = getsockopt(connected_s, IPPROTO_TCP, TCP_NODELAY, &option, &option_len); if (rc < 0) { perror("getsockopt"); exit(1); } if (!option) { fprintf(stderr, "TCP_NODELAY is not set in the child.\n"); exit(1); } return 0; } #if 0 ],[ ac_cv_tcp_nodelay_inherited="yes" ],[ ac_cv_tcp_nodelay_inherited="no" ],[ ac_cv_tcp_nodelay_inherited="yes" ])]) if test "$ac_cv_tcp_nodelay_inherited" = "yes"; then tcp_nodelay_inherited=1 else tcp_nodelay_inherited=0 fi ]) #endif --vtzGhvizbBRQ85DL-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message