All of lore.kernel.org
 help / color / mirror / Atom feed
* [Ocfs2-devel]  What's your opinion on the patch to fix bug 58 for kernel 2.6 porting?
@ 2004-04-28 21:11 Zhang, Sonic
  2004-04-29 12:34 ` Mark Fasheh
  0 siblings, 1 reply; 5+ messages in thread
From: Zhang, Sonic @ 2004-04-28 21:11 UTC (permalink / raw)
  To: ocfs2-devel

Hi Mark,

	Do you have any opinion on the patch to fix bug 58 for kernel
2.6 porting?
	Could you add the patch into the source tree? 

	Thank you.


*********************************************
Sonic Zhang
Software Engineer
Intel China Software Lab
Tel: (086)021-52574545-1667
iNet: 752-1667
********************************************* 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: ocfs2-inode-count.patch
Type: application/octet-stream
Size: 2910 bytes
Desc: ocfs2-inode-count.patch
Url : http://oss.oracle.com/pipermail/ocfs2-devel/attachments/20040429/445ff5c9/ocfs2-inode-count.obj

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

* [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting?
  2004-04-28 21:11 [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting? Zhang, Sonic
@ 2004-04-29 12:34 ` Mark Fasheh
  0 siblings, 0 replies; 5+ messages in thread
From: Mark Fasheh @ 2004-04-29 12:34 UTC (permalink / raw)
  To: ocfs2-devel

Well, to be perfectly honest I don't think this is the right solution.
Instead of peppering the code with signal stuff, why not try to figure out
what the timing issue is (it seems that the umount thread should wait on
pending operations) and fix it that way?
	--Mark

On Thu, Apr 29, 2004 at 10:10:56AM +0800, Zhang, Sonic wrote:
> Hi Mark,
> 
> 	Do you have any opinion on the patch to fix bug 58 for kernel
> 2.6 porting?
> 	Could you add the patch into the source tree? 
> 
> 	Thank you.
> 
> 
> *********************************************
> Sonic Zhang
> Software Engineer
> Intel China Software Lab
> Tel: (086)021-52574545-1667
> iNet: 752-1667
> ********************************************* 
> 


> _______________________________________________
> Ocfs2-devel mailing list
> Ocfs2-devel@oss.oracle.com
> http://oss.oracle.com/mailman/listinfo/ocfs2-devel

--
Mark Fasheh
Software Developer, Oracle Corp
mark.fasheh@oracle.com

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

