* [PATCH] xfs: show error code when printing writeback error messages.
@ 2019-08-01 10:03 Tetsuo Handa
2019-08-01 10:38 ` Dave Chinner
0 siblings, 1 reply; 3+ messages in thread
From: Tetsuo Handa @ 2019-08-01 10:03 UTC (permalink / raw)
To: linux-xfs; +Cc: Tetsuo Handa
Even without backtraces, including error code should be helpful.
[ 630.162595][ T9218] XFS (sda1): writeback error -12 on sector 131495992
[ 631.718685][ T9432] XFS (sda1): writeback error -12 on sector 131503928
[ 632.015588][ T442] XFS (sda1): writeback error -12 on sector 157773936
Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
---
fs/xfs/xfs_aops.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c
index f16d5f196c6b..d2c9076643cf 100644
--- a/fs/xfs/xfs_aops.c
+++ b/fs/xfs/xfs_aops.c
@@ -112,7 +112,7 @@ xfs_destroy_ioend(
if (unlikely(error && !quiet)) {
xfs_err_ratelimited(XFS_I(inode)->i_mount,
- "writeback error on sector %llu", start);
+ "writeback error %d on sector %llu", error, start);
}
}
--
2.16.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] xfs: show error code when printing writeback error messages.
2019-08-01 10:03 [PATCH] xfs: show error code when printing writeback error messages Tetsuo Handa
@ 2019-08-01 10:38 ` Dave Chinner
2019-08-26 19:01 ` Darrick J. Wong
0 siblings, 1 reply; 3+ messages in thread
From: Dave Chinner @ 2019-08-01 10:38 UTC (permalink / raw)
To: Tetsuo Handa; +Cc: linux-xfs
On Thu, Aug 01, 2019 at 07:03:46PM +0900, Tetsuo Handa wrote:
> Even without backtraces, including error code should be helpful.
>
> [ 630.162595][ T9218] XFS (sda1): writeback error -12 on sector 131495992
> [ 631.718685][ T9432] XFS (sda1): writeback error -12 on sector 131503928
> [ 632.015588][ T442] XFS (sda1): writeback error -12 on sector 157773936
>
> Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
> ---
> fs/xfs/xfs_aops.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c
> index f16d5f196c6b..d2c9076643cf 100644
> --- a/fs/xfs/xfs_aops.c
> +++ b/fs/xfs/xfs_aops.c
> @@ -112,7 +112,7 @@ xfs_destroy_ioend(
>
> if (unlikely(error && !quiet)) {
> xfs_err_ratelimited(XFS_I(inode)->i_mount,
> - "writeback error on sector %llu", start);
> + "writeback error %d on sector %llu", error, start);
If you are going to do this, make the error message properly useful.
Report the inode number and the ioend offset and length so we know
what file and where in the file the writeback failure occurred.
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] xfs: show error code when printing writeback error messages.
2019-08-01 10:38 ` Dave Chinner
@ 2019-08-26 19:01 ` Darrick J. Wong
0 siblings, 0 replies; 3+ messages in thread
From: Darrick J. Wong @ 2019-08-26 19:01 UTC (permalink / raw)
To: Dave Chinner; +Cc: Tetsuo Handa, linux-xfs
On Thu, Aug 01, 2019 at 08:38:51PM +1000, Dave Chinner wrote:
> On Thu, Aug 01, 2019 at 07:03:46PM +0900, Tetsuo Handa wrote:
> > Even without backtraces, including error code should be helpful.
> >
> > [ 630.162595][ T9218] XFS (sda1): writeback error -12 on sector 131495992
> > [ 631.718685][ T9432] XFS (sda1): writeback error -12 on sector 131503928
> > [ 632.015588][ T442] XFS (sda1): writeback error -12 on sector 157773936
> >
> > Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
> > ---
> > fs/xfs/xfs_aops.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c
> > index f16d5f196c6b..d2c9076643cf 100644
> > --- a/fs/xfs/xfs_aops.c
> > +++ b/fs/xfs/xfs_aops.c
> > @@ -112,7 +112,7 @@ xfs_destroy_ioend(
> >
> > if (unlikely(error && !quiet)) {
> > xfs_err_ratelimited(XFS_I(inode)->i_mount,
> > - "writeback error on sector %llu", start);
> > + "writeback error %d on sector %llu", error, start);
>
> If you are going to do this, make the error message properly useful.
> Report the inode number and the ioend offset and length so we know
> what file and where in the file the writeback failure occurred.
Ping?
--D
> Cheers,
>
> Dave.
> --
> Dave Chinner
> david@fromorbit.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-08-26 19:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-01 10:03 [PATCH] xfs: show error code when printing writeback error messages Tetsuo Handa
2019-08-01 10:38 ` Dave Chinner
2019-08-26 19:01 ` Darrick J. Wong
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox