All of lore.kernel.org
 help / color / mirror / Atom feed
* possible reiser4 bug
@ 2006-02-24  5:35 Alec Burney
  2006-02-25 21:09 ` Alexander Zarochentsev
  0 siblings, 1 reply; 7+ messages in thread
From: Alec Burney @ 2006-02-24  5:35 UTC (permalink / raw)
  To: reiserfs-list

i have been experiencing hard locks (preceded by intense 5< load
averages, disk i/o timeouts, and processes gone astray) that seem to
be related to a possible bug in reiser4.
here is the information that i think is important:

 a sample dmesg from right before a hardlock:
------------[ cut here ]------------
kernel BUG at fs/reiser4/plugin/file/tail_conversion.c:29!
invalid opcode: 0000 [#1]
SMP
last sysfs file: /class/vc/vcsa7/dev
Modules linked in: snd_rtctimer
CPU:    0
EIP:    0060:[<c019c3bb>]    Not tainted VLI
EFLAGS: 00210282   (2.6.16-rc3-mm1 #1)
EIP is at get_exclusive_access+0x1b/0x44
eax: eec1b1ac   ebx: ecda70d8   ecx: ecda7140   edx: 00000000
esi: addee000   edi: eec1b160   ebp: 00000000   esp: dfd89f38
ds: 007b   es: 007b   ss: 0068
Process soffice.bin (pid: 11208, threadinfo=dfd89000 task=e1193a70)
Stack: <0>00000001 c019b956 c013f613 eecbfb74 e8daa560 00000001
00005600 00000000
       ecda70d8 ecda7140 addee000 ea8ea7c0 00005600 d06d2740 00005600 ea8ea7c0
       c03b0e10 00000000 c014bbf3 dfd89fa4 addee000 ea8ea7c0 fffffff7 bfb4a870
Call Trace:
 <c019b956> write_unix_file+0x2a4/0x44b   <c013f613> vma_link+0xa2/0xbc
 <c014bbf3> vfs_write+0xab/0x14c   <c014bd32> sys_write+0x3c/0x62
 <c01025bf> sysenter_past_esp+0x54/0x75
Code: 8d 43 10 e8 5c 54 1a 00 e9 f8 fc ff ff 90 90 90 53 89 c3 b8 00
f0 ff ff 21 e0 8b 00 8b 80 c8 04 00 00 8b 40 48 83 78 0c 00 74 08 <0f>
0b 1d 00 e0 58 36 c0 e8 28 61 1a 00 ba 01 00 ff ff 89 d8 f0

my uname -a:
Linux helix 2.6.16-rc3-mm1 #1 SMP Sun Feb 19 21:46:21 HST 2006 i686
AMD Athlon(tm) MP 2600+ AuthenticAMD GNU/Linux

my fsck.reiser4 -V
fsck.reiser4 1.0.5
Copyright (C) 2001, 2002, 2003, 2004 by Hans Reiser, licensing
governed by reiser4progs/COPYING.

my fsck.reiser4 -p from a drive known to be causing trouble
Default profiles:
format:     "format40" (id:0x0 type:0x8)
journal:    "journal40" (id:0x0 type:0xf)
oid:        "oid40" (id:0x0 type:0x9)
alloc:      "alloc40" (id:0x0 type:0xe)
key:        "key_large" (id:0x1 type:0x10)
node:       "node40" (id:0x0 type:0x2)
statdata:   "stat40" (id:0x0 type:0x1)
nodeptr:    "nodeptr40" (id:0x3 type:0x1)
direntry:   "cde40" (id:0x2 type:0x1)
tail:       "plain40" (id:0x6 type:0x1)
extent:     "extent40" (id:0x5 type:0x1)
acl:        "absent (id:0x4 type:0x1)"
permission: "absent (id:0x0 type:0x6)"
regular:    "reg40" (id:0x0 type:0x0)
directory:  "dir40" (id:0x1 type:0x0)
symlink:    "sym40" (id:0x2 type:0x0)
special:    "spl40" (id:0x3 type:0x0)
hash:       "r5_hash" (id:0x1 type:0x3)
fibration:  "ext_1_fibre" (id:0x2 type:0x4)
formatting: "smart" (id:0x2 type:0x5)


the partition in question is 232903996 kilobytes large (that's 223
gigabytes), and does not fail badblocks or fsck.reiser4 testing. my
system holds up to memtest86, and does not crash if the drive is not
mounted and used.


my question: can this be fixed, has it been fixed, or can i convert
this drive online to reiserfs.
sorry for such a long message, but this is very important to me. thank you!

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
  2006-02-25 21:09 ` Alexander Zarochentsev
@ 2006-02-25 11:17   ` James (Alec) Burney
  2006-02-26  2:33   ` Francesco Biscani
  1 sibling, 0 replies; 7+ messages in thread
