All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Dilger <adilger@dilger.ca>
To: Pavel Machek <pavel@ucw.cz>
Cc: Theodore Ts'o <tytso@mit.edu>,
	Ext4 Developers List <linux-ext4@vger.kernel.org>
Subject: Re: ext4: media error but where?
Date: Fri, 4 Jul 2014 16:18:41 -0600	[thread overview]
Message-ID: <D1E29C34-308C-4906-A697-BB383600226B@dilger.ca> (raw)
In-Reply-To: <20140704203309.GA28107@amd.pavel.ucw.cz>

[-- Attachment #1: Type: text/plain, Size: 2148 bytes --]


On Jul 4, 2014, at 2:33 PM, Pavel Machek <pavel@ucw.cz> wrote:

> On Fri 2014-07-04 13:17:37, Andreas Dilger wrote:
>> Maybe it is worthwhile to improve this error message to be:
>> 
>>    EXT4-fs (sda3): initial error at time 1401714179: ...
> 
> I'm glad you suggested it. I actually done a patch before reading
> this. What about:

Looks good to me.  There have been a few users confused by these messages
already, so it is nice to make them a bit more clear.

Reviewed-by: Andreas Dilger <adilger@dilger.ca>

> ---
> 
> Make it clear that values printed are times, and that it is error
> since last fsck. Also add note about fsck version required.
> 
> Signed-off-by: Pavel Machek <pavel@ucw.cz>
> 
> diff --git a/fs/ext4/super.c b/fs/ext4/super.c
> index b9b9aab..3423947 100644
> --- a/fs/ext4/super.c
> +++ b/fs/ext4/super.c
> @@ -2809,10 +2809,11 @@ static void print_daily_error_info(unsigned long arg)
> 	es = sbi->s_es;
> 
> 	if (es->s_error_count)
> -		ext4_msg(sb, KERN_NOTICE, "error count: %u",
> +		/* fsck newer than v1.41.13 is needed to clean this condition. */
> +		ext4_msg(sb, KERN_NOTICE, "error count since last fsck: %u",
> 			 le32_to_cpu(es->s_error_count));
> 	if (es->s_first_error_time) {
> -		printk(KERN_NOTICE "EXT4-fs (%s): initial error at %u: %.*s:%d",
> +		printk(KERN_NOTICE "EXT4-fs (%s): initial error at time %u: %.*s:%d",
> 		       sb->s_id, le32_to_cpu(es->s_first_error_time),
> 		       (int) sizeof(es->s_first_error_func),
> 		       es->s_first_error_func,
> @@ -2826,7 +2827,7 @@ static void print_daily_error_info(unsigned long arg)
> 		printk("\n");
> 	}
> 	if (es->s_last_error_time) {
> -		printk(KERN_NOTICE "EXT4-fs (%s): last error at %u: %.*s:%d",
> +		printk(KERN_NOTICE "EXT4-fs (%s): last error at time %u: %.*s:%d",
> 		       sb->s_id, le32_to_cpu(es->s_last_error_time),
> 		       (int) sizeof(es->s_last_error_func),
> 		       es->s_last_error_func,
> 
> -- 
> (english) http://www.livejournal.com/~pavelmachek
> (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html


Cheers, Andreas






[-- Attachment #2: Message signed with OpenPGP using GPGMail --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2014-07-04 22:18 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-26 20:20 ext4: total breakdown on USB hdd, 3.0 kernel Pavel Machek
2014-06-26 20:30 ` Pavel Machek
2014-06-26 20:50   ` Pavel Machek
2014-06-27  2:48     ` Theodore Ts'o
2014-06-27  2:46   ` Theodore Ts'o
2014-06-29 20:25     ` Pavel Machek
2014-06-29 21:04       ` Theodore Ts'o
2014-06-30  6:46         ` Pavel Machek
2014-06-30 13:43           ` Theodore Ts'o
2014-07-04 10:23             ` ext4: media error but where? Pavel Machek
2014-07-04 12:11               ` Theodore Ts'o
2014-07-04 17:21                 ` Pavel Machek
2014-07-04 18:06                   ` Pavel Machek
2014-07-04 18:56                   ` Theodore Ts'o
2014-07-06 13:32                     ` Pavel Machek
2014-07-06 13:43                       ` Pavel Machek
2014-07-06 18:29                         ` Theodore Ts'o
2014-07-06 21:37                           ` Pavel Machek
2014-07-07  1:00                             ` Theodore Ts'o
2014-07-07 18:55                               ` Pavel Machek
2014-07-07 23:18                                 ` 3.16-rc, ext4: oopses, OOMs after hard powerdown Pavel Machek
2014-07-07 23:21                                 ` ext4: media error but where? Theodore Ts'o
2014-07-04 19:17                   ` Andreas Dilger
2014-07-04 20:33                     ` Pavel Machek
2014-07-04 22:18                       ` Andreas Dilger [this message]
2014-07-05 22:17                       ` Theodore Ts'o
2014-06-27  8:23 ` ext4: total breakdown on USB hdd, 3.0 kernel Oliver Neukum

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=D1E29C34-308C-4906-A697-BB383600226B@dilger.ca \
    --to=adilger@dilger.ca \
    --cc=linux-ext4@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=tytso@mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.