On Sun, Mar 18, 2018 at 3:52 PM, waxhead <waxhead@xxxxxxxxxxxxxx> wrote: > Liu Bo wrote: >> >> On Sat, Mar 17, 2018 at 5:26 PM, Liu Bo <obuil.liubo@xxxxxxxxx> wrote: >>> >>> On Fri, Mar 16, 2018 at 2:46 PM, Mike Stevens <michael.stevens@xxxxxxxxx> >>> wrote: >>>>> >>>>> Could you please paste the whole dmesg, it looks like it hit >>>>> btrfs_abort_transaction(), >>>>> which should give us more information about where goes wrong. >>>> >>>> >>>> The whole thing is here https://pastebin.com/4ENq2saQ >>> >>> >>> Given this, >>> >>> [ 299.410998] BTRFS: error (device sdag) in >>> btrfs_create_pending_block_groups:10192: errno=-27 unknown >>> >>> it refers to -EFBIG, so I think the warning comes from >>> >>> btrfs_add_system_chunk() >>> { >>> ... >>> if (array_size + item_size + sizeof(disk_key) >>> >>> > BTRFS_SYSTEM_CHUNK_ARRAY_SIZE) { >>> >>> mutex_unlock(&fs_info->chunk_mutex); >>> >>> return -EFBIG; >>> >>> } >>> >>> If that's the case, we need to check this earlier during mount. >>> >> >> I didn't realize this until now, we do have a limitation on up to how >> many disks btrfs could handle, in order to make balance/scrub work >> properly (where system chunks may be set readonly), >> >> ((BTRFS_SYSTEM_CHUNK_ARRAY_SIZE / 2) - sizeof(struct btrfs_chunk)) / >> sizeof(struct btrfs_stripe) + 1 >> >> will be the number of disks btrfs can handle at most. > > > Am I understanding this correct, BTRFS have limit to the number of physical > devices it can handle?! (max 30 devices?!) > > Or are this referring to the number of devices BTRFS can utilize in a stripe > (in which case 30 actually sounds like a high number). > > 30 devices is really not that much, heck you get 90 disks top load JBOD > storage chassis these days and BTRFS does sound like an attractive choice > for things like that. So Mike's case is, that both metadata and data are configured as raid6, and the operations, balance and scrub, that he tried, need to set the existing block group as readonly (in order to avoid any further changes being applied during operations are running), then we got into the place where another system chunk is needed. However, I think it'd be better to have some warnings about this when doing a) mkfs.btrfs -mraid6, b) btrfs device add. David, any idea? thanks, liubo -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