* [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting?
@ 2004-04-29 20:20 Zhang, Sonic
  2004-04-30 11:57 ` Joel Becker
  0 siblings, 1 reply; 5+ messages in thread
From: Zhang, Sonic @ 2004-04-29 20:20 UTC (permalink / raw)
  To: ocfs2-devel

Hi Mark,

	In kernel 2.6 VFS routine sys_umount()->...->generic_shutdown_super(), =
if the inode usage count i_count is not 0, error information is =
reported. Then, the system will halt in routine =
kill_bdev()->truncate_inode_pages().
	If we don't fix it in OCFS2 driver, we have to change the kernel 2.6 =
VFS sys_umount code. Is it a good solution?

	Thanks.


*********************************************
Sonic Zhang
Software Engineer
Intel China Software Lab
Tel: (086)021-52574545-1667
iNet: 752-1667
*********************************************=20

-----Original Message-----
From: Mark Fasheh [mailto:mark.fasheh@oracle.com]=20
Sent: 2004=C4=EA4=D4=C230=C8=D5 1:32
To: Zhang, Sonic
Cc: Ocfs2-Devel
Subject: Re: [Ocfs2-devel] What's your opinion on the patch to fix bug =
58 for kernel 2.6 porting?

Well, to be perfectly honest I don't think this is the right solution.
Instead of peppering the code with signal stuff, why not try to figure =
out
what the timing issue is (it seems that the umount thread should wait on
pending operations) and fix it that way?
	--Mark

On Thu, Apr 29, 2004 at 10:10:56AM +0800, Zhang, Sonic wrote:
> Hi Mark,
>=20
> 	Do you have any opinion on the patch to fix bug 58 for kernel
> 2.6 porting?
> 	Could you add the patch into the source tree?=20
>=20
> 	Thank you.
>=20
>=20
> *********************************************
> Sonic Zhang
> Software Engineer
> Intel China Software Lab
> Tel: (086)021-52574545-1667
> iNet: 752-1667
> *********************************************=20
>=20


> _______________________________________________
> Ocfs2-devel mailing list
> Ocfs2-devel@oss.oracle.com
> http://oss.oracle.com/mailman/listinfo/ocfs2-devel

--
Mark Fasheh
Software Developer, Oracle Corp
mark.fasheh@oracle.com

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

* [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting?
  2004-04-29 20:20 Zhang, Sonic
@ 2004-04-30 11:57 ` Joel Becker
  0 siblings, 0 replies; 5+ messages in thread
From: Joel Becker @ 2004-04-30 11:57 UTC (permalink / raw)
  To: ocfs2-devel

On Fri, Apr 30, 2004 at 09:19:19AM +0800, Zhang, Sonic wrote:
> 	In kernel 2.6 VFS routine sys_umount()->...->generic_shutdown_super(), if the inode usage count i_count is not 0, error information is reported. Then, the system will halt in routine kill_bdev()->truncate_inode_pages().
> 	If we don't fix it in OCFS2 driver, we have to change the kernel 2.6 VFS sys_umount code. Is it a good solution?

	The issue is not whether to fix it in the OCFS2 driver.  The
issue is solving the problem without resorting to ugly stuff like
signals.
	Can you provide a complete description of what happens to cause
the problem, so we can look at it?

Joel

-- 

"Depend on the rabbit's foot if you will, but remember, it didn't
 help the rabbit."
	- R. E. Shay

Joel Becker
Senior Member of Technical Staff
Oracle Corporation
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127

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

* [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting?
@ 2004-05-04  1:08 Zhang, Sonic
  0 siblings, 0 replies; 5+ messages in thread
From: Zhang, Sonic @ 2004-05-04  1:08 UTC (permalink / raw)
  To: ocfs2-devel

Hi,

	OK, see below.

This bug occurs only when unmount a volume immediately after =
open/read/write/close files.

Bug 58 details.
http://oss.oracle.com/bugzilla/show_bug.cgi?id=3D58

Steps: (done in one bash script)
1. load_ocfs2
2. mount /dev/hda4 /ocfs
3. write and read files in /ocfs.
4. close files.
5. umount /ocfs immediately=20

Results:
System halts with error information.
VFS: Busy inodes after unmount. Self-destruct in 5 seconds. Have a nice =
day...


Possible Cause:
	This error information is printed out in kernel 2.6 VFS routine =
generic_shutdown_super() after the second call to invalidate_inodes(). =
In invalidate_inodes(), only inodes with 0 usage count are added to the =
dispose list. And the ocfs_clear_inode(), which lead to =
ocfs_dismount_volume(), is only invoked for those inodes in the dispose =
list.=20

	In ocfs2 after svn version 847, ocfs_clear_inodes() is not invoked if =
unmount a volume immediately after open/read/write/close files, because =
the inode usage counts of the OCFS2 volume are not 0. The i_count isn't =
decreased in function ocfs_file_release() until the journal lock is =
released in ocfs_commit_thread().

	I remember that this change is adopted to avoid the =
ocfs_commit_thread() to access invalid inode referenced in journal lock. =
Am I right?

	In order to fix this bug, I think we have 2 approaches.=20
	One is to keep the mnt_count in struct vfsmount larger than 2 before =
the all inode usage counters are decreased to 0. The other is to =
decrease all inode usage counters before invalide_inodes() is called. =
This can be done in ocfs_put_super(), which is invoked just before the =
second call to invalidate_inodes().

	Any suggestion?
	Thank you.


*********************************************
Sonic Zhang
Software Engineer
Intel China Software Lab
Tel: (086)021-52574545-1667
iNet: 752-1667
*********************************************=20

-----Original Message-----
From: joel.becker@oracle.com [mailto:joel.becker@oracle.com]=20
Sent: 2004=C4=EA5=D4=C21=C8=D5 0:53
To: Zhang, Sonic
Cc: Mark Fasheh; Ocfs2-Devel
Subject: Re: [Ocfs2-devel] What's your opinion on the patch to fix bug =
58 for kernel 2.6 porting?

On Fri, Apr 30, 2004 at 09:19:19AM +0800, Zhang, Sonic wrote:
> 	In kernel 2.6 VFS routine =
sys_umount()->...->generic_shutdown_super(), if the inode usage count =
i_count is not 0, error information is reported. Then, the system will =
halt in routine kill_bdev()->truncate_inode_pages().
> 	If we don't fix it in OCFS2 driver, we have to change the kernel 2.6 =
VFS sys_umount code. Is it a good solution?

	The issue is not whether to fix it in the OCFS2 driver.  The
issue is solving the problem without resorting to ugly stuff like
signals.
	Can you provide a complete description of what happens to cause
the problem, so we can look at it?

Joel

--=20

"Depend on the rabbit's foot if you will, but remember, it didn't
 help the rabbit."
	- R. E. Shay

Joel Becker
Senior Member of Technical Staff
Oracle Corporation
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127

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

end of thread, other threads:[~2004-05-04  1:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-28 21:11 [Ocfs2-devel] What's your opinion on the patch to fix bug 58 for kernel 2.6 porting? Zhang, Sonic
2004-04-29 12:34 ` Mark Fasheh
  -- strict thread matches above, loose matches on Subject: below --
2004-04-29 20:20 Zhang, Sonic
2004-04-30 11:57 ` Joel Becker
2004-05-04  1:08 Zhang, Sonic

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.