lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4B4AB1C8.3050601@redhat.com>
Date:	Sun, 10 Jan 2010 23:06:16 -0600
From:	Eric Sandeen <sandeen@...hat.com>
To:	Jeff Layton <laytonjb@....net>
CC:	linux-ext4@...r.kernel.org
Subject: Re: Size of journal?

Jeff Layton wrote:
> Good afternoon!
> 
> I was wondering what the default journal size is for ext4
> when it's built on a single partition? Or does it vary in size
> as needed?
> 
> TIA!
> 
> Jeff

See figure_journal_size() in mke2fs.c.  It's called w/ size == -1
if no other size is specified on the commandline so that goes
to ext2fs_default_journal_size(), which is pretty straightforward
in its scaling with nr of filesystem blocks:

/*
 * Find a reasonable journal file size (in blocks) given the number of blocks
 * in the filesystem.  For very small filesystems, it is not reasonable to
 * have a journal that fills more than half of the filesystem.
 */
int ext2fs_default_journal_size(__u64 blocks)
{
        if (blocks < 2048)
                return -1;
        if (blocks < 32768)
                return (1024);
        if (blocks < 256*1024)
                return (4096);
        if (blocks < 512*1024)
                return (8192);
        if (blocks < 1024*1024)
                return (16384);
        return 32768;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