lkml.org 
[lkml]   [2002]   [Apr]   [22]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateMon, 22 Apr 2002 10:17:06 -0600
FromAndreas Dilger <>
SubjectRe: [PATCH] open files in kjounald
On Apr 22, 2002  06:56 +0200, Ph. Marek wrote:
> On every mount of ext3 (and I suppose all journaling filesystems which use
> jbd, although I didn't test this) a new kjournald is created. All kjournald
> share the same file-information.
> 
> Before this patch it would accumulativly fetch open files from the calling
> process (normally mount); I verified this via (in bash)
> 	exec 30< /etc/services
> 	mount <partition> /mnt/tmp
> 	ps -aux | grep kjournald
> 	ls -la <pid of any kjournald>
> gives, among 0, 1 and 2
> 	30 -> /etc/services
> 
> This is really awful as you can't umount devfs (normally /dev/console is
> opened as from the start-scripts) and so / can't be umounted.
> 
> After applying this patch the open files were gone.

It looks OK to me, except that the patch is reversed.

> diff -ru linux/fs/jbd/journal.c linux.ori/fs/jbd/journal.c
> --- linux/fs/jbd/journal.c      Mon Apr 22 06:29:16 2002
> +++ linux.ori/fs/jbd/journal.c  Mon Apr 22 06:28:54 2002
> @@ -204,7 +204,6 @@
> 
>         lock_kernel();
>         daemonize();
> -       exit_files(current);
>         spin_lock_irq(&current->sigmask_lock);
>         sigfillset(&current->blocked);
>         recalc_sigpending(current);

Cheers, Andreas
--
Andreas Dilger
http://www-mddsp.enel.ucalgary.ca/People/adilger/
http://sourceforge.net/projects/ext2resize/

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:25    [W:0.264 / U:0.230 seconds]
©2003-2008 Jasper Spaans