On 15 January 2011 ?. 04:47:01 Jason McIntyre wrote: > On Sat, Jan 15, 2011 at 02:16:34AM +0300, Vadim Zhukov wrote: > > > > It's obvious now, who is native English speaker, and who is not. ;) > > The phrase "The argument may contain a multiplier, as documented in > > scan_scaled" was taken from smtpd.conf(5) - I thought it was OK to > > re-use it here unchanged. Sorry if your eyes suffered a little. :) > > it's fine to lift from other pages. but smtpd.conf is talking about > bytes which can be adjusted by a multiple. and here it's either sectors > or a multiplier, right? so a bit different.
Well, at least for the -s it was just bytes (per sector), so there is no actual difference. But, of course, it's good to be consistent within a page. > > The problem is that I had to re-read phrase "This value is multiplied > > by the number of 512-byte blocks in a sector" a few times, until > > realized what it means. Alexander, did you mean this too when said > > "It just confused me"? Maybe it's better to talk about device > > blocks separately? > > yes, that's the ambiguity we need to try and avoid. so make sure you're > happy it's eliminated. I'll then wait until someone knowledgeable answer the question about rounding, and then present hopefully final version. > > Index: newfs.8 > > =================================================================== > > RCS file: /cvs/src/sbin/newfs/newfs.8,v > > retrieving revision 1.68 > > diff -u -p -r1.68 newfs.8 > > --- newfs.8 21 Mar 2010 07:51:23 -0000 1.68 > > +++ newfs.8 14 Jan 2011 23:15:29 -0000 > > @@ -218,6 +218,8 @@ With this option, > > will not print extraneous information like superblock backups. > > .It Fl S Ar sector-size > > The size of a sector in bytes (almost always 512). > > +The argument may contain a multiplier, as documented in > > +.Xr scan_scaled 3 . > > well, i'd try to use the same text for both -S and -s. i think the one > above still has the ambiguity. i'd use the (new) text for -s: > > Alternatively > .Ar sector-size > may instead... Fixed. > > A sector is the smallest addressable unit on the physical device. > > Changing this is useful only when using > > .Nm > > @@ -234,6 +236,14 @@ The size of the file system in sectors. > > This value is multiplied by the number of 512\-byte blocks in a sector > > to yield the size of the file system in 512\-byte blocks, which is the > > value > > used by the kernel. > > +Alternatively > > +.Ar size > > +may instead use a multiplier, as documented in > > +.Xr scan_scaled 3 . > > +In the latter case > > +.Ar size > > +is rounded up to next sector boundary and then again gets converted to > > +512\-byte blocks count. > > you should just swap the last two sentences around (keep the sector > stuff together) and you can kill "In the latter case". Sorry for being stupid. Do you mean this? "This value is multiplied by the number of 512-byte blocks in a sector to yield the size of the file system in 512-byte blocks, which is the value used by the kernel. Actual size is always rounded up to next sector boundary and then again gets converted to 512-byte blocks count. Alternatively size may instead use a multiplier, as documented in scan_scaled(3)." This sounds strange: 1) If size=sectors*blockspersectors then size is obviously rounded to the sector size; 2) It's not clear that it gets rounded at all in the case of multiplier being used. Looks like I just didn't get what you meant. :( -- Best wishes, Vadim Zhukov A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? Index: newfs.8 =================================================================== RCS file: /cvs/src/sbin/newfs/newfs.8,v retrieving revision 1.68 diff -u -p -r1.68 newfs.8 --- newfs.8 21 Mar 2010 07:51:23 -0000 1.68 +++ newfs.8 16 Jan 2011 17:05:45 -0000 @@ -218,6 +218,10 @@ With this option, will not print extraneous information like superblock backups. .It Fl S Ar sector-size The size of a sector in bytes (almost always 512). +Alternatively +.Ar sector-size +may instead use a multiplier, as documented in +.Xr scan_scaled 3 . A sector is the smallest addressable unit on the physical device. Changing this is useful only when using .Nm @@ -230,10 +234,18 @@ from its default will make it impossible to find the alternate superblocks if the standard superblock is lost. .It Fl s Ar size -The size of the file system in sectors. +The size of the file system in sectors (see +.Fl S ) . This value is multiplied by the number of 512\-byte blocks in a sector to yield the size of the file system in 512\-byte blocks, which is the value used by the kernel. +Alternatively +.Ar size +may instead use a multiplier, as documented in +.Xr scan_scaled 3 , +to specify size in bytes; in this case +.Ar size +is rounded up to the next sector boundary. The maximum size of an FFS file system is 2,147,483,647 (2^31 \- 1) of these 512\-byte blocks, slightly less than 1 TB. FFS2 file systems can be as large as 64 PB.