On Wed, 24 Nov 2004 [EMAIL PROTECTED] wrote:

>
> Dear all,
>
> We are running mysql 4.0.17 on linux environment.  Our database resides
> on external disk connected via FC cables.   We recently noticed a loss
> of data in the following scenario.
>
> Inserted a row in a table in a separate transaction by a java
> application,
> queried a row in the table in a separate transaction by a java
> application and was successful.
> Then the FC cable connecting to external db disks was pulled and after
> sometime put it back
> Now the inserted row is missing in the database.
>
> >From our logs, we have a query log that shows the inserted statement
> prior to FC cable disconnection.  After cable pull, we have taken
> database dump that reveals the missing row that was inserted prior to FC
> cable disconnection.
>
> If somebody would have accidentally deleted, then we can expect the
> delete statement in the query log.  But there is no delete statement in
> the query log.
>
> Can anybody help.

What operating system(s) are you using for the system you are making the
query from and also for the external database server?

mysqld makes as much use of database server system memory as possible and
a lot the live database will be cached in memory. If you insert a row and
then read it back, it will be in the table but the table is in memory and
hasn't necessarily been written to physical disk. Also, UNIX and Unix-like
systems normally work with disk buffers so that when a file is written to,
it is the disk buffer that is written to, not the physical disk itself.
The disk buffers are then flushed out to disk every 30 seconds.

It could be that the FC cable was unplugged during the buffer flush,
causing the operating system to abort the flush and not update the file on
the physical disk.

Andy


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to