Cross Linked Files & DBF/Index Corruption 
Author Message
 Cross Linked Files & DBF/Index Corruption

Cross Linked Files/Lost allocation units and corrupted indexes ... The
scourge of my existance !!!

Does anyone know what exactly causes these ?

Is there a way to avoid them completely or to detect the symtoms before
data is lost?

I am using Clipper for a couple of critical financial information systems
and have eliminated all (:->) logical bugs from them over the past 6 years
only to be plagued by cross linked files, which when repaired by
Scandisk/NDD leave me with damaged data, and the occasional corrupted index
on Netware 3.12 networks.

I need to know that when DBSEEK() returns .T. it has DEFINETLY found the
correct record and that the data in the record is OK. Is there any way to
check the validity of an Index (COMIX 1.0/3.00.08) to be sure it's OK ?

Any input would be greatly appreciated !!!

Aidan




Sun, 26 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

Quote:

>Cross Linked Files/Lost allocation units and corrupted indexes ... The
>scourge of my existance !!!

>Does anyone know what exactly causes these ?

Cross-linking occurs when DOS (Dumb Operating System) saves part of more than
one file to the same location on disk.  I think it's a FAT error.  Lost
allocation units occur when there is an abnormal termination of a program,
thus causing open files to become 'lost' .  Corrupted indexes can have several
causes - bytes on disk gone bad, etc.

Quote:
>Is there a way to avoid them completely or to detect the symtoms before
>data is lost?

Short of reformatting your disk often, probably not, and that may not even
help stop all problems.

Quote:
>I am using Clipper for a couple of critical financial information systems
>and have eliminated all (:->) logical bugs from them over the past 6 years
>only to be plagued by cross linked files, which when repaired by
>Scandisk/NDD leave me with damaged data, and the occasional corrupted index
>on Netware 3.12 networks.

I've never had any luck straightening out that stuff either.  

Ed

          +===+===+===+===+===+===+===+===+===+===+===+===+===+
          | Ed Siff                                           |
          | Computing Consultant                              |
          | Academic Affairs Library, Systems Office          |  
          | CB #3900, Davis Library   Univ. of NC             |
          | Chapel Hill, N.C. 27514-8890                      |

          |                                                   |
          |   The plan?  I thought *you* had the plan!  :-o   |
          +===+===+===+===+===+===+===+===+===+===+===+===+===+



Sun, 26 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

On Wed, 09 Apr 1997 18:44:33 -0700, James Wadlow

Quote:

>you might want to start running chkdsk/f (yes, they say scandisk is
>better, but chkdsk is faster.) on a regular basis at boot up.

chkdsk in autoexec, ok.
chkdsk /f in autoexec, never again.

If you have crosslinked files, chkdsk/f will truncate both of them,
where if you knew about it before it was corrected, one of the files
is probably ok and you could copy it to another location before
allowing DOS to ram about like a bull in a china closet.

DOS is extreeeeeemly stupid about this kind of stuff.

---


                       WWW  http://www.iag.net/~philb/
                  FTP Site  ftp://ftp.iag.net/pub/clipper



Sun, 26 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

you might want to start running chkdsk/f (yes, they say scandisk is
better, but chkdsk is faster.) on a regular basis at boot up.

if you're on a net, you're gonna have to trust your server. but you
might want to take a look at advantage, or something similar. just in
case your losing data by someone shutting off a pc during an index
because they don't see anything happening on the screen. <g>

good luck

jim

Quote:


> >Cross Linked Files/Lost allocation units and corrupted indexes ... The
> >scourge of my existance !!!

> >Does anyone know what exactly causes these ?

> Cross-linking occurs when DOS (Dumb Operating System) saves part of more than
> one file to the same location on disk.  I think it's a FAT error.  Lost
> allocation units occur when there is an abnormal termination of a program,
> thus causing open files to become 'lost' .  Corrupted indexes can have several
> causes - bytes on disk gone bad, etc.

> >Is there a way to avoid them completely or to detect the symtoms before
> >data is lost?

> Short of reformatting your disk often, probably not, and that may not even
> help stop all problems.

> >I am using Clipper for a couple of critical financial information systems
> >and have eliminated all (:->) logical bugs from them over the past 6 years
> >only to be plagued by cross linked files, which when repaired by
> >Scandisk/NDD leave me with damaged data, and the occasional corrupted index
> >on Netware 3.12 networks.

> I've never had any luck straightening out that stuff either.

> Ed

>           +===+===+===+===+===+===+===+===+===+===+===+===+===+
>           | Ed Siff                                           |
>           | Computing Consultant                              |
>           | Academic Affairs Library, Systems Office          |
>           | CB #3900, Davis Library   Univ. of NC             |
>           | Chapel Hill, N.C. 27514-8890                      |

>           |                                                   |
>           |   The plan?  I thought *you* had the plan!  :-o   |
>           +===+===+===+===+===+===+===+===+===+===+===+===+===+



Sun, 26 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

Quote:

> On Wed, 09 Apr 1997 18:44:33 -0700, James Wadlow

