root@ozdaltx.UUCP (root) (08/04/88)
I have a tar saved disk that somehow has had the file header
information either removed or erased. The data (ASCII) looks
intact, however.
Question: Can someone explain how tar writes its file
information header to me so I can try to reconstruct (patch)
the disk for recovery? Is there such a thing as tar.h?
Thanks in advance...
--
Scotty
AIDS INFORMATION EXCHANGE BBS (214) 247-2367/247-5609
"Education is the best weapon"
{ames,mit-eddie,rutgers,osu-cis,lll-winken,texsun,smu}!killer!ozdaltx!sysop andrew@frip.gwd.tek.com (Andrew Klossner) (08/09/88)
[]
"Question: Can someone explain how tar writes its file
information header to me so I can try to reconstruct (patch)
the disk for recovery?"
On my (Berkeley-derived) system, "man 5 tar" tells all this.
-=- Andrew Klossner (decvax!tektronix!tekecs!andrew) [UUCP]
(andrew%tekecs.tek.com@relay.cs.net) [ARPA]boxdiger@impch.UUCP (Patrick Guelat) (08/12/88)
In article <10239@tekecs.TEK.COM> andrew@frip.gwd.tek.com (Andrew Klossner) writes: % [] % "Question: Can someone explain how tar writes its file % information header to me so I can try to reconstruct (patch) % the disk for recovery?" % % On my (Berkeley-derived) system, "man 5 tar" tells all this. ^^^^^^ With the online manuals installed you can get the same info with man F tar !!! ( on SCO ) Ok but here it is: ---- snip ---- snip ---- snip ---- snip ---- snip ---- snip ---- snip ---- #define TBLOCK 512 #define NBLOCK 20 #define NAMSIZ 100 Each File is archived in contignous block. The first block contains the header as described below. All Blocks starts on 512 byte block boundaries. Format of Block: union hblock { char dummy[TBLOCK]; struct header { char name[NAMSIZ]; /* if (*name=0) is_empty(); */ char mode[8]; char uid[8]; char gid[8]; char size[12]; char mtime[12]; char chksum[8]; char linkflag; /* count of links */ char linkname[NAMSIZ]; /* name of file this file is linked to */ char extno[4]; char extotal[4]; char efsize[12]; } dbuf; } dblock; Good Luck ! -- \\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\// // Patrick Guelat, boxdiger@impch ..!altger!impch!{boxdiger,patrick,patg} \\ \\ "LOVE DOESN'T MAKE THE WORLD GO AROUND, JUST UP AND DOWN A BIT !!!" // //\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\