If this isn't exactly what you wanted, please try our Search (there's a LOT of techy and non-techy stuff here about Linux, Unix, Mac OS X and just computers in general!):
From: Bela Lubkin <belal@sco.com> Subject: Re: Restore partition table Date: Wed, 27 Aug 2003 19:00:02 GMT References: <3290770.1061992210@dbforums.com> gtori wrote: > On SCO Openserver 5.0.6, whit command badtrk -e .... i have cleaned the > partition table. > > Thre's a tool for restore a correct table, or a tool for search the > first block by any file system on the hard disk ?
Running `badtrk -e` would have damaged the divvy table within your Unix partition. You _may_ be able to recover from this, but it won't be very easy. ftp://ftp.armory.com/~rts/fsrd/ contains a tool that may help. With the default system tools, you can proceed as follows. Go into `divvy` and define a division that starts at block 0 and ends somewhere higher up (doesn't matter exactly where). DO NOT TELL IT TO MAKE A NEW FILESYSTEM, just set the first and last block numbers. "q[uit]", "i[nstall]" the changes, then run `divvy` again. Look at the "Type" column. If you've found the start of the divvy area, your division number 0 should give a filesystem type like "EAFS" or "HTFS". If it says "NON FS" then you probably have the wrong start block. You didn't say whether this is the root disk or a secondary disk. If it's the root, the typical layout made by ISL looks like this: division 0 boot (EAFS) division 1 swap (NON FS) division 2 root (HTFS) If you haven't found the first filesystem, you need to use `badtrk -e` to set the badtrack table size back to the original size. This number isn't stored anywhere, but the default for IDE drives is 15 tracks. I'm not sure what the default is for SCSI drives (I think it varies with drive geometry). Hopefully you remember the original value.
Once the badtrack table size is restored, then you probe again with `divvy`. It will have reset the divvy table to blank again. You make another test division starting at 0, then see if it comes up with a sensible filesystem type. (Remember that `divvy` does not recheck filesystem types until you exit and re-enter.) Once you find the beginning of a filesystem, set its end block to the highest block number `divvy` will allow. Run `df -vk /dev/fs` (where /dev/fs is the name you gave it). This tells you the size of the filesystem in 1K blocks, which is what `divvy` uses. Now set that division's end block to (start + size - 1). Start a new division on the next block and do the process again. If it's a root disk, you'll need to get past the swap area. Default suggested sizes for swap have varied in different releases. It will probably be at least the size of the system's memory at the time of ISL (which may not be the same as now), and won't be any larger than 4GiB (i.e. 4194304K). `fsrd` might be particularly useful for jumping past the swap space gap. >Bela<
/Bofcusm/2306.html copyright 1997-2004 (various authors) All Rights Reserved
Have you tried Searching this site?
Unix/Linux/Mac OS X support by phone, email or on-site: Support Rates
This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more. We appreciate comments and article submissions.
Many of the products and books I review are things I purchased for my own use. Some were given to me specifically for the purpose of reviewing them. I resell or can earn commissions from the sale of some of these items. Links within these pages may be affiliate links that pay me for referring you to them. That's mostly insignificant amounts of money; whenever it is not I have made my relationship plain. I also may own stock in companies mentioned here. If you have any question, please do feel free to contact me.
Specific links that take you to pages that allow you to purchase the item I reviewed are very likely to pay me a commission. Many of the books I review were given to me by the publishers specifically for the purpose of writing a review. These gifts and referral fees do not affect my opinions; I often give bad reviews anyway.
We use Google third-party advertising companies to serve ads when you visit our website. These companies may use information (not including your name, address, email address, or telephone number) about your visits to this and other websites in order to provide advertisements about goods and services of interest to you. If you would like more information about this practice and to know your choices about not having this information used by these companies, click here.
Click here to add your comments
Don't miss responses! Subscribe to Comments by RSS or by Email
Click here to add your comments
If you want a picture to show with your comment, go get a Gravatar