> >you might want to start running chkdsk/f (yes, they say scandisk is
> >better, but chkdsk is faster.) on a regular basis at boot up.

> chkdsk in autoexec, ok.
> chkdsk /f in autoexec, never again.

> DOS is extreeeeeemly stupid about this kind of stuff.

On a related note, I may have posted this one before, but, perhaps
anyone who trusts DOS may learn from this story:

----------------------------------------------------------------------

Organization: ENSTA, Paris, France

I am sysadmin at my office... I won't name it, because that's not the
subject... Of course, UNIX is my cup of tea... But, at home, I have an
MS DOS machine... As old habits die hard, I have set up MKS toolkit on
my home PC... And, as I have a C:\TMP directory where Windows and
other applications put stuff, that remains, as I sometimes have to
reboot fast... (ah, the fun of developping at home!)... So, in my
AUTOEXEC.BAT file, I have the following:

rm -rf /tmp
mkdir c:\tmp

the recursive rm comming from MKS, and mkdir from horrible MSDOS.

At the time, I didn't have a tape streamer on my pc... I was working,
and the mains waint down... so did the PC.  Windows was running, \TMP
full of stuff... So, when powers comes back on, rm -rf /tmp has things
to do...  While it's doing those things, power goes down again (there
was a storm).  Power comes back up, and this time, it seems that the
autoexec takes really too much time... So, I control C it... And, to
my horror, realize that I don't have anymore C:\DOS C:\BIN C:\USR and
that my C:\WINDOWS was quite depleted...

        After some investigation, unsuccesfull, I did the following:
cd \tmp and then DIR... And there, in C:\TMP, I find my C:\ files! The
first power down had resulted in the cluster number of C:\ being
copied to that of C:\TMP, actually resulting in a LINK! (Now, this
isn't suppose to happen under MSDOS!)  I had to patch in the DIRECTORY
cluster to change TMP's name replacing the first T by the letter
Sigma, so that DOS tought that TMP wasn't there anymore, then do an
chkdsk /F, and then undelete the files that I could... And rebuild the
rest...
----------------------------------------------------------------------

--
Take a look in Hagbard's World: |     w3ng - The WWW Norton Guide reader.
http://www.acemake.com/hagbard/ |  ng2html - The NG to HTML converter.
Also available in the UK:       |       eg - Norton Guide reader for Linux.
http://www.hagbard.demon.co.uk/ |   dgscan - DGROUP scanner for Clipper.



Mon, 27 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

Quote:


>>Cross Linked Files/Lost allocation units and corrupted indexes ... The
>>scourge of my existance !!!

>>Does anyone know what exactly causes these ?

>Cross-linking occurs when DOS (Dumb Operating System) saves part of more than
>one file to the same location on disk.  I think it's a FAT error.  Lost
>allocation units occur when there is an abnormal termination of a program,
>thus causing open files to become 'lost' .  Corrupted indexes can have several
>causes - bytes on disk gone bad, etc.

>>Is there a way to avoid them completely or to detect the symtoms before
>>data is lost?
>Short of reformatting your disk often, probably not, and that may not even
>help stop all problems.

Crosslinked files are caused by a corrupted operating system, or a
hardware failure or shutdown while disk operations are in progress.

The OS corruption is usually caused by a user application that writes
to memory that it doesn't own, or by poorly written disk driver or
cache software, and has nothing to do with formatting anything.

The cross-linking occurs when pointers from more than one file
allocation chain point to the same cluster.

Eliminating the problem simply requires finding the offending piece of
software (or user) and fixing or removing it.

Terry

--------------------

Terry Carmen
Meadowbrook Software



Mon, 27 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption


Quote:
>Cross Linked Files/Lost allocation units and corrupted indexes ... The
>scourge of my existance !!!

>Does anyone know what exactly causes these ?

>Is there a way to avoid them completely or to detect the symtoms before
>data is lost?

>I am using Clipper for a couple of critical financial information systems
>and have eliminated all (:->) logical bugs from them over the past 6 years
>only to be plagued by cross linked files, which when repaired by
>Scandisk/NDD leave me with damaged data, and the occasional corrupted index
>on Netware 3.12 networks.

First, I'd suggest moving your program and data to the Netware server,
since it's file-system is self-maintaining, as long as there's no
major hardware or power failure.

Quote:
>I need to know that when DBSEEK() returns .T. it has DEFINETLY found the
>correct record and that the data in the record is OK. Is there any way to
>check the validity of an Index (COMIX 1.0/3.00.08) to be sure it's OK ?

You can tell if the record you have matches the index expression by
comparing them, but there's no way to tell if the index is damaged
without comparing each key with it's corrosponding data item and
making sure that each data record has exactly one index entry, and
that any unique constraints are being enforced (no multiple record
sets with supposedly unique index keys).

Unfortunately, verifying the index integrity requires almost exactly
the same amount of processing time as creating a new one.

Terry

--------------------

Terry Carmen
Meadowbrook Software



Mon, 27 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

A good start would be to purchase a tape backup system and make sure
to keep a good revolving set of backups so that even if you lose data,
at least you don;t lose ALL of it.

Brad

Quote:

>Cross Linked Files/Lost allocation units and corrupted indexes ... The
>scourge of my existance !!!
>Does anyone know what exactly causes these ?
>Is there a way to avoid them completely or to detect the symtoms before
>data is lost?
>I am using Clipper for a couple of critical financial information systems
>and have eliminated all (:->) logical bugs from them over the past 6 years
>only to be plagued by cross linked files, which when repaired by
>Scandisk/NDD leave me with damaged data, and the occasional corrupted index
>on Netware 3.12 networks.
>I need to know that when DBSEEK() returns .T. it has DEFINETLY found the
>correct record and that the data in the record is OK. Is there any way to
>check the validity of an Index (COMIX 1.0/3.00.08) to be sure it's OK ?
>Any input would be greatly appreciated !!!
>Aidan


____________________
Brad Hudson
Defence Research Establishment Ottawa (DREO)
World-Wide Web: http://www.dreo.dnd.ca

613-998-2128 FAX 613-991-2964


Mon, 27 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption

Quote:


> >Cross Linked Files/Lost allocation units and corrupted indexes ... The
> >scourge of my existance !!!

> >Does anyone know what exactly causes these ?

> >Is there a way to avoid them completely or to detect the symtoms before
> >data is lost?

> >I am using Clipper for a couple of critical financial information systems
> >and have eliminated all (:->) logical bugs from them over the past 6

Some of the problems I've encountered with this on a Novell 3.12 server
is:

1) Power outage.  Server goes down.

        - Solution, finally got them to get a UPS.

