White space fix only. Translators can ignore.

Sponsored by:	iXsystems
This commit is contained in:
Dru Lavigne 2014-04-23 20:27:03 +00:00
parent 7655cacc8e
commit 62fd2d07c9
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/head/; revision=44639

View file

@ -432,24 +432,24 @@ super-block backups (for fsck -b #) at:
<para>Many external storage solutions, such as hard drives,
<acronym>USB</acronym> thumbdrives, and <acronym>CD</acronym>
and <acronym>DVD</acronym> burners, use the
Universal Serial Bus (<acronym>USB</acronym>). &os; provides
support for <acronym>USB</acronym> 1.x, 2.0, and 3.0 devices.</para>
and <acronym>DVD</acronym> burners, use the Universal Serial Bus
(<acronym>USB</acronym>). &os; provides support for
<acronym>USB</acronym> 1.x, 2.0, and 3.0 devices.</para>
<note>
<para><acronym>USB</acronym> 3.0 support is not compatible with
some hardware, including Haswell (Lynx point) chipsets. If
some hardware, including Haswell (Lynx point) chipsets. If
&os; boots with a <errorname>failed with error 19</errorname>
message, disable xHCI/USB3 in the system
<acronym>BIOS</acronym>.</para>
</note>
<para>Support for <acronym>USB</acronym> storage devices
is built into the <filename>GENERIC</filename>
kernel. For a custom kernel, be sure that the following
lines are present in the kernel configuration file:</para>
<programlisting>device scbus # SCSI bus (required for ATA/SCSI)
<para>Support for <acronym>USB</acronym> storage devices is built
into the <filename>GENERIC</filename> kernel. For a custom
kernel, be sure that the following lines are present in the
kernel configuration file:</para>
<programlisting>device scbus # SCSI bus (required for ATA/SCSI)
device da # Direct Access (disks)
device pass # Passthrough device (direct ATA/SCSI access)
device uhci # provides USB 1.x support
@ -460,15 +460,15 @@ device usb # USB Bus (required)
device umass # Disks/Mass storage - Requires scbus and da
device cd # needed for CD and DVD burners</programlisting>
<para>&os; uses the &man.umass.4; driver which uses the
<acronym>SCSI</acronym> subsystem to access
<acronym>USB</acronym> storage devices. Since any
<acronym>USB</acronym> device will be seen as a
<acronym>SCSI</acronym> device by the system,
if the <acronym>USB</acronym> device is a
<acronym>CD</acronym> or <acronym>DVD</acronym> burner, do
<emphasis>not</emphasis> include <option>device atapicam</option>
in a custom kernel configuration file.</para>
<para>&os; uses the &man.umass.4; driver which uses the
<acronym>SCSI</acronym> subsystem to access
<acronym>USB</acronym> storage devices. Since any
<acronym>USB</acronym> device will be seen as a
<acronym>SCSI</acronym> device by the system, if the
<acronym>USB</acronym> device is a <acronym>CD</acronym> or
<acronym>DVD</acronym> burner, do <emphasis>not</emphasis>
include <option>device atapicam</option> in a custom kernel
configuration file.</para>
<para>The rest of this section demonstrates how to verify that a
<acronym>USB</acronym> storage device is recognized by &os; and
@ -480,15 +480,15 @@ device cd # needed for CD and DVD burners</programlisting>
<para>To test the <acronym>USB</acronym> configuration, plug in
the <acronym>USB</acronym> device. Use
<command>dmesg</command> to confirm that the drive appears in
the system message buffer. It should look something
like this:</para>
the system message buffer. It should look something like
this:</para>
<screen>umass0: &lt;STECH Simple Drive, class 0/0, rev 2.00/1.04, addr 3&gt; on usbus0
umass0: SCSI over Bulk-Only; quirks = 0x0100
umass0:4:0:-1: Attached to scbus4
da0 at umass-sim0 bus 0 scbus4 target 0 lun 0
da0: &lt;STECH Simple Drive 1.04&gt; Fixed Direct Access SCSI-4 device
da0: Serial Number WD-WXE508CAN263
da0: &lt;STECH Simple Drive 1.04&gt; Fixed Direct Access SCSI-4 device
da0: Serial Number WD-WXE508CAN263
da0: 40.000MB/s transfers
da0: 152627MB (312581808 512 byte sectors: 255H 63S/T 19457C)
da0: quirks=0x2&lt;NO_6_BYTE&gt;</screen>
@ -511,36 +511,36 @@ da0: quirks=0x2&lt;NO_6_BYTE&gt;</screen>
<screen>&prompt.root; <userinput>usbconfig</userinput>
ugen0.3: &lt;Simple Drive STECH&gt; at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (2mA)</screen>
<para>If the device has not been formatted,
refer to <xref linkend="disks-adding"/> for instructions on
how to format and create partitions on the
<acronym>USB</acronym> drive. If the drive comes with a file
system, it can be mounted by <systemitem
class="username">root</systemitem> using the
<para>If the device has not been formatted, refer to <xref
linkend="disks-adding"/> for instructions on how to format
and create partitions on the <acronym>USB</acronym> drive. If
the drive comes with a file system, it can be mounted by
<systemitem class="username">root</systemitem> using the
instructions in <xref linkend="mount-unmount"/>.</para>
<warning>
<para>Allowing untrusted users to mount arbitrary media, by
enabling <varname>vfs.usermount</varname> as
described below, should not be considered safe from a
security point of view. Most file systems were not
built to safeguard against malicious devices.</para>
enabling <varname>vfs.usermount</varname> as described
below, should not be considered safe from a security point
of view. Most file systems were not built to safeguard
against malicious devices.</para>
</warning>
<para>To make the device mountable as a normal user, one
solution is to make all users of the device a member of the
<systemitem class="groupname">operator</systemitem> group
using &man.pw.8;. Next, ensure that <systemitem
class="groupname">operator</systemitem> is able to
read and write the device by adding these lines to
class="groupname">operator</systemitem> is able to read and
write the device by adding these lines to
<filename>/etc/devfs.rules</filename>:</para>
<programlisting>[localrules=5]
add path 'da*' mode 0660 group operator</programlisting>
<note>
<para>If internal <acronym>SCSI</acronym> disks are also installed in the
system, change the second line as follows:</para>
<para>If internal <acronym>SCSI</acronym> disks are also
installed in the system, change the second line as
follows:</para>
<programlisting>add path 'da[<replaceable>3</replaceable>-9]*' mode 0660 group operator</programlisting>
@ -558,9 +558,8 @@ add path 'da*' mode 0660 group operator</programlisting>
<programlisting>devfs_system_ruleset="localrules"</programlisting>
<para>Then, instruct the system to allow regular users
to mount file systems by adding the
following line to
<para>Then, instruct the system to allow regular users to mount
file systems by adding the following line to
<filename>/etc/sysctl.conf</filename>:</para>
<programlisting>vfs.usermount=1</programlisting>
@ -568,7 +567,7 @@ add path 'da*' mode 0660 group operator</programlisting>
<para>Since this only takes effect after the next reboot, use
<command>sysctl</command> to set this variable now:</para>
<screen>&prompt.root; <userinput>sysctl vfs.usermount=1</userinput>
<screen>&prompt.root; <userinput>sysctl vfs.usermount=1</userinput>
vfs.usermount: 0 -&gt; 1</screen>
<para>The final step is to create a directory where the file
@ -587,19 +586,18 @@ vfs.usermount: 0 -&gt; 1</screen>
<para>Suppose a <acronym>USB</acronym> thumbdrive is plugged in,
and a device <filename>/dev/da0s1</filename> appears. If the
device is formatted with a <acronym>FAT</acronym> file system, the user can
mount it using:</para>
device is formatted with a <acronym>FAT</acronym> file system,
the user can mount it using:</para>
<screen>&prompt.user; <userinput>mount -t msdosfs -o -m=644,-M=755 /dev/da0s1 /mnt/<replaceable>username</replaceable></userinput></screen>
<para>Before the device can be unplugged, it
<emphasis>must</emphasis> be unmounted first:</para>
<emphasis>must</emphasis> be unmounted first:</para>
<screen>&prompt.user; <userinput>umount /mnt/<replaceable>username</replaceable></userinput></screen>
<para>After device
removal, the system message buffer will show messages similar
to the following:</para>
<para>After device removal, the system message buffer will show
messages similar to the following:</para>
<screen>umass0: at uhub3, port 2, addr 3 (disconnected)
da0 at umass-sim0 bus 0 scbus4 target 0 lun 0
@ -629,14 +627,16 @@ da0: &lt;STECH Simple Drive 1.04&gt; s/n WD-WXE508CAN263 detached
</indexterm>
<para><acronym>CD</acronym> media provide a number of features
that differentiate them from conventional disks. They are designed so that
they can be read continuously without delays to move the head
between tracks. While <acronym>CD</acronym> media do have tracks, these refer
to a section of data to be read continuously, and not a physical
property of the disk. The <acronym>ISO</acronym> 9660 file system was designed to deal with these
differences.</para>
that differentiate them from conventional disks. They are
designed so that they can be read continuously without delays to
move the head between tracks. While <acronym>CD</acronym> media
do have tracks, these refer to a section of data to be read
continuously, and not a physical property of the disk. The
<acronym>ISO</acronym> 9660 file system was designed to deal
with these differences.</para>
<indexterm><primary><acronym>ISO</acronym> 9660</primary></indexterm>
<indexterm><primary><acronym>ISO</acronym>
9660</primary></indexterm>
<indexterm>
<primary>file systems</primary>
<secondary>ISO 9660</secondary>
@ -652,10 +652,10 @@ da0: &lt;STECH Simple Drive 1.04&gt; s/n WD-WXE508CAN263 detached
Which tool to use to burn a <acronym>CD</acronym> depends
on whether the <acronym>CD</acronym> burner is an
<acronym>ATAPI</acronym>, <acronym>SCSI</acronym>, or
<acronym>USB</acronym> device. This chapter demonstrates the use
of several command line utilities. For <acronym>CD</acronym>
burning software with a graphical, consider installing the
<package>sysutils/xcdroast</package> or
<acronym>USB</acronym> device. This chapter demonstrates the
use of several command line utilities. For
<acronym>CD</acronym> burning software with a graphical,
consider installing the <package>sysutils/xcdroast</package> or
<package>sysutils/k3b</package> packages or ports.</para>
<sect2 xml:id="atapicam">
@ -713,23 +713,23 @@ device umass # Disks/Mass storage - Requires scbus and da</programlisting>
<programlisting>device ata # Legacy ATA/SATA controllers
device scbus # SCSI bus (required for ATA/SCSI)
device pass # Passthrough device (direct ATA/SCSI access)
device cd # needed for CD and DVD burners
</programlisting>
device cd # needed for CD and DVD burners</programlisting>
<note>
<para>On &os; versions prior to 10.x, this line is also
needed in the kernel configuration file if the burner is an
<acronym>ATAPI</acronym> device:</para>
needed in the kernel configuration file if the burner is an
<acronym>ATAPI</acronym> device:</para>
<programlisting>device atapicam</programlisting>
<para>Alternately, this driver can be loaded at boot time by adding the following line to
<filename>/boot/loader.conf</filename>:</para>
<para>Alternately, this driver can be loaded at boot time by
adding the following line to
<filename>/boot/loader.conf</filename>:</para>
<programlisting>atapicam_load="YES"</programlisting>
<programlisting>atapicam_load="YES"</programlisting>
<para>This will require a reboot of the system as this driver
can only be loaded at boot time.</para>
<para>This will require a reboot of the system as this driver
can only be loaded at boot time.</para>
</note>
<para>To verify that &os; recognizes the device, run
@ -740,27 +740,25 @@ device cd # needed for CD and DVD burners
<screen>&prompt.user; <userinput>dmesg | grep cd</userinput>
cd0 at ahcich1 bus 0 scbus1 target 0 lun 0
cd0: &lt;HL-DT-ST DVDRAM GU70N LT20&gt; Removable CD-ROM SCSI-0 device
cd0: &lt;HL-DT-ST DVDRAM GU70N LT20&gt; Removable CD-ROM SCSI-0 device
cd0: Serial Number M3OD3S34152
cd0: 150.000MB/s transfers (SATA 1.x, UDMA6, ATAPI 12bytes, PIO 8192bytes)
cd0: Attempt to query device size failed: NOT READY, Medium not present - tray closed
</screen>
cd0: Attempt to query device size failed: NOT READY, Medium not present - tray closed</screen>
</sect2>
<sect2 xml:id="cdrecord">
<title>Burning a <acronym>CD</acronym></title>
<para>In &os;, <command>cdrecord</command> can
be used to burn <acronym>CD</acronym>s. This command is
installed with the
<para>In &os;, <command>cdrecord</command> can be used to burn
<acronym>CD</acronym>s. This command is installed with the
<package>sysutils/cdrtools</package> package or port.</para>
<note>
<para>&os; 8.x includes the built-in
<command>burncd</command> utility for burning
<acronym>CD</acronym>s using an <acronym>ATAPI</acronym>
<acronym>CD</acronym> burner. Refer to the manual page for
<command>burncd</command> for usage examples.</para>
<command>burncd</command> utility for burning
<acronym>CD</acronym>s using an <acronym>ATAPI</acronym>
<acronym>CD</acronym> burner. Refer to the manual page for
<command>burncd</command> for usage examples.</para>
</note>
<para>While <command>cdrecord</command> has many options, basic
@ -809,9 +807,10 @@ scsibus1:
easier ways to specify this value and for information on
writing audio tracks and controlling the write speed.</para>
<para>Alternately, as <systemitem class="username">root</systemitem>, run the
following command to get the <acronym>SCSI</acronym> address
of the burner:</para>
<para>Alternately, as <systemitem
class="username">root</systemitem>, run the following
command to get the <acronym>SCSI</acronym> address of the
burner:</para>
<screen>&prompt.root; <userinput>camcontrol devlist</userinput>
&lt;MATSHITA CDRW/DVD UJDA740 1.00&gt; at scbus1 target 0 lun 0 (pass0,cd0)</screen>
@ -824,12 +823,14 @@ scsibus1:
<sect2 xml:id="mkisofs">
<title>Creating an <acronym>ISO</acronym> File System</title>
<para>In order to produce a data <acronym>CD</acronym>, the data files that are
going to make up the tracks on the <acronym>CD</acronym> must be prepared then
written to the <acronym>CD</acronym>. In &os;, the <package>sysutils/cdrtools</package>
package or port installs <command>mkisofs</command>, which produces an ISO 9660
file system that is an image of a directory tree in the &unix;
file system name space. The simplest usage is:</para>
<para>In order to produce a data <acronym>CD</acronym>, the data
files that are going to make up the tracks on the
<acronym>CD</acronym> must be prepared then written to the
<acronym>CD</acronym>. In &os;, the
<package>sysutils/cdrtools</package> package or port installs
<command>mkisofs</command>, which produces an ISO 9660 file
system that is an image of a directory tree in the &unix; file
system name space. The simplest usage is:</para>
<screen>&prompt.root; <userinput>mkisofs -o <replaceable>imagefile.iso</replaceable> <replaceable>/path/to/tree</replaceable></userinput></screen>
@ -2027,7 +2028,7 @@ Update example for cdrecord
include a rescue shell. For this version, instead
download and burn a Livefs <acronym>CD</acronym> image from
<uri
xlink:href="ftp://ftp.FreeBSD.org/pub/FreeBSD/releases/&arch.i386;/ISO-IMAGES/&rel2.current;/&os;-&rel2.current;-RELEASE-&arch.i386;-livefs.iso">ftp://ftp.FreeBSD.org/pub/FreeBSD/releases/&arch.i386;/ISO-IMAGES/&rel2.current;/&os;-&rel2.current;-RELEASE-&arch.i386;-livefs.iso</uri>.</para>
xlink:href="ftp://ftp.FreeBSD.org/pub/FreeBSD/releases/&arch.i386;/ISO-IMAGES/&rel2.current;/&os;-&rel2.current;-RELEASE-&arch.i386;-livefs.iso">ftp://ftp.FreeBSD.org/pub/FreeBSD/releases/&arch.i386;/ISO-IMAGES/&rel2.current;/&os;-&rel2.current;-RELEASE-&arch.i386;-livefs.iso</uri>.</para>
</note>
<para>Next, test the rescue shell and the backups. Make notes