Re: [PATCH] softraid.4 move wd(4) examples to sd(4)
On Wed, Dec 07, 2016 at 06:42:51AM -0800, Bryan Vyhmeister wrote: > On Wed, Dec 07, 2016 at 10:46:44AM +0100, Reyk Floeter wrote: > > > > > Am 05.12.2016 um 23:05 schrieb Bryan Vyhmeister: > > > > > > In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) > > > devices in the examples sections while softraid(4) uses wd(4) devices > > > for the chunks. This patch updates softraid.4 to use sd(4) devices as > > > well. I have not used a wd(4) device in years and I think it more > > > confusing to use examples with wd(4) when almost everything these days > > > is sd(4). > > > Bryan > > > > > > > wd(4) is still alive. For example, we use it on VMs where we don't > > have a PV disk driver yet (Xen, Hyper-V). > > I did not know that. I've only used OpenBSD under VMware products and > bhyve. That makes sense. > Actually, with the new xbf(4) we don't need it on Xen anymore (; Reyk
Re: [PATCH] softraid.4 move wd(4) examples to sd(4)
On Wed, Dec 07, 2016 at 10:46:44AM +0100, Reyk Floeter wrote: > > > Am 05.12.2016 um 23:05 schrieb Bryan Vyhmeister: > > > > In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) > > devices in the examples sections while softraid(4) uses wd(4) devices > > for the chunks. This patch updates softraid.4 to use sd(4) devices as > > well. I have not used a wd(4) device in years and I think it more > > confusing to use examples with wd(4) when almost everything these days > > is sd(4). > > Bryan > > > > wd(4) is still alive. For example, we use it on VMs where we don't > have a PV disk driver yet (Xen, Hyper-V). I did not know that. I've only used OpenBSD under VMware products and bhyve. That makes sense. Bryan
Re: [PATCH] softraid.4 move wd(4) examples to sd(4)
> Am 05.12.2016 um 23:05 schrieb Bryan Vyhmeister: > > In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) > devices in the examples sections while softraid(4) uses wd(4) devices > for the chunks. This patch updates softraid.4 to use sd(4) devices as > well. I have not used a wd(4) device in years and I think it more > confusing to use examples with wd(4) when almost everything these days > is sd(4). > Bryan > wd(4) is still alive. For example, we use it on VMs where we don't have a PV disk driver yet (Xen, Hyper-V). Reyk > > Index: share/man/man4/softraid.4 > === > RCS file: /cvs/src/share/man/man4/softraid.4,v > retrieving revision 1.41 > diff -u -p -r1.41 softraid.4 > --- share/man/man4/softraid.414 Apr 2015 19:10:13 -1.41 > +++ share/man/man4/softraid.45 Dec 2016 21:58:55 - > @@ -121,41 +121,41 @@ An example to create a 3 chunk RAID 1 fr > .Pp > Initialize the partition tables of all disks: > .Bd -literal -offset indent > -# fdisk -iy wd1 > -# fdisk -iy wd2 > -# fdisk -iy wd3 > +# fdisk -iy sd1 > +# fdisk -iy sd2 > +# fdisk -iy sd3 > .Ed > .Pp > Now create RAID partitions on all disks: > .Bd -literal -offset indent > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd1 > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd2 > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd3 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd1 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd2 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd3 > .Ed > .Pp > Assemble the RAID volume: > .Bd -literal -offset indent > -# bioctl -c 1 -l /dev/wd1a,/dev/wd2a,/dev/wd3a softraid0 > +# bioctl -c 1 -l /dev/sd1a,/dev/sd2a,/dev/sd3a softraid0 > .Ed > .Pp > The console will show what device was added to the system: > .Bd -literal -offset indent > scsibus0 at softraid0: 1 targets > -sd0 at scsibus0 targ 0 lun 0: SCSI2 > -sd0: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total > +sd4 at scsibus0 targ 0 lun 0: SCSI2 > +sd4: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total > .Ed > .Pp > It is good practice to wipe the front of the disk before using it: > .Bd -literal -offset indent > -# dd if=/dev/zero of=/dev/rsd0c bs=1m count=1 > +# dd if=/dev/zero of=/dev/rsd4c bs=1m count=1 > .Ed > .Pp > Initialize the partition table and create a filesystem on the > new RAID volume: > .Bd -literal -offset indent > -# fdisk -iy sd0 > -# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd0 > -# newfs /dev/rsd0a > +# fdisk -iy sd4 > +# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd4 > +# newfs /dev/rsd4a > .Ed > .Pp > The RAID volume is now ready to be used as a normal disk device. > @@ -167,7 +167,7 @@ Install > .Xr boot 8 > on the RAID volume: > .Bd -literal -offset indent > -# installboot sd0 > +# installboot sd4 > .Ed > .Pp > At the >
Re: [PATCH] softraid.4 move wd(4) examples to sd(4)
On Wed, Dec 07, 2016 at 06:49:06AM +, Jason McIntyre wrote: > On Mon, Dec 05, 2016 at 02:05:02PM -0800, Bryan Vyhmeister wrote: > > In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) > > devices in the examples sections while softraid(4) uses wd(4) devices > > for the chunks. This patch updates softraid.4 to use sd(4) devices as > > well. I have not used a wd(4) device in years and I think it more > > confusing to use examples with wd(4) when almost everything these days > > is sd(4). > > i kind of disagree: i don;t think it does any harm to show these examples > using wd. if anything, it might force the reader to think about what > they're doing. > > note also that the final example in bioctl(8) has an example using a > chunk on a wd disk. I did notice that too. I can understand that point of view. If that is preferred, it is fine by me. Bryan
Re: [PATCH] softraid.4 move wd(4) examples to sd(4)
On Mon, Dec 05, 2016 at 02:05:02PM -0800, Bryan Vyhmeister wrote: > In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) > devices in the examples sections while softraid(4) uses wd(4) devices > for the chunks. This patch updates softraid.4 to use sd(4) devices as > well. I have not used a wd(4) device in years and I think it more > confusing to use examples with wd(4) when almost everything these days > is sd(4). > > Bryan > morning. i kind of disagree: i don;t think it does any harm to show these examples using wd. if anything, it might force the reader to think about what they're doing. note also that the final example in bioctl(8) has an example using a chunk on a wd disk. jmc > > Index: share/man/man4/softraid.4 > === > RCS file: /cvs/src/share/man/man4/softraid.4,v > retrieving revision 1.41 > diff -u -p -r1.41 softraid.4 > --- share/man/man4/softraid.4 14 Apr 2015 19:10:13 - 1.41 > +++ share/man/man4/softraid.4 5 Dec 2016 21:58:55 - > @@ -121,41 +121,41 @@ An example to create a 3 chunk RAID 1 fr > .Pp > Initialize the partition tables of all disks: > .Bd -literal -offset indent > -# fdisk -iy wd1 > -# fdisk -iy wd2 > -# fdisk -iy wd3 > +# fdisk -iy sd1 > +# fdisk -iy sd2 > +# fdisk -iy sd3 > .Ed > .Pp > Now create RAID partitions on all disks: > .Bd -literal -offset indent > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd1 > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd2 > -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd3 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd1 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd2 > +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd3 > .Ed > .Pp > Assemble the RAID volume: > .Bd -literal -offset indent > -# bioctl -c 1 -l /dev/wd1a,/dev/wd2a,/dev/wd3a softraid0 > +# bioctl -c 1 -l /dev/sd1a,/dev/sd2a,/dev/sd3a softraid0 > .Ed > .Pp > The console will show what device was added to the system: > .Bd -literal -offset indent > scsibus0 at softraid0: 1 targets > -sd0 at scsibus0 targ 0 lun 0:SCSI2 > -sd0: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total > +sd4 at scsibus0 targ 0 lun 0: SCSI2 > +sd4: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total > .Ed > .Pp > It is good practice to wipe the front of the disk before using it: > .Bd -literal -offset indent > -# dd if=/dev/zero of=/dev/rsd0c bs=1m count=1 > +# dd if=/dev/zero of=/dev/rsd4c bs=1m count=1 > .Ed > .Pp > Initialize the partition table and create a filesystem on the > new RAID volume: > .Bd -literal -offset indent > -# fdisk -iy sd0 > -# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd0 > -# newfs /dev/rsd0a > +# fdisk -iy sd4 > +# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd4 > +# newfs /dev/rsd4a > .Ed > .Pp > The RAID volume is now ready to be used as a normal disk device. > @@ -167,7 +167,7 @@ Install > .Xr boot 8 > on the RAID volume: > .Bd -literal -offset indent > -# installboot sd0 > +# installboot sd4 > .Ed > .Pp > At the >
[PATCH] softraid.4 move wd(4) examples to sd(4)
In responding to a post on misc@, I noticed that bioctl(8) uses all sd(4) devices in the examples sections while softraid(4) uses wd(4) devices for the chunks. This patch updates softraid.4 to use sd(4) devices as well. I have not used a wd(4) device in years and I think it more confusing to use examples with wd(4) when almost everything these days is sd(4). Bryan Index: share/man/man4/softraid.4 === RCS file: /cvs/src/share/man/man4/softraid.4,v retrieving revision 1.41 diff -u -p -r1.41 softraid.4 --- share/man/man4/softraid.4 14 Apr 2015 19:10:13 - 1.41 +++ share/man/man4/softraid.4 5 Dec 2016 21:58:55 - @@ -121,41 +121,41 @@ An example to create a 3 chunk RAID 1 fr .Pp Initialize the partition tables of all disks: .Bd -literal -offset indent -# fdisk -iy wd1 -# fdisk -iy wd2 -# fdisk -iy wd3 +# fdisk -iy sd1 +# fdisk -iy sd2 +# fdisk -iy sd3 .Ed .Pp Now create RAID partitions on all disks: .Bd -literal -offset indent -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd1 -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd2 -# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E wd3 +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd1 +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd2 +# printf "a\en\en\en\enRAID\enw\enq\en\en" | disklabel -E sd3 .Ed .Pp Assemble the RAID volume: .Bd -literal -offset indent -# bioctl -c 1 -l /dev/wd1a,/dev/wd2a,/dev/wd3a softraid0 +# bioctl -c 1 -l /dev/sd1a,/dev/sd2a,/dev/sd3a softraid0 .Ed .Pp The console will show what device was added to the system: .Bd -literal -offset indent scsibus0 at softraid0: 1 targets -sd0 at scsibus0 targ 0 lun 0:SCSI2 -sd0: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total +sd4 at scsibus0 targ 0 lun 0: SCSI2 +sd4: 1MB, 0 cyl, 255 head, 63 sec, 512 bytes/sec, 3714 sec total .Ed .Pp It is good practice to wipe the front of the disk before using it: .Bd -literal -offset indent -# dd if=/dev/zero of=/dev/rsd0c bs=1m count=1 +# dd if=/dev/zero of=/dev/rsd4c bs=1m count=1 .Ed .Pp Initialize the partition table and create a filesystem on the new RAID volume: .Bd -literal -offset indent -# fdisk -iy sd0 -# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd0 -# newfs /dev/rsd0a +# fdisk -iy sd4 +# printf "a\en\en\en\en4.2BSD\enw\enq\en\en" | disklabel -E sd4 +# newfs /dev/rsd4a .Ed .Pp The RAID volume is now ready to be used as a normal disk device. @@ -167,7 +167,7 @@ Install .Xr boot 8 on the RAID volume: .Bd -literal -offset indent -# installboot sd0 +# installboot sd4 .Ed .Pp At the