Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 14 Jun 2009 17:49:38 +0200
From:      Pawel Jakub Dawidek <pjd@FreeBSD.org>
To:        "James R. Van Artsdalen" <james-freebsd-current@jrv.org>
Cc:        freebsd-fs@FreeBSD.org, Kip Macy <kip.macy@gmail.com>, FreeBSD Current <freebsd-current@FreeBSD.org>, Thomas Backman <serenity@exscape.org>
Subject:   Re: ZFS: Silent/hidden errors, nothing logged anywhere
Message-ID:  <20090614154938.GC1848@garage.freebsd.pl>
In-Reply-To: <4A3411EF.5000307@jrv.org>
References:  <920A69B1-4F06-477E-A13B-63CC22A13120@exscape.org> <3c1674c90906121401s19105167vf4535566321b45de@mail.gmail.com> <20090613150627.GB1848@garage.freebsd.pl> <4A3411EF.5000307@jrv.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--mvpLiMfbWzRoNl4x
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sat, Jun 13, 2009 at 03:54:07PM -0500, James R. Van Artsdalen wrote:
> Pawel Jakub Dawidek wrote:
> >
> > We do log such errors. Solaris uses FMA and for FreeBSD I use devd. You
> > can find the following entry in /etc/devd.conf:
> >
> > notify 10 {
> >         match "system"          "ZFS";
> >         match "type"            "checksum";
> >         action "logger -p kern.warn 'ZFS: checksum mismatch, zpool=3D$p=
ool path=3D$vdev_path offset=3D$zio_offset size=3D$zio_size'";
> > };
> >
> > If you see nothing in your logs, there must be a bug with reporting the
> > problem somewhere or devd is not running (it should be enabled by
> > default).
> >  =20
>=20
> Looking at vsyslog(3), I don't think logger(1) can ever log with
> facility KERN.  LOG_KERN is 0, so this in vsyslog
>=20
>           /* Set default facility if none specified. */
>           if ((pri & LOG_FACMASK) =3D=3D 0)
>                  pri |=3D LogFacility;
>=20
> will always change the KERN facility is to LogFacility, which defaults
> to LOG_USER.
> =20
> So the devd output is really going to user.warn and a syslog.conf line li=
ke
>=20
> kern.*                                          /var/log/kernel.log
>=20
> will capture kernel messages, but not the devd logger output, and if you
> look in kernel.log you won't find the checksum errors.

Could be, I'm most of the time just use *.* /var/log/all.log.

We could easly log directly from inside the kernel, but this is just an
example devd entry so one can replace it with, eg. mailing the problem
to the system administrator or whatever.

--=20
Pawel Jakub Dawidek                       http://www.wheel.pl
pjd@FreeBSD.org                           http://www.FreeBSD.org
FreeBSD committer                         Am I Evil? Yes, I Am!

--mvpLiMfbWzRoNl4x
Content-Type: application/pgp-signature
Content-Disposition: inline

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

iD8DBQFKNRwSForvXbEpPzQRAlJwAKC/wgqzMzX+/LO2A4YqY8Rm6DAk6ACgrgQh
ONb32i62rHj7RVg8J8PwZrE=
=OCAq
-----END PGP SIGNATURE-----

--mvpLiMfbWzRoNl4x--



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