larger than 256kb, which is larger than the maximum log stripe unit size.
So, only set and check the log stripe unit on version 2 internal logs, and
default the stripe unit size to 32kb if the data volume's stripe unit
size is too big.
Only set and check the log stripe unit on version 2 internal logs, and
default the stripe unit size to 32kb if the data volume's stripe unit
size is too big.
}
/* convert from 512 byte blocks to fs blocks */
lsunit = DTOBT(lsunit);
- } else if (dsunit) {
+ } else if (logversion == 2 && loginternal && dsunit) {
/* lsunit and dsunit now in fs blocks */
lsunit = dsunit;
}
- if ((lsunit * blocksize) > 256 * 1024) {
+ if (logversion == 2 && (lsunit * blocksize) > 256 * 1024) {
fprintf(stderr,
_("log stripe unit (%d bytes) is too large for kernel to handle (max 256k)\n"),
(lsunit * blocksize));
- exit(1);
+ lsunit = 32 * 1024;
+ fprintf(stderr,
+ _("log stripe unit adjusted to 256kb\n"));
}
protostring = setup_proto(protofile);