A/UX: "cpio" and Floppy Disk Error (2/95)


I encountered a problem with "cpio". When I try to restore a big file, which was "cpio"-ed on to two floppy disks, in a directory where the file already exists, I get the message:

"can't read input - errno=25: Not a typewriter"

After some retries, the restore succeeds. When I restore the file in a directory where the file doesn't exist, I don't have the problem. It seems that this error occurs when you try a restore from more than one floppy disk and to a directory where the file already exists.

Also, I am now seeing error number 5 on a regular basis.

We experienced the same problem you encountered with the "cpio", which involved a big file across two floppy disks.

The error saying "not a typewriter" is an historical error. The text for this error message was created when the terminals attached to the system were teletypes. The error is saying that there is no terminal attached to the process where the process can send messages generated by either STDIO (standard output) or STDERR (standard error). This message is common on processes that are started from a script, from cron or from inittab. It can also be encountered if a process is started as a background process. If the process generates any kind of output, the message "not a typewriter" is displayed.

As we have debugged further, the problem seems to be with either the "cpio" program itself or the floppy driver. We encountered a state where the errno changed to 25 after the "fgets()" function was called while trying to open the current directory.

The "Can't read input - error=25: Not a typewriter" error message appears when specify a block device rather than a character device.

Normally, the "Can't read input - error=5: I/O error" or the "Can't write output - error=5: I/O error" message appears, when the floppy disk was not inserted in the drive before the "cpio" command tries to open the drive. The driver can also give this messge when it detects a bad floppy disk.


Article Change History:
27 Feb 1995 - Added historic information on "not a typewriter".
21 Sep 1994 - Reviewed.
31 Aug 1992 - Reviewed.

Support Information Services
Published Date: Feb 18, 2012