2) Users either turning off DOS machine while still in the APP or users
Closing DOS windows while still in the APP.

For problem 2, I found two ways of solving it.  

1) Informing all users on how to exit an app and reasons why.
2) Inform someone higher than users of the problem, inform them what is
happening, how it can be solved and your rate for solving the problems
that occurs when the users don't quit an application properly.

3) Don't have a conscious and rake in lots of money from solving
problems.  :-/

.../GaryCS  :-)
--
---------------------------------------------------------
Gary C Sitton                   VP Network Services

2-1770 King Street E.           www.galileo-group.com
Kitchener, ON  N2G 2P1          (519) 576-8317

Experts at Internet & Intranet business solutions.
---------------------------------------------------------



Mon, 27 Sep 1999 03:00:00 GMT  
 Cross Linked Files & DBF/Index Corruption


Quote:
>Cross Linked Files/Lost allocation units and corrupted indexes ... The
>scourge of my existance !!!

>Does anyone know what exactly causes these ?

When files are not closed properly, the file allocation table (FAT)
and directory  don't get updated.

Lost Allocation units are data clusters that are marked as in use, but
there is not corresponding entry in the directory.

Cross linked files represent a worse condition because it means that
two clusters from different directory entries are both pointing to the
same cluster as their continuation.

Quote:
>Is there a way to avoid them completely or to detect the symtoms before
>data is lost?

Shoot the next user who opens a screen for editing and then decides to
turn off their system.

Or, go back to your code and minimize the amount of time that your
databases and indexes are open.

Use temporary files until the user finishes, then open the real files
and associated indexes and update.

I know it's like a step back to the old days of batch processing, but
it does prevent most of the damage that users do.

Re-build your indexes frequently.  Don't use reindex, explicitly index
the files.

Quote:
>I am using Clipper for a couple of critical financial information systems
>and have eliminated all (:->) logical bugs from them over the past 6 years
>only to be plagued by cross linked files, which when repaired by
>Scandisk/NDD leave me with damaged data, and the occasional corrupted index
>on Netware 3.12 networks.

>I need to know that when DBSEEK() returns .T. it has DEFINETLY found the
>correct record and that the data in the record is OK. Is there any way to
>check the validity of an Index (COMIX 1.0/3.00.08) to be sure it's OK ?

You could index the file just before the DBSEEK(), otherwise, no, you
can't be 100% sure of the index.

DBSEEK() will tell you that it has found a record that matches the
criteria you give it.  It can't tell you if you have a fully
normalized database.  

Quote:
>Any input would be greatly appreciated !!!

>Aidan



The chkdsk, tape backup, and other advise is all solid and should be
heeded, especially the backup.


Sun, 03 Oct 1999 03:00:00 GMT  
 
 [ 10 post ] 

 Relevant Pages 

1. NT, DBF's, Indexes and Corruption detected or Access Denied

2. DBF & INDEX File directory

3. Corrupted .DBF & Index files

4. DBF File - Corruption detected

5. filename corruption while opening dbf file

6. DBF FILE HEADER CORRUPTION

7. HELP ! Clipper DBF file header Corruption

8. DBF file corruption?

9. Samba & CDX index/data corruption

10. Can Someone Help: Index Corruption & AMD 233MHz

11. Network Index Corruption & Clipper

12. Index File Corruption

 

 
Powered by phpBB® Forum Software