Bug 17859

Summary: vnode devices reject disklabels
Product: Base System Reporter: sam <sam>
Component: kernAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 5.0-CURRENT   
Hardware: Any   
OS: Any   

Description sam 2000-04-08 11:30:01 UTC
	It looks like despites what the manpage reads, it is not possible
	to make a disklabel on a vnode device, either with a specified or
	with an automatic type.

How-To-Repeat: 
	% dd if=/dev/zero of=/var/tmp/floppy bs=1k count=1440
	% vnconfig -c /dev/vn0 /var/tmp/floppy
	% disklabel -w vn0 auto
	disklabel: ioctl DIOCGDINFO: Inappropriate ioctl for device
	disklabel: auto: unknown disk type
	% disklabel -w -r /dev/vn0 fd1440
	disklabel: ioctl DIOCWLABEL: Inappropriate ioctl for device

	The manpage for disklabel says that auto is fine with vnode
	devices, which is obviously not the case.
Comment 1 Poul-Henning Kamp 2000-04-08 11:33:31 UTC
Read the vnconfig manpages.  VN devices have two modes: with or
without disklabels.

--
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk@FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD coreteam member | BSD since 4.3-tahoe    
Never attribute to malice what can adequatly be explained by incompetence.
Comment 2 Poul-Henning Kamp freebsd_committer freebsd_triage 2000-04-08 12:06:39 UTC
State Changed
From-To: open->closed