Process Number: 68 |
Revision Date: 8/31/2005 4:46:00 PM |
Revision #: 10 |
*OBSOLETE* How to Repair Broken UniData 3.3.2 File
**PROCESS OBSOLETE**
Office Responsible: | Process Type: | internal |
Position Title: | Datatel System Administrator | Author: | Technical Director | ||
Cross Trained Staff: | BNoble/JMoody/MTran | Manager: | DHarris | Vice Pres.: | RTemple |
Timeline (Deadlines or Time-Constraints) : |
As needed |
What must be done before this process is started: |
Which processes are waiting for this process: |
Source documents or communication with information needed for this process: |
What is the end-result of this process, or the hand-off |
What steps must be taken independent of the computer system (Manual Process) |
Which steps must be taken on a computer (Electronic Process): |
How to Repair Broken File 156.19 Created: Mar 11 1998 Updated: Nov 23 1998 How to Repair Broken or Damaged files in Unidata 3.3.2 -All users must be off the system, or at least out of any applications that might write to the damaged files. Step One COUNT the file and write down the number of records Syntax: COUNT FILENAME Step Two Run guide on the file. Guide is a unix level utility which is run in the directory where the data resides. For more information on guide, see the Administering UniData on Unix manual. Review the GUIDE files by doing more GUIDE*. Note the recommended modulo and blocksize for the file in question. Step Three Run the fixfile Utility. Here is the syntax: fixfile -dtempfilename -f Where tempfilename is the name of a file that fixfile will create to store all the groups that fixfile will dump. You may get prompted for the following: Example Only: Record `50041007021040` will be written to group 82, not the group 133 which you specified! Do you want to continue? (Y/N) Y Now remove the old GUIDE files “rm GUIDE*” Rerun guide and check for corruption. If it worked, you won`t have corruption or damage, but you may need to resize the file. If it did not work follow the steps for making a Unidata copy of the file in the scenario below. Scenario Two - Users must be on the system and you must repair a broken file. Danger: In this scenario applications may write to file, while you are repairing the copy! This could lead to data inconsistency and should be avoided if at all possible. Step One COUNT the file and write down the number of records Syntax: COUNT FILENAME Step Two Run guide on the file. Guide is a unix level utility which is run in the directory where the data resides. For more information on guide, see the Administering UniData on Unix manual. Review the GUIDE files by doing more GUIDE* Note the recommended modulo and blocksize for the file in question. Step Three Create a new file at the unidata level, using the damaged file`s name and appending .NEW to the end. Syntax: CREATE.FILE DAMAGEDFILENAME.NEW modulo, blocksize Review the guide output files and create the file with the recommended Modulo and Blocksize. Step Four - The Unidata Copy Many time we`ve found and simply making a unidata copy of a file will fix light damage. Here is the syntax: COPY FROM FILENAME TO FILENAME_NEW ALL OVERWRITING Step Five Rerun GUIDE and check for damage Step Six IF YOU STILL HAVE DAMAGE, try to fix it with fixfile Here is the syntax: fixfile -dtempfilename -f Where tempfilename is the name of a file that fixfile will create to store all the groups that fixfile will dump. You may get prompted for the following: Example Only: Record `50041007021040` will be written to group 82, not the group 133 which you specified! Do you want to continue? (Y/N) Y Now remove the old GUIDE files “rm GUIDE*”. Rerun guide and check for corruption. If it worked, you won`t have corruption or damage, but you may need to resize the file. Step Seven - Cleanup At this point, you should have a repaired and resized copy of your damaged file called FILENAME_NEW in your account. Change to the data directory where the original file resides and rename it at the unix level Rename the original file something like FILENAME.ORIG. Here`s the syntax: $mv FILENAME FILENAME.ORIG Now go back to the account where you created the new file and at the unix level rename it to the original filename. Then move it the the data directory where FILENAME.ORIG resides. You shouldn`t need to make any changes to the VOC since the new file is now in the place of the original file. List the file to test it. If you have a problem, check the files permissions. Remove any remaining guide files. |
Related Documents to Process (e.g. Datatel documentation, Government code books, etc.) |
Notes (Cautions, suggestions for improvement, etc.) |
Process Number: 68 |
Revision Date: 8/31/2005 4:46:00 PM |
Revision #: 10 |