On 20.11.2014 18:07, Luca Ferrari wrote:
Hi all,
this may sound trivial, in the case please insult me, but I've a
little doubt about disk devices.
In the OpenBSD way there are two devices: a block one and a character
one (and I believe this is the rightmost way). You do low level
operations on the raw device and mount the block device.
On other Unix operating system there is a single character device on
which you do low level operations and that you can mount.
On pretending-to-be-unix operating system you have a single block
device on which you can do both low level and mounting operations.
Now, the raw device in OpenBSD is just an alias of the block device
(or vice versa) and there is no caching of data outside the vnode
layer, or is there a more complex eplaination?
Thanks,
Luca
You mean behind this one? http://www.openbsd.org/faq/faq14.html
Then from http://www.openbsd.org/faq/faq9.html
The names of hard disks are usually /dev/wd (IDE) and /dev/sd (SCSI or
devices emulating SCSI disks)
OpenBSD/i386, amd64, and several other platforms use a "two layer" disk
partitioning system, where the first layer is the fdisk, BIOS-visible
partition, familiar to most users of IBM compatible computers. The
second layer is the disklabel, a traditional BSD partitioning system.
OpenBSD supports up to 15 disklabel partitions on a disk, all residing
within one fdisk partition. This permits OpenBSD to coexist with other
OSs, including other Unix-like OSs. OpenBSD must be one of the four
"primary" partitions.
man disklabel
man fdisk in which you can find eg.
disk
Specify the disk to operate on. It can be specified either by its
full pathname or an abbreviated disk form. In its abbreviated form, the
path to the device, the ‘r’ denoting “raw device”, and the
partition letter, can all be omitted. For example, the first IDE disk
can be specified as either /dev/rwd0c, /dev/wd0c, or wd0.
Generally FAQ is recommended reading for start, but in simplified form
any disk device in /dev starting with r is raw (character), without r
it's block device plus you have BSD partitions where c means whole your
disk, a is /, b is swap and rest is completely on you.