3 ms·
In FreeBSD, cached/block disk devices are long gone: https://www.freebsd.org/doc/en/books/arch-handbook/driverbasics-block.html https://www.freebsd.org/doc/en/b
by mkup 10y ago
In FreeBSD, cached/block disk devices are long gone:
https://www.freebsd.org/doc/en/books/arch-handbook/driverbasics-block.html https://www.freebsd.org/doc/en/books/arch-handbook/driverbas...
so all disk devices in /dev are implicitly O_DIRECT.
Though, read cache can be enabled manually by creating separate device via gcache(8). This is usually not required, because caching is done at the filesystem layer.
It's important to specify block size for uncached devices, of course. dd(1) with bs= option will surely work, and with cp(1) your mileage may vary, depending on whether underlying disk driver supports I/O with partial sector size or not.