Re: [Ocfs2-users] df showing wrong size
What version are you running? On 06/28/2010 03:46 PM, Garcia, Raymundo wrote: > So.. if it is not cleaned up.. what can we do? > > -Original Message- > From: Sunil Mushran [mailto:sunil.mush...@oracle.com] > Sent: Monday, June 28, 2010 11:04 AM > To: Patrick J. LoPresti > Cc: Garcia, Raymundo; ocfs2-users@oss.oracle.com > Subject: Re: [Ocfs2-users] df showing wrong size > > On 06/28/2010 09:37 AM, Patrick J. LoPresti wrote: > >> On Mon, Jun 28, 2010 at 9:29 AM, Sunil Mushran >> wrote: >> >> >>> ocfs2 is a journaled file system. But it is also a clustered file system. >>> So it cannot arbitrarily delete orphaned files because they could still be >>> in use on another node. >>> >>> >> Ah, interesting... So I have a dumb question: >> >> If a deleted file is still open on a node, and that node crashes, when >> and how does that file's space get reclaimed? >> >> (Sorry if this is in the documentation and I missed it.) >> >> > Node death triggers dlm recovery followed by fs journal replay > followed by orphan cleanup. If that file is not in use on any other > node, it will get cleaned up. > > The information contained in this message may be confidential and legally > protected under applicable law. The message is intended solely for the > addressee(s). If you are not the intended recipient, you are hereby notified > that any use, forwarding, dissemination, or reproduction of this message is > strictly prohibited and may be unlawful. If you are not the intended > recipient, please contact the sender by return e-mail and destroy all copies > of the original message. > > ___ > Ocfs2-users mailing list > Ocfs2-users@oss.oracle.com > http://oss.oracle.com/mailman/listinfo/ocfs2-users > ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
So.. if it is not cleaned up.. what can we do? -Original Message- From: Sunil Mushran [mailto:sunil.mush...@oracle.com] Sent: Monday, June 28, 2010 11:04 AM To: Patrick J. LoPresti Cc: Garcia, Raymundo; ocfs2-users@oss.oracle.com Subject: Re: [Ocfs2-users] df showing wrong size On 06/28/2010 09:37 AM, Patrick J. LoPresti wrote: > On Mon, Jun 28, 2010 at 9:29 AM, Sunil Mushran > wrote: > >> ocfs2 is a journaled file system. But it is also a clustered file system. >> So it cannot arbitrarily delete orphaned files because they could still be >> in use on another node. >> > Ah, interesting... So I have a dumb question: > > If a deleted file is still open on a node, and that node crashes, when > and how does that file's space get reclaimed? > > (Sorry if this is in the documentation and I missed it.) > Node death triggers dlm recovery followed by fs journal replay followed by orphan cleanup. If that file is not in use on any other node, it will get cleaned up. The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message. ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
On 06/28/2010 09:37 AM, Patrick J. LoPresti wrote: > On Mon, Jun 28, 2010 at 9:29 AM, Sunil Mushran > wrote: > >> ocfs2 is a journaled file system. But it is also a clustered file system. >> So it cannot arbitrarily delete orphaned files because they could still be >> in use on another node. >> > Ah, interesting... So I have a dumb question: > > If a deleted file is still open on a node, and that node crashes, when > and how does that file's space get reclaimed? > > (Sorry if this is in the documentation and I missed it.) > Node death triggers dlm recovery followed by fs journal replay followed by orphan cleanup. If that file is not in use on any other node, it will get cleaned up. ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
On 06/28/2010 07:57 AM, Patrick J. LoPresti wrote: > On Sun, Jun 27, 2010 at 11:17 PM, Garcia, Raymundo > wrote: > >> Hello… it was put under my attention that a partition we have in one of our >> production system was displaying wrong size with df command…. 123 GB… but in >> fact the size of all the files is a mere 15 GB…. What is going on? Shall we >> use ocfs.fsck to fix that? Is strange… >> > As others have mentioned, this could be still-open files that have > been deleted. It could also be that ocfs2 is leaking free space. I > thought journaling file systems didn't have "orphan" files after > reboot, but I could be wrong. > > I think I have seen ocfs2 leak free space even during normal > operation, but I am still working on reproducing it. > > If you do run fsck.ocfs2 -- you probably want to use "fsck.ocfs2 -fy" > -- could you please send the output to the list? > ocfs2 is a journaled file system. But it is also a clustered file system. So it cannot arbitrarily delete orphaned files because they could still be in use on another node. Having said that, we did have a bug that could result in orphaned files not getting deleted. This has since been fixed. For (RH)EL5 users: Bug was introduced in ocfs2 1.4.1 and fixed in 1.4.4. http://oss.oracle.com/projects/ocfs2/news/article_21.html For SLES users: Introduced in base sles10 sp2. It has since been fixed. I don't know the kernel version offhand. For mainline users: Fixed in 2.6.31. Sunil ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
On Mon, Jun 28, 2010 at 9:29 AM, Sunil Mushran wrote: > > > ocfs2 is a journaled file system. But it is also a clustered file system. > So it cannot arbitrarily delete orphaned files because they could still be > in use on another node. Ah, interesting... So I have a dumb question: If a deleted file is still open on a node, and that node crashes, when and how does that file's space get reclaimed? (Sorry if this is in the documentation and I missed it.) - Pat ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
On Sun, Jun 27, 2010 at 11:17 PM, Garcia, Raymundo wrote: > Hello… it was put under my attention that a partition we have in one of our > production system was displaying wrong size with df command…. 123 GB… but in > fact the size of all the files is a mere 15 GB…. What is going on? Shall we > use ocfs.fsck to fix that? Is strange… As others have mentioned, this could be still-open files that have been deleted. It could also be that ocfs2 is leaking free space. I thought journaling file systems didn't have "orphan" files after reboot, but I could be wrong. I think I have seen ocfs2 leak free space even during normal operation, but I am still working on reproducing it. If you do run fsck.ocfs2 -- you probably want to use "fsck.ocfs2 -fy" -- could you please send the output to the list? Thanks. - Pat ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
Make sure you don't have deleted files, which are still open. You can use lsof to find those. From: ocfs2-users-boun...@oss.oracle.com [mailto:ocfs2-users-boun...@oss.oracle.com] On Behalf Of Garcia, Raymundo Sent: Sunday, June 27, 2010 11:18 PM To: ocfs2-users@oss.oracle.com Subject: [Ocfs2-users] df showing wrong size Hello... it was put under my attention that a partition we have in one of our production system was displaying wrong size with df command 123 GB... but in fact the size of all the files is a mere 15 GB What is going on? Shall we use ocfs.fsck to fix that? Is strange... Thanks for any comment Raymundo Garcia The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message. ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users
Re: [Ocfs2-users] df showing wrong size
Hi Garcia, On 06/28/2010 02:17 PM, Garcia, Raymundo wrote: > > > Hello… it was put under my attention that a partition we have in one of > our production system was displaying wrong size with df command…. 123 > GB… but in fact the size of all the files is a mere 15 GB…. What is > going on? Shall we use ocfs.fsck to fix that? Is strange… 123GB is the total size of the used size? df use statfs(2) to check the size, so in general, you will get the used size for the whole volume(including some files that haven't been freed and stayed in orphan dir). 15GB is what you get from du I guess? du will iterate the dir and check it. So it only contains the size for every visible file, not including orphan files. Regards, Tao > > Thanks for any comment…. > > Raymundo Garcia > > > The information contained in this message may be confidential and > legally protected under applicable law. The message is intended solely > for the addressee(s). If you are not the intended recipient, you are > hereby notified that any use, forwarding, dissemination, or reproduction > of this message is strictly prohibited and may be unlawful. If you are > not the intended recipient, please contact the sender by return e-mail > and destroy all copies of the original message. > > > > ___ > Ocfs2-users mailing list > Ocfs2-users@oss.oracle.com > http://oss.oracle.com/mailman/listinfo/ocfs2-users ___ Ocfs2-users mailing list Ocfs2-users@oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-users