Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 2 Jul 2012 18:32:32 -0400
From:      Alexander Kabaev <kabaev@gmail.com>
To:        Yuri <yuri@rawbw.com>
Cc:        freebsd-hackers@FreeBSD.org
Subject:   Re: System is flooded with failed read(2) calls: Resource temporarily unavailable (errno=35) coming from xorg unix socket
Message-ID:  <20120702183232.037dda59@kan.dyndns.org>
In-Reply-To: <4FEE0D2F.4010808@rawbw.com>
References:  <4FEE0D2F.4010808@rawbw.com>

next in thread | previous in thread | raw e-mail | index | archive | help
--Sig_/LxNGpS6jFIS.aanY2qxGxc=
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable

On Fri, 29 Jun 2012 13:16:47 -0700
Yuri <yuri@rawbw.com> wrote:

<SKIP>
> #  Declare DTrace script
> #
>   if ($COUNT) {          # aggregate style
> $dtrace =3D <<END;
> /usr/sbin/dtrace -n '
>          #pragma D option quiet
>          syscall:::return
>          /errno !=3D 0 && pid !=3D \$pid $FILTER/
>          {
>                  \@Errs[execname, probefunc, errno] =3D count();
>          }
>          dtrace:::END {
>                  printa("%s %s %d %\@d\\n", \@Errs);
>          }'
> END

Pardon my possibly naive question, but isn't using errno to detect
whether the syscall is succesful a wrong techique? Syscall will NOT
change errno unless unless it actually failed, so unless dtrace's errno
emulation is more magic than I thought, your script will mistakenly
attribute error code coming from a distant past to syscalls just
complete with no errors?
--=20
Alexander Kabaev

--Sig_/LxNGpS6jFIS.aanY2qxGxc=
Content-Type: application/pgp-signature; name=signature.asc
Content-Disposition: attachment; filename=signature.asc

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (FreeBSD)

iD8DBQFP8iGFQ6z1jMm+XZYRArNDAJ9oo+vJ6KbVEWIlYrI7K0sx7KaQ2gCdHKUs
0KRbUNhVYkzCXZ2dE1xIaII=
=VMIB
-----END PGP SIGNATURE-----

--Sig_/LxNGpS6jFIS.aanY2qxGxc=--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120702183232.037dda59>