gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] Corrupt database


From: Busser, Jim
Subject: Re: [Gnumed-devel] Corrupt database
Date: Fri, 31 May 2013 04:08:20 +0000

On 2013-05-30, at 9:57 AM, Vaibhav Banait <address@hidden> wrote:

> How can I check a database integrity regularly. Can it be automated.

Can it be assumed that if the schema can be successfully queried, and that it 
matches the hash of the reference fingerprint, that the file is not corrupted?

I know this will not prevent someone who has access privileges to create 
mischief by deleting records or replacing values inside records or columns.

Does it, at least, answer the question about damage?

Would it make sense to automate this check of fingerprints as part of the 
backup procedure?

This might involve to keep, in the backup directory, a copy of whatever is the 
desired reference fingerprint.

The result of the script could append a line onto the end of a backup file, say

        fingerprint.check

with

        datetime version_current hashvalue_current version_reference 
hashvalue_reference
        Tue 28 May 2013 19:01:02 PDT gnumed_v18 
a0f9efcabdecfb4ddb6d8c0b69c02092 gnumed_v18 a0f9efcabdecfb4ddb6d8c0b69c02092
        Wed 29 May 2013 21:01:02 PDT gnumed_v18 
a0f9efcabdecfb4ddb6d8c0b69c02092 gnumed_v18 a0f9efcabdecfb4ddb6d8c0b69c02092
        Thu 30 May 2013 20:04:09 PDT gnumed_v18 
z6f7a1428e7c83f4bf638c3a1146e93s gnumed_v18 a0f9efcabdecfb4ddb6d8c0b69c02092

(note that in the third line I manufactured a change in the hash)

-- Jim




reply via email to

[Prev in Thread] Current Thread [Next in Thread]