mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-26 03:09:34 +03:00
Improve differing sector size error
When adding or replacing a vdev with a different sector size the error message should be more useful. In addition to describing the problem provide a hint that the '-o ashift' option can be used to override the optimal default value. Since using a non-optimal value may incur a significant performance penalty we should issue this error. But there a numerous reasons why a administrator may wish to do this anyway. Signed-off-by: Niklas Edmundsson <ZNikke@github> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #2421
This commit is contained in:
parent
628668a39f
commit
d4aae2a054
@ -2753,10 +2753,11 @@ zpool_vdev_attach(zpool_handle_t *zhp,
|
||||
|
||||
case EDOM:
|
||||
/*
|
||||
* The new device has a different alignment requirement.
|
||||
* The new device has a different optimal sector size.
|
||||
*/
|
||||
zfs_error_aux(hdl, dgettext(TEXT_DOMAIN,
|
||||
"devices have different sector alignment"));
|
||||
"new device has a different optimal sector size; use the "
|
||||
"option '-o ashift=N' to override the optimal size"));
|
||||
(void) zfs_error(hdl, EZFS_BADDEV, msg);
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user