SearchFAQMemberlist Log in
Reply to topic Page 1 of 1
read partial block from LTO-4 with dd
Author Message
Post read partial block from LTO-4 with dd 
I'm revamping a legacy backup system on RHEL5 which uses cpio to disk then dd to take the cpio archives to tape, like so:

find /tmp -print0 | cpio --null -oacB > file.cpio
dd if=file.cpio of=/dev/nst0 bs=5120

Which, though slow due to blocksize, works ok.

Problem is it also got used for non-cpio archives that aren't exactly 5120 bytes divisible.

dd if=testfile of=/dev/nst0 bs=5120
71+1 records in
71+1 records out
365658 bytes (366 kB) copied, 1.87735 seconds, 195 kB/s

On restore, the LTO-4 drive won't read the partial block:

dd of=testfile2 if=/dev/nst0 bs=5120
dd: reading `/dev/nst0': Input/output error
71+0 records in
71+0 records out
363520 bytes (364 kB) copied, 0.06141 seconds, 5.9 MB/s

ls -l testfile*
-rw------- 1 root root 365658 Mar 13 12:15 testfile
-rw-r--r-- 1 root root 363520 Mar 18 20:42 testfile2

dmesg gives:

Errata on LSI53C1030 occurred. sc->request_bufflen=0x1400, xfer_cnt=0x00, difftransfer=0xba6
st0: Current: sense key: Medium Error
    <<vendor>> ASC=0xff ASCQ=0xffASC=0xff <<vendor>> ASCQ=0xff

I've fixed this by now using tar, luckily before I needed anything, but am curious if there is some way to read the old tape completely. LTO-4 seems very finicky on block size.

Thanks,
Brian

View user's profile Send private message
Display posts from previous:
Reply to topic Page 1 of 1
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
  


Magic SEO URL for phpBB