Bug 177431 - Handbook & Announcements recommend poor dd options for memstick images
Summary: Handbook & Announcements recommend poor dd options for memstick images
Status: Closed FIXED
Alias: None
Product: Documentation
Classification: Unclassified
Component: Books & Articles (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-doc (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-28 03:50 UTC by Ronald F. Guilmette
Modified: 2015-08-14 18:15 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ronald F. Guilmette 2013-03-28 03:50:00 UTC
The Handbook, as shown on this web page:

  http://www.freebsd.org/doc/en/books/handbook/bsdinstall-pre.html

recommends  dd'ing the desired (?) memstick.img file to a USB memory stick
using the following command:

	# dd if=FreeBSD-9.0-RELEASE-i386-memstick.img of=/dev/da0 bs=64k

(Please note that the specific filename mentioned here is now out-of-date
relative to the most recent -RELEASE.)

So anyway, there appear to be two things wrong with the above recommended
dd command, to wit:

     (1) the recommended dd block size of 64k is probably highly sub-optimal
         for many/most/all modern USB flash drives.  It is apparently difficult
         to find a single (minimal) block size that will provide best per-
         formance for all USB flash drives, however online sources suggest
         that a 1 MiB block size should provide excelent performance for
         most such drives (and with relatively little waste of space).

     (2) The dd command should probably also include the conv=sync option,
         just as shown in the 9.1 RELEASE Announcement.  (Otherwise it is
	 not 100% clear what will happen to the last few blocks of the
	 memstick.img file, i.e. the ones that don't fix neatly into exactly
	 `N' of the dd blocks.)

Separately and additionally, various versions of the official FreeBSD Release
Announcements, for example the version found here:

   http://www.freebsd.org/releases/9.1R/announce.html

recommend using bs=10240 when dd'ing a memstick.img file to a USB flash
device.  As noted above, this value is also probably highly sub-optimal,
and should probably be replaced (in *all* current and past Release
Announcement pages) to the value "bs=1M".

Fix: 

See above.
How-To-Repeat: 
Visit the two URLs mentioned above.
Comment 1 commit-hook freebsd_committer freebsd_triage 2015-08-14 18:13:57 UTC
A commit references this bug:

Author: bcr
Date: Fri Aug 14 18:13:09 UTC 2015
New revision: 47233
URL: https://svnweb.freebsd.org/changeset/doc/47233

Log:
  Be consistent about the blocksize (1m instead of 64k) and conv=sync
  with the instructions in the release notes when describing how to
  burn the memstick image to a memory stick.

  PR:		177431
  Submitted by:	rfg tristatelogic com

Changes:
  head/en_US.ISO8859-1/books/handbook/bsdinstall/chapter.xml
Comment 2 Benedict Reuschling freebsd_committer freebsd_triage 2015-08-14 18:15:59 UTC
We can not change previous release notes, but those for 10.2-RELEASE mention the proper blocksize of 1m as well as conv=sync. Thanks for reporting this!