Date: Thu, 4 Mar 2010 10:31:41 +1100 From: John Marshall <john.marshall@riverwillow.com.au> To: freebsd-stable@freebsd.org Subject: Re: sleep(3) sometimes too sleepy on FreeBSD 8.0? Message-ID: <20100303233141.GC4420@rwpc12.mby.riverwillow.net.au> In-Reply-To: <20100225111407.GE14464@rwpc12.mby.riverwillow.net.au> References: <20100223013522.GE2303@rwpc12.mby.riverwillow.net.au> <20100224075359.GA61876@server.vk2pj.dyndns.org> <20100224112139.GT50403@deviant.kiev.zoral.com.ua> <20100224114441.GA57760@icarus.home.lan> <20100224122045.GU50403@deviant.kiev.zoral.com.ua> <20100224124101.GC14464@rwpc12.mby.riverwillow.net.au> <20100224163803.GW50403@deviant.kiev.zoral.com.ua> <20100225111407.GE14464@rwpc12.mby.riverwillow.net.au>
next in thread | previous in thread | raw e-mail | index | archive | help
--0ntfKIWw70PvrIHh Content-Type: multipart/mixed; boundary="+HP7ph2BbKc20aGI" Content-Disposition: inline --+HP7ph2BbKc20aGI Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, 25 Feb 2010, 22:14 +1100, John Marshall wrote: > Another thing I did was to patch the sendmail build config on another > one of the servers, and rebuild, so that sendmail's sleep() would simply > call FreeBSD's nanosleep(2). I have asked on comp.mail.sendmail if > anyone knows why the sendmail build only enbles use of nanosleep on > Solaris. After checking with jhb@ re appropriate value of __FreeBSD_version for the test, I have submitted a build configuration patch to the sendmail folks so that a sendmail build on FreeBSD >=3D 300000 will use nanosleep(). The patch has been accepted by sendmail and is attached for reference. > SERVER 1 > - FreeBSD 8.0-RELEASE-p2 > - Sendmail 8.14.4 (modified so that sleep() uses nanosleep(2)) >=20 > SERVER 2 > - FreeBSD 8.0-RELEASE-p2 > - Sendmail 8.14.4 >=20 > SERVER 3 > - FreeBSD 8-STABLE > - Sendmail 8.14.4 >=20 > ...and then watch sendmail on all three. One week has elapsed and no queue runners have succumbed to excessive drowsiness. --=20 John Marshall --+HP7ph2BbKc20aGI Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="include_sm_conf.h.diff" --- include/sm/conf.h.orig 2009-06-17 09:41:32.000000000 +1000 +++ include/sm/conf.h 2010-02-27 09:31:33.000000000 +1100 @@ -1014,6 +1014,9 @@ # if __FreeBSD_version >= 222000 /* 2.2.2-release and later */ # define HASSETUSERCONTEXT 1 /* BSDI-style login classes */ # endif /* __FreeBSD_version >= 222000 */ +# if __FreeBSD_version >= 300000 /* 3.0.0-release and later */ +# define HAVE_NANOSLEEP 1 /* has nanosleep(2) */ +# endif /* __FreeBSD_version >= 300000 */ # if __FreeBSD_version >= 330000 /* 3.3.0-release and later */ # ifndef SMRSH_CMDDIR # define SMRSH_CMDDIR "/usr/libexec/sm.bin" --+HP7ph2BbKc20aGI-- --0ntfKIWw70PvrIHh Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkuO8V0ACgkQw/tAaKKahKIRPACgyJkBCNMupz1+ek2JWkqpoTSc 4WcAoIjve3uqoTgi66GaGxKSxRQQW+Wo =bbmV -----END PGP SIGNATURE----- --0ntfKIWw70PvrIHh--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100303233141.GC4420>