From: James (Alec) Burney @ 2006-02-25 11:17 UTC (permalink / raw)
  To: Alexander Zarochentsev; +Cc: reiserfs-list

thanks for the patch, Alex, but yesterday i converted all of my
harddisks to reiserFS in an act of frustration. Sorry that i can't help
you test your patch.

Alexander Zarochentsev wrote:
> hello,
> 
> On Friday 24 February 2006 08:35, Alec Burney wrote:
> 
> [...]
> 
> 
> would you please try the attached patch.
> 
> 
> 
> ------------------------------------------------------------------------
> 
>  fs/reiser4/plugin/file/file.c |    9 +++++----
>  1 files changed, 5 insertions(+), 4 deletions(-)
> 
> Index: linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
> ===================================================================
> --- linux-2.6.16-rc3-mm1.orig/fs/reiser4/plugin/file/file.c
> +++ linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
> @@ -2454,6 +2454,7 @@ ssize_t write_unix_file(struct file *fil
>  
>  	if (inode_get_flag(inode, REISER4_PART_CONV)) {
>  		/* we can not currently write to a file which is partially converted */
> +		txn_restart(ctx);
>  		get_exclusive_access(uf_info);
>  		result = finish_conversion(inode);
>  		drop_exclusive_access(uf_info);
> @@ -2481,6 +2482,7 @@ ssize_t write_unix_file(struct file *fil
>  
>  		   3) convert file to extents to not enter here on each write
>  		   to mmaped file */
> +		txn_restart(ctx);
>  		get_exclusive_access(uf_info);
>  		result = check_pages_unix_file(file, inode);
>  		drop_exclusive_access(uf_info);
> @@ -2535,14 +2537,13 @@ ssize_t write_unix_file(struct file *fil
>  	while (left > 0) {
>  		int excl = 0;
>  
> -		/* getting exclusive or not exclusive access requires no
> -		   transaction open */
> -		txn_restart_current();
> -
>  		/* faultin user page */
>  		fault_in_pages_readable(buf,
>  					left > PAGE_CACHE_SIZE ? PAGE_CACHE_SIZE : left);
>  
> +		/* getting exclusive or not exclusive access requires no
> +		   transaction open */
> +		txn_restart(ctx);
>  		if (inode->i_size == 0) {
>  			get_exclusive_access(uf_info);
>  			excl = 1;

-- 
cell: 808.332.5131

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
  2006-02-24  5:35 possible reiser4 bug Alec Burney
@ 2006-02-25 21:09 ` Alexander Zarochentsev
  2006-02-25 11:17   ` James (Alec) Burney
  2006-02-26  2:33   ` Francesco Biscani
  0 siblings, 2 replies; 7+ messages in thread
From: Alexander Zarochentsev @ 2006-02-25 21:09 UTC (permalink / raw)
  To: reiserfs-list; +Cc: Alec Burney

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

hello,

On Friday 24 February 2006 08:35, Alec Burney wrote:
> i have been experiencing hard locks (preceded by intense 5< load
> averages, disk i/o timeouts, and processes gone astray) that seem to
> be related to a possible bug in reiser4.
> here is the information that i think is important:
>
>  a sample dmesg from right before a hardlock:
> ------------[ cut here ]------------
> kernel BUG at fs/reiser4/plugin/file/tail_conversion.c:29!
> invalid opcode: 0000 [#1]
> SMP
> last sysfs file: /class/vc/vcsa7/dev 
> Modules linked in: snd_rtctimer
> CPU:    0
> EIP:    0060:[<c019c3bb>]    Not tainted VLI
> EFLAGS: 00210282   (2.6.16-rc3-mm1 #1)
> EIP is at get_exclusive_access+0x1b/0x44
> eax: eec1b1ac   ebx: ecda70d8   ecx: ecda7140   edx: 00000000
> esi: addee000   edi: eec1b160   ebp: 00000000   esp: dfd89f38
> ds: 007b   es: 007b   ss: 0068
> Process soffice.bin (pid: 11208, threadinfo=dfd89000 task=e1193a70)
> Stack: <0>00000001 c019b956 c013f613 eecbfb74 e8daa560 00000001
> 00005600 00000000
>        ecda70d8 ecda7140 addee000 ea8ea7c0 00005600 d06d2740 00005600
> ea8ea7c0 c03b0e10 00000000 c014bbf3 dfd89fa4 addee000 ea8ea7c0
> fffffff7 bfb4a870 Call Trace:
>  <c019b956> write_unix_file+0x2a4/0x44b   <c013f613>
> vma_link+0xa2/0xbc <c014bbf3> vfs_write+0xab/0x14c   <c014bd32>
> sys_write+0x3c/0x62 <c01025bf> sysenter_past_esp+0x54/0x75
> Code: 8d 43 10 e8 5c 54 1a 00 e9 f8 fc ff ff 90 90 90 53 89 c3 b8 00
> f0 ff ff 21 e0 8b 00 8b 80 c8 04 00 00 8b 40 48 83 78 0c 00 74 08
> <0f> 0b 1d 00 e0 58 36 c0 e8 28 61 1a 00 ba 01 00 ff ff 89 d8 f0
>

[...]

> my question: can this be fixed, has it been fixed, or can i convert
> this drive online to reiserfs.
> sorry for such a long message, but this is very important to me.
> thank you!

would you please try the attached patch.

-- 
Alex.

[-- Attachment #2: reiser4-unix_file_write-get_exclusive_access-carefully.diff --]
[-- Type: text/x-diff, Size: 1471 bytes --]

 fs/reiser4/plugin/file/file.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

Index: linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
===================================================================
--- linux-2.6.16-rc3-mm1.orig/fs/reiser4/plugin/file/file.c
+++ linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
@@ -2454,6 +2454,7 @@ ssize_t write_unix_file(struct file *fil
 
 	if (inode_get_flag(inode, REISER4_PART_CONV)) {
 		/* we can not currently write to a file which is partially converted */
+		txn_restart(ctx);
 		get_exclusive_access(uf_info);
 		result = finish_conversion(inode);
 		drop_exclusive_access(uf_info);
@@ -2481,6 +2482,7 @@ ssize_t write_unix_file(struct file *fil
 
 		   3) convert file to extents to not enter here on each write
 		   to mmaped file */
+		txn_restart(ctx);
 		get_exclusive_access(uf_info);
 		result = check_pages_unix_file(file, inode);
 		drop_exclusive_access(uf_info);
@@ -2535,14 +2537,13 @@ ssize_t write_unix_file(struct file *fil
 	while (left > 0) {
 		int excl = 0;
 
-		/* getting exclusive or not exclusive access requires no
-		   transaction open */
-		txn_restart_current();
-
 		/* faultin user page */
 		fault_in_pages_readable(buf,
 					left > PAGE_CACHE_SIZE ? PAGE_CACHE_SIZE : left);
 
+		/* getting exclusive or not exclusive access requires no
+		   transaction open */
+		txn_restart(ctx);
 		if (inode->i_size == 0) {
 			get_exclusive_access(uf_info);
 			excl = 1;

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
  2006-02-25 21:09 ` Alexander Zarochentsev
  2006-02-25 11:17   ` James (Alec) Burney
@ 2006-02-26  2:33   ` Francesco Biscani
  2006-02-26  7:33     ` Alexander Zarochentsev
  1 sibling, 1 reply; 7+ messages in thread
From: Francesco Biscani @ 2006-02-26  2:33 UTC (permalink / raw)
  To: reiserfs-list; +Cc: Alexander Zarochentsev, Alec Burney

On Saturday 25 February 2006 22:09, Alexander Zarochentsev wrote:
> would you please try the attached patch.

I'm having a similar problem on 2.6.16-rc4 + reiser4 from -mm1. I will be 
testing the attached patch.

Regards,

  Francesco

-- 
Dr. Francesco Biscani
Dipartimento di Astronomia
Università di Padova
biscani@pd.astro.it

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
  2006-02-26  2:33   ` Francesco Biscani
@ 2006-02-26  7:33     ` Alexander Zarochentsev
  2006-02-28 13:46       ` Francesco Biscani
  0 siblings, 1 reply; 7+ messages in thread
From: Alexander Zarochentsev @ 2006-02-26  7:33 UTC (permalink / raw)
  To: reiserfs-list; +Cc: Francesco Biscani

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

On Sunday 26 February 2006 05:33, Francesco Biscani wrote:
> On Saturday 25 February 2006 22:09, Alexander Zarochentsev wrote:
> > would you please try the attached patch.
>
> I'm having a similar problem on 2.6.16-rc4 + reiser4 from -mm1. I
> will be testing the attached patch.

please use better version of the patch (attached).

> Regards,
>
>   Francesco

-- 
Alex.

[-- Attachment #2: reiser4-unix_file_write-get_exclusive_access-carefully.diff --]
[-- Type: text/x-diff, Size: 2674 bytes --]

 fs/reiser4/plugin/file/file.c            |    9 +++++----
 fs/reiser4/plugin/item/extent_file_ops.c |    2 +-
 fs/reiser4/vfs_ops.c                     |    5 ++++-
 3 files changed, 10 insertions(+), 6 deletions(-)

Index: linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
===================================================================
--- linux-2.6.16-rc3-mm1.orig/fs/reiser4/plugin/file/file.c
+++ linux-2.6.16-rc3-mm1/fs/reiser4/plugin/file/file.c
@@ -2454,6 +2454,7 @@ ssize_t write_unix_file(struct file *fil
 
 	if (inode_get_flag(inode, REISER4_PART_CONV)) {
 		/* we can not currently write to a file which is partially converted */
+		txn_restart(ctx);
 		get_exclusive_access(uf_info);
 		result = finish_conversion(inode);
 		drop_exclusive_access(uf_info);
@@ -2481,6 +2482,7 @@ ssize_t write_unix_file(struct file *fil
 
 		   3) convert file to extents to not enter here on each write
 		   to mmaped file */
+		txn_restart(ctx);
 		get_exclusive_access(uf_info);
 		result = check_pages_unix_file(file, inode);
 		drop_exclusive_access(uf_info);
@@ -2535,14 +2537,13 @@ ssize_t write_unix_file(struct file *fil
 	while (left > 0) {
 		int excl = 0;
 
-		/* getting exclusive or not exclusive access requires no
-		   transaction open */
-		txn_restart_current();
-
 		/* faultin user page */
 		fault_in_pages_readable(buf,
 					left > PAGE_CACHE_SIZE ? PAGE_CACHE_SIZE : left);
 
+		/* getting exclusive or not exclusive access requires no
+		   transaction open */
+		txn_restart(ctx);
 		if (inode->i_size == 0) {
 			get_exclusive_access(uf_info);
 			excl = 1;
Index: linux-2.6.16-rc3-mm1/fs/reiser4/vfs_ops.c
===================================================================
--- linux-2.6.16-rc3-mm1.orig/fs/reiser4/vfs_ops.c
+++ linux-2.6.16-rc3-mm1/fs/reiser4/vfs_ops.c
@@ -209,8 +209,11 @@ void writeout(struct super_block *sb, st
 
 void reiser4_throttle_write(struct inode *inode)
 {
-	txn_restart_current();
+	reiser4_context *ctx = get_current_context();
+
+	txn_restart(ctx);
 	balance_dirty_pages_ratelimited(inode->i_mapping);
+	txn_restart(ctx);
 }
 
 const char *REISER4_SUPER_MAGIC_STRING = "ReIsEr4";
Index: linux-2.6.16-rc3-mm1/fs/reiser4/plugin/item/extent_file_ops.c
===================================================================
--- linux-2.6.16-rc3-mm1.orig/fs/reiser4/plugin/item/extent_file_ops.c
+++ linux-2.6.16-rc3-mm1/fs/reiser4/plugin/item/extent_file_ops.c
@@ -803,7 +803,7 @@ extent_balance_dirty_pages(struct inode 
 		fault_in_pages_readable(f->data,
 					f->length > PAGE_CACHE_SIZE ?
 					PAGE_CACHE_SIZE : f->length);
-
+		txn_restart_current();
 		if (excl)
 			get_exclusive_access(uf_info);
 		else

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
  2006-02-26  7:33     ` Alexander Zarochentsev
@ 2006-02-28 13:46       ` Francesco Biscani
  0 siblings, 0 replies; 7+ messages in thread
From: Francesco Biscani @ 2006-02-28 13:46 UTC (permalink / raw)
  To: reiserfs-list; +Cc: Alexander Zarochentsev

On Sunday 26 February 2006 08:33, Alexander Zarochentsev wrote:
> please use better version of the patch (attached).

Hello,

  after some days of testing the problem seems gone. The kernel survived many 
CPU and I/O intensive tasks (some compilations of gcc and firefox) without an 
hiccup, whereas without the patch it hanged quite soon.

Thanks and regards,

  Francesco

-- 
Dr. Francesco Biscani
Dipartimento di Astronomia
Università di Padova
biscani@pd.astro.it

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: possible reiser4 bug
@ 2006-03-10 19:51 Maarten Deprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez
  0 siblings, 0 replies; 7+ messages in thread
From: Maarten Deprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez @ 2006-03-10 19:51 UTC (permalink / raw)
  To: reiserfs-list

Alexander Zarochentsev wrote:
> please use better version of the patch (attached).

Also tried the patch and it seems problem with linux 2.6.16-rc2-mm1 is
gone. Not much tested, but it always crashed when accessing a
particular file, and that's fixed now. For me, this can be included in
official sources.

Thanks,
Maarten Deprez

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2006-03-10 19:51 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-24  5:35 possible reiser4 bug Alec Burney
2006-02-25 21:09 ` Alexander Zarochentsev
2006-02-25 11:17   ` James (Alec) Burney
2006-02-26  2:33   ` Francesco Biscani
2006-02-26  7:33     ` Alexander Zarochentsev
2006-02-28 13:46       ` Francesco Biscani
  -- strict thread matches above, loose matches on Subject: below --
2006-03-10 19:51 Maarten Deprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez, maartendeprez

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.