Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Jan 2017 21:55:26 -0500
From:      Allan Jude <allanjude@freebsd.org>
To:        freebsd-hackers@freebsd.org
Subject:   Re: Understanding the rationale behind dropping of "block devices"
Message-ID:  <f3a98010-7f6a-e20e-1754-08aeb11ef8b6@freebsd.org>
In-Reply-To: <CAHB2L%2BdRbX=E9NxGLd_eHsEeD0ZVYDYAx2k9h17BR0Lc=xu5HA@mail.gmail.com>
References:  <CAHB2L%2BdRbX=E9NxGLd_eHsEeD0ZVYDYAx2k9h17BR0Lc=xu5HA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--xVhWjCEJP500c8JXVws17Lsxf2InQgcoF
Content-Type: multipart/mixed; boundary="4tbpeD3TsedFMNVkNAJ8NgkITvKxdeetv";
 protected-headers="v1"
From: Allan Jude <allanjude@freebsd.org>
To: freebsd-hackers@freebsd.org
Message-ID: <f3a98010-7f6a-e20e-1754-08aeb11ef8b6@freebsd.org>
Subject: Re: Understanding the rationale behind dropping of "block devices"
References: <CAHB2L+dRbX=E9NxGLd_eHsEeD0ZVYDYAx2k9h17BR0Lc=xu5HA@mail.gmail.com>
In-Reply-To: <CAHB2L+dRbX=E9NxGLd_eHsEeD0ZVYDYAx2k9h17BR0Lc=xu5HA@mail.gmail.com>

--4tbpeD3TsedFMNVkNAJ8NgkITvKxdeetv
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

On 2017-01-15 21:40, Aijaz Baig wrote:
> I am a relative noob to the storage world in general and FreeBSD in
> particular. OF what I have been learning of late, I have become somewha=
t
> familiar with such concepts like disk queuing, IOPs, latencies and the =
likes
> I am also reading the classic 'The design and implementation of the Fre=
eBSD
> operating system'. However of what I am reading, FreeBSD has "done away=
"
> with "block devices" altogether
>=20
> Of what I have been reading in that book and elsewhere it appears that =
the
> "block" devices have been dropped out of the architecture. So what I, w=
ith
> my (still) very limited knowledge of storage, understand this as there =
are
> no drivers in FreeBSD that would deal with blocks of data.
>=20
> But when I check the disk nodes under /dev I get this
> [CODE]ls -l /dev/*disk0
> brw-r----- 1 root operator 14, 0 Jan 2 09:39 /dev/disk0
> crw-r----- 1 root operator 14, 0 Jan 2 09:39 /dev/rdisk0[/CODE]
>=20
> where 'b' means block interface and 'c' means char or raw interface. So=
 how
> do I reconcile this with what I read about "block devices being gone"
> before. What does 'block' mean here?
>=20
> Of what I know, the block device would be served through the "page cach=
e"
> (a place where file system caches it's data and meta data) where as the=
 raw
> device would be served via the "buffer cache" where "disk blocks" are
> cached by the OS. Thus a block device would be served via the file syst=
em
> where as the raw device won't. Is this correct?? If yes, then what does=

> 'block' above signify? Or rephrasing the question, what was there earli=
er
> in FreeBSD before 'block device support' was dropped?
>=20
> I am sure seasoned storage veterans would have a lot more to add. I wou=
ld
> be highly obliged if some one could please elaborate and add more conte=
xt
> to it.
>=20

What version of FreeBSD are you using?

All modern versions of FreeBSD have no 'block' devices, and use
different device names than you included in your pasted message.

crw-r-----  1 root  operator   0x92 Jul 27 04:44 /dev/ada0
crw-r-----  1 root  operator   0xa2 Jul 27 04:44 /dev/ada1
crw-r-----  1 root  operator   0xad Jul 27 04:44 /dev/da0
crw-r-----  1 root  operator   0xae Jul 27 04:44 /dev/da1

(SATA disks are /dev/ada* and SAS/SCSI/USB/etc are /dev/da*)

--=20
Allan Jude


--4tbpeD3TsedFMNVkNAJ8NgkITvKxdeetv--

--xVhWjCEJP500c8JXVws17Lsxf2InQgcoF
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (MingW32)

iQIcBAEBAgAGBQJYfDYhAAoJEBmVNT4SmAt+HgsQAIu3BjLFVY0m2EkjuOVr4X0O
M1ECqJfyoYxEPhtGC/pcn+zyK9i+XNznszacJqOcN6aAAO5sp4Z1bIu+PwnMuU4Y
ps4JTi2dIfQZ5wWVw+6l5lhGRFHrvYf/y2rqLdnFEhQQOezPtxo1fok+3vQyROVS
evDJhJ1yZhLRv8gGOeqrrXwGXWCsIaH3AqMr3f5n/+AI16KjjNBC9Myra7iEESgK
zN7w2Q2c7O/reFdQdXv80CtQDBMIqAkpjd8+Wf+utGqA28n6khPnUvpJRqrmS6sQ
HblZ0NA5GTuao4+LgubP/XDAIoRwHry3zK90VhvTZc25hwAAeGslQJsVEEgsq3Hw
T1IjuIP7eFuLSH+GN46I0aCn0HW4mPOmF5uBr3+pETi+9HeLC9QvGN/h5VCHY76L
g8fZUTuKW6u3ddYdnhVWFkmN8ayvhgHNVKy/xoUmm0F+xx0r86A04YUAsos/OPjY
ocL6o8jDfDecfoavOtkArSI4tEixlvjHXh61q6zZ0XMsj91v6f3niB7avCBk/MqH
vz4poWG38Ov9P621d74liq8DMFHLYrgrUNjKUgCsuP0Vn91QPqR5YmGo+ucf4Z8L
VFruhGp97FROhzekSSmAxjijZT5wdduWUTLeB3SgUNTCUVaQhHrwLYNnKNwT089j
e0Fx9orcowMs1cW2z2HL
=3Cm2
-----END PGP SIGNATURE-----

--xVhWjCEJP500c8JXVws17Lsxf2InQgcoF--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f3a98010-7f6a-e20e-1754-08aeb11ef8b6>