The size of the UFS soft-updates journal must be a multiple of the
filesystem block size. When a size is specified with the -S flag to tunefs(8), round it up to the filesystem block size. Reported by: Peter Holm Tested by: Peter Holm Sponsored by: Netflix
This commit is contained in:
parent
83b009dab5
commit
886e9f061c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=344731
@ -971,9 +971,9 @@ journal_alloc(int64_t size)
|
|||||||
if (size / sblock.fs_fsize > sblock.fs_fpg)
|
if (size / sblock.fs_fsize > sblock.fs_fpg)
|
||||||
size = sblock.fs_fpg * sblock.fs_fsize;
|
size = sblock.fs_fpg * sblock.fs_fsize;
|
||||||
size = MAX(SUJ_MIN, size);
|
size = MAX(SUJ_MIN, size);
|
||||||
/* fsck does not support fragments in journal files. */
|
|
||||||
size = roundup(size, sblock.fs_bsize);
|
|
||||||
}
|
}
|
||||||
|
/* fsck does not support fragments in journal files. */
|
||||||
|
size = roundup(size, sblock.fs_bsize);
|
||||||
resid = blocks = size / sblock.fs_bsize;
|
resid = blocks = size / sblock.fs_bsize;
|
||||||
if (sblock.fs_cstotal.cs_nbfree < blocks) {
|
if (sblock.fs_cstotal.cs_nbfree < blocks) {
|
||||||
warn("Insufficient free space for %jd byte journal", size);
|
warn("Insufficient free space for %jd byte journal", size);
|
||||||
|
Loading…
Reference in New Issue
Block a user