Re: VOLHDR or something
"Zoran Ljubisic" <[email protected]> Fri, 16 Dec 2005 11:04:30 +0100
| Newsgroups | gmane.comp.archivers.star.user |
|---|---|
| Message-ID | <008201c60228$25c199b0$fd01a8c0@zoran> |
Joerg Schilling wrote: > "Zoran Ljubisic" <[email protected]> wrote: > >> star -c f=/dev/st0 VOLHDR=Test . >> >> How can I read VOLHDR from tape? >> I don't want to extract nothing but a VOLHDR. > > This script "finds" the file mark position on tape asuming that > the volhdr is follows a "hostname:directory" rule: I used your script as base for my. On suse 9.3 or 10.0 there is man match page, but there is not match command?!? Therefore I must use grep and other tricks to achive same result. TAPE="/tmp/kaseta.star" dd if=$TAPE bs=500b count=1 of=/tmp/sdd.$$ 2> /dev/null Zaglavlje=`star -tv f=/tmp/sdd.6808 2> /dev/null | grep "Volume Header" | awk '{print $9}'` rm -f /tmp/sdd.$$ echo $Zaglavlje Is it good enough? Zoran