From 915dcdb7ac5f64ac5f5235bbe6a9dfc0046a8fa1 Mon Sep 17 00:00:00 2001 From: Robert Wing Date: Tue, 13 Oct 2020 18:00:23 +0000 Subject: [PATCH] ctl.conf(5): fix LUN size in UCL format example. Remove quotes around size in the LUN section and change the suffix to 'GB'. The UCL format does recognize 'G' on its own, which uses a base 10 multiplier where 'GB' uses a 2 power multiplier. Document the difference between valid suffixes when using ctl.conf(5) in the general syntax form or in UCL format. Reviewed by: kevans, mav Approved by: kevans (mentor) Differential Revision: https://reviews.freebsd.org/D26716 --- usr.sbin/ctld/ctl.conf.5 | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/usr.sbin/ctld/ctl.conf.5 b/usr.sbin/ctld/ctl.conf.5 index 90e85724a041..68766af3ae60 100644 --- a/usr.sbin/ctld/ctl.conf.5 +++ b/usr.sbin/ctld/ctl.conf.5 @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 21, 2016 +.Dd October 13, 2020 .Dt CTL.CONF 5 .Os .Sh NAME @@ -426,7 +426,12 @@ property set. .It Ic serial Ar string The SCSI serial number presented to the initiator. .It Ic size Ar size -The LUN size, in bytes. +The LUN size, in bytes or by number with a suffix of +.Sy K , M , G , T +(for kilobytes, megabytes, gigabytes, or terabytes). +When the configuration is in UCL format, use the suffix format +.Sy kKmMgG Ns | Ns Sy bB , +(i.e., 4GB, 4gb, and 4Gb are all equivalent). .El .Sh FILES .Bl -tag -width ".Pa /etc/ctl.conf" -compact @@ -536,7 +541,7 @@ lun { example_0 { path = /dev/zvol/tank/example_0 blocksize = 4096 - size = "4G" + size = 4GB } example_1 {