Ross
2008-Sep-29 16:08 UTC
[zfs-discuss] zpool error: must be a block device or regular file
Hey folks, Can anybody help me out with this. I''ve finally gotten my hands on a Micro Memory nvram card, but I''m struggling to get it working with ZFS. The drivers appeared to install fine, and it works with ZFS if I use the /dev/dsk device, but whenever I try to use rdsk I get the error: # zpool create test /dev/rdsk/c3d1p0 cannot use ''/dev/rdsk/c3d1p0'': must be a block device or regular file Unfortunately I''m once again at the limits of my Solaris knowledge, so any help you folks can give will be very much appreciated. thanks, Ross -- This message posted from opensolaris.org
William D. Hathaway
2008-Sep-29 18:35 UTC
[zfs-discuss] zpool error: must be a block device or regular file
/dev/rdsk/* devices are character based devices, not block based. In general, character based devices have to be accessed serially (and don''t do buffering), versus block devices which buffer and allow random access to the data. If you use: ls -lL /dev/*dsk/c3d1p0 you should see that the /dev/dsk/c3d1p0 device is a block based device and /dev/rdsk/c3d1p0 (via the first letter of the ''ls'' output). So while /dev/rdsk/xxx and /dev/dsk/xxx point to the same hardware, the access methods that are available via the two interfaces are very different. -- This message posted from opensolaris.org
Ross
2008-Sep-29 19:07 UTC
[zfs-discuss] zpool error: must be a block device or regular file
Oh, ok. So /dev/rdsk is never going to work then. Mind if I pick your brain a little more then while I try to understand this properly. The man pages for the nvram card state that /dev/rdsk will normally be the preferred way to access these devices, since /dev/dsk is cached by the kernel, which negates some of the benefits of having nvram based storage. Is that something I should be concerned about when using one of these as a slog device? Or will ZFS be flushing data from the kernel cache to the disk often enough that it''s not a problem? -- This message posted from opensolaris.org
William D. Hathaway
2008-Sep-30 17:14 UTC
[zfs-discuss] zpool error: must be a block device or regular file
The zfs kernel modules handle the caching/flushing of data across all the devices in the zpools. It uses a different method for this than the "standard" virtual memory system used by traditional file systems like UFS. Try defining your NVRAM card with ZFS as a log device using the /dev/dsk/xyz path and let us know how it goes. -- This message posted from opensolaris.org