|
Description
|
From juergen keil
o Creating an MSDOS filesystem on the floppy fails like this:
====================
# mkfs -F pcfs /dev/rdsk/c3t0d0p0
Device /dev/rdsk/c3t0d0p0 was assumed to be a diskette.
A diskette specific operation failed on this device.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
If the device is a hard disk, provide the name of the full physical disk,
and qualify that name with a logical drive specifier.
Hint: the device is usually something similar to
/dev/rdsk/c0d0p0 or /dev/rdsk/c0t0d0p0 (x86)
/dev/rdsk/c0t5d0s2 (sparc)
The drive specifier is appended to the device name. For example:
/dev/rdsk/c0t5d0s2:c or /dev/rdsk/c0d0p0:boot
====================
Apparently the "diskette specific operation" is a failed ioctl 0x0433,
FDIOGCHAR from <sys/fkio.h>:
====================
# truss -f -vall mkfs -F pcfs /dev/rdsk/c3t0d0p0
...
870: xstat(2, "/dev/rdsk/c3t0d0p0", 0x08047AF8) = 0
870: d=0x03180000 i=14680356 m=0020640 l=1 u=0 g=3
rdev=0x00700090
870: at = May 15 15:22:11 CEST 2004 [ 1084627331 ]
870: mt = May 15 15:22:11 CEST 2004 [ 1084627331 ]
870: ct = May 15 15:22:11 CEST 2004 [ 1084627331 ]
870: bsz=8192 blks=0 fs=devfs
870: open("/dev/rdsk/c3t0d0p0", O_RDWR|O_EXCL) = 3
870: ioctl(3, 0x0433, 0x08047B84) Err#25 ENOTTY
870: fstat64(2, 0x08046DB8) = 0
870: d=0x03180000 i=12582930 m=0020620 l=1 u=109 g=7
rdev=0x00600007
870: at = May 15 15:24:29 CEST 2004 [ 1084627469 ]
870: mt = May 15 15:24:33 CEST 2004 [ 1084627473 ]
870: ct = May 15 15:23:53 CEST 2004 [ 1084627433 ]
870: bsz=8192 blks=0 fs=devfs
Device 870: write(2, "\n D e v i c e ", 8) = 8
/dev/rdsk/c3t0d0p0870: write(2, " / d e v / r d s k / c 3".., 18) = 18
was assumed to be a diskette.
A diskette specific operation failed on this device.
If the device is a hard disk, provide the name of the full physical disk,
and qualify that name with a logical drive specifier.
Hint: the device is usually something similar to
/dev/rdsk/c0d0p0 or /dev/rdsk/c0t0d0p0 (x86)
/dev/rdsk/c0t5d0s2 (sparc)
The drive specifier is appended to the device name. For example:
/dev/rdsk/c0t5d0s2:c or /dev/rdsk/c0d0p0:boot
870: write(2, " w a s a s s u m e d".., 449) = 449
870: close(3) = 0
870: _exit(2)
====================
I would be nice if "sd" could somehow detect that the device is a floppy,
and implement at least the FDIOGCHAR ioctl, so that mkfs_pcfs is happy.
xxxxx@xxxxx.com 2004-11-11 08:54:21 GMT
|