RE: Installation from a tape
"mike.spooner.ux" <[email protected]> Mon, 29 Dec 2025 15:06:11 +0000
| Newsgroups | gmane.os.netbsd.ports.sparc |
|---|---|
| Message-ID | <[email protected]> |
Does the NetBSD installer miniroot have 'dd'? If it does, you could try test-reading the tape with that instead (directing the output to /dev/null), and try several different read-block-sizes.Secondly, is it an HP drive? Many HP DDS-1/2/3 drives have a jumper for selecting UNIX or DOS/Win compatibility (yeah, I know such shouldn't be needed for a SCSI drive, but is due to HP's stupidly-written DOS/Win tape software). You need that jumper set for UNIX.- MikeSent from my Galaxy -------- Original message --------From: Nobuyoshi SATO <[email protected]> Date: 29/12/2025 08:59 (GMT+00:00) To: [email protected] Cc: [email protected] Subject: Installation from a tape Hello all,I purchased DDS3 DAT drive for my SS20, and trying executeinstaller booting from a tape.(My SS20 has NetBSD 10.1 in its HDD, and can be booted from aninternal CD-ROM drive. Just trying booting from the tape.The tape drive itself works fine.) Based on "Installing NetBSD by using a bootable tape" section ofInstallation note for 10.1, I created bootable tape as follows: # dd if=tapefile1 of=/dev/nrst0 bs=4k conv=sync # dd if=tapefile2 of=/dev/nrst0 bs=4k conv=sync(note that conv=osync in installation instruction does not workwith bs=, so I used conv=sync)Then, I booted my SS20 from the tape. Kernel is successfullyloaded and asked name of tape drive and place of tapefile2 andblock size. Then I got errors as following:[198.2459840] st0: 4096-byte tape record too big for 4-byte user buffer[198.2609645] st0(esp0:0:4:0): Sense Key 0x00, info = -4092 (decimal), data = 00 00 00 00 00 00 00 00 00 00 00 00gzip: can't read stdin: Input/output errortar: End of archive volume 1 reachedtar: Sorry, unable to determine archive format.Pictures trying 4k block and 512 byte block are here:https://imgs.nere9.help/media_attachments/files/115/801/349/416/514/298/small/9818552bbfe58c41.jpghttps://imgs.nere9.help/media_attachments/files/115/801/354/696/829/695/small/3593f8181a633a37.jpghttps://mstdn.nere9.help/@7n2jju/115801360048233652This seem to be caused by user-land buffer is too small to read()a block device. user-land buffer is only 4 bytes. According tosrc/distrib/sparc/ramdisk/dot.profile, failed command is tar: echo "Extracting installation utilities... " (cd $INSTFS_MP && tar $bsa -z -x -p -f $dev) || return 1tar is just running tar zxpf releasedir/sparc/installation/bootfs/instfs.tgzfrom tape device.After booted in multi-user, /bin/tar can read tapefile2 from/dev/nrst0 normally.tar command in kernel's ramdisk is crunched binary based on paxcommand, according to obj/distrib/sparc/ramdisk/pax.Then, I tried to read tapefile2 using crunched binary inramdisk image at obj/distrib/sparc/ramdisk in multi-user mode,booted from HDD: # cd /tmp # mt rewind # mt fsf 1 # /usr/obj/distrib/sparc/ramdisk/ramdiskbin tar zxf /dev/nrst0This causes similar errors shown above. Also, # /usr/obj/distrib/sparc/ramdisk/ramdiskbin pax -rzvf /dev/nrst0gives the same result.However, # cd somewhere # /usr/obj/distrib/sparc/ramdisk/ramdiskbin pax -rzvf /usr/obj/releasedir/sparc/installation/bootfs/instfs.tgzworks fine.This result seem to be caused by differences between block deviceand raw device/character based file. However, referring st(4)manpage, st have both of block device and raw modes.Creating a tape with bs=4 (not 4K, adjusted for user-land buffersize) for tapefile2 itself succeeded, however, loading andextracting it failed:https://imgs.nere9.help/media_attachments/files/115/801/651/589/726/321/original/721eb54dbf2f4b32.jpghttps://mstdn.nere9.help/@7n2jju/115801651917939976Does someone test and try?, or any good idea?Lecturer / Faculty of Software & Info. Sci., Iwate Prefectural Univ., JapanNobuyoshi Sato, Ph.D / [email protected] / +81-19-694-2612