diff --git a/sbin/geom/class/concat/gconcat.8 b/sbin/geom/class/concat/gconcat.8 index c91c0b9808de..2e1b79dadd1a 100644 --- a/sbin/geom/class/concat/gconcat.8 +++ b/sbin/geom/class/concat/gconcat.8 @@ -35,7 +35,7 @@ .Cm create .Op Fl v .Ar name -.Ar prov prov ... +.Ar prov ... .Nm .Cm destroy .Op Fl fv @@ -44,7 +44,7 @@ .Cm label .Op Fl hv .Ar name -.Ar prov prov ... +.Ar prov ... .Nm .Cm stop .Op Fl fv @@ -168,10 +168,21 @@ umount /mnt gconcat stop data gconcat unload .Ed +.Pp +Configure concatenated provider on one disk only. +Create file system. +Add two more disks and extend existing file system. +.Bd -literal -offset indent +gconcat label data /dev/da0 +newfs /dev/concat/data +gconcat label data /dev/da0 /dev/da1 /dev/da2 +growfs /dev/concat/data +.Ed .Sh SEE ALSO .Xr geom 4 , .Xr loader.conf 5 , .Xr geom 8 , +.Xr growfs 8 , .Xr mount 8 , .Xr newfs 8 , .Xr sysctl 8 , diff --git a/sbin/geom/class/concat/geom_concat.c b/sbin/geom/class/concat/geom_concat.c index bf4687ed393a..4157cea29fe4 100644 --- a/sbin/geom/class/concat/geom_concat.c +++ b/sbin/geom/class/concat/geom_concat.c @@ -55,7 +55,7 @@ struct g_command class_commands[] = { "[-v] prov ..." }, { "create", G_FLAG_VERBOSE | G_FLAG_LOADKLD, NULL, G_NULL_OPTS, - "[-v] name prov prov ..." + "[-v] name prov ..." }, { "destroy", G_FLAG_VERBOSE, NULL, { @@ -72,7 +72,7 @@ struct g_command class_commands[] = { { 'h', "hardcode", NULL, G_TYPE_NONE }, G_OPT_SENTINEL }, - "[-hv] name prov prov ..." + "[-hv] name prov ..." }, { "stop", G_FLAG_VERBOSE, NULL, { @@ -118,7 +118,7 @@ concat_label(struct gctl_req *req) int error, i, hardcode, nargs; nargs = gctl_get_int(req, "nargs"); - if (nargs <= 2) { + if (nargs < 2) { gctl_error(req, "Too few arguments."); return; } diff --git a/sys/geom/concat/g_concat.c b/sys/geom/concat/g_concat.c index f2e980a2333f..113c175165ef 100644 --- a/sys/geom/concat/g_concat.c +++ b/sys/geom/concat/g_concat.c @@ -452,8 +452,8 @@ g_concat_create(struct g_class *mp, const struct g_concat_metadata *md, G_CONCAT_DEBUG(1, "Creating device %s (id=%u).", md->md_name, md->md_id); - /* Two disks is minimum. */ - if (md->md_all <= 1) + /* One disks is minimum. */ + if (md->md_all < 1) return (NULL); /* Check for duplicate unit */ @@ -664,7 +664,7 @@ g_concat_ctl_create(struct gctl_req *req, struct g_class *mp) gctl_error(req, "No '%s' argument.", "nargs"); return; } - if (*nargs <= 2) { + if (*nargs < 2) { gctl_error(req, "Too few arguments."); return; }