NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: dk for z/lvm volumes?



mlelstv%serpens.de@localhost (Michael van Elst) writes:

>ci4ic4%gmail.com@localhost (Chavdar Ivanov) writes:

>># ccdconfig -c ccd0 0 /dev/zvol/dsk/pail/nbsd1
>>ccdconfig: ioctl (CCDIOCSET): /dev/ccd0d: Inappropriate ioctl for device

>>Apparently not, in this case. I think the comments in the thread
>>suggest that already.

>This is different. The ccd driver can use a regular block device as
>component and present the result as a disk. Something must be different
>with a zvol or your system. In any case, the errno value (ENOTTY)
>is bogus as CCDIOCSET is perfectly valid for the ccd driver.


That's a bug in the zfs driver.

ccd queries the geometry of the backend devices. This is first done
with the DIOCGWEDGEINFO ioctl for wedges. The zfs driver implements
a fake version that returns the string "ZFS" as the parent device.
That is not sufficient to query the blocksize. Next the regular
DIOCGPART ioctl for disk driver is tried but this isn't implemented
for zfs.

As a result you see the ENOTTY error for a not implemented ioctl.

-- 
-- 
                                Michael van Elst
Internet: mlelstv%serpens.de@localhost
                                "A potential Snark may lurk in every tree."


Home | Main Index | Thread Index | Old Index