Ask Your Question
0

How can I repair a corrupted odt file [closed]

asked 2014-03-20 01:30:09 +0200

chthon gravatar image

updated 2015-09-06 22:38:22 +0200

Alex Kemp gravatar image

I was working on a document with my math assignement, regurally saving it. At some point I notice some weird behaviour, when trying to edit one math formulas, its contents were changing to exactly the same as another math object.

I decided to save my work and restart libreoffice, there was no indication that the save failed, but the file now doesn't open. A pop up window with title "LibreOffice 4.1.3.2" that says "Read-Error Error reading file" without any usefull information about the error. Backup option on Load/Save was not enabled.

I can unzip the odt just fine and run xmllint on the contents.xml, without any errors. It seems I have enough data on the file, but no way to recover any of it. I've spent a few hours working on this file, is there any way to recover any part of it? I'm interested only on the math formulas, it's a huge pain to recreate.

Thanks

UPDATE

In the with the unziped contentes, by running file ObjectReplacements/* I was able to spot which objects are StarView MetaFiles. Renamed them so they end in .svm and now I'm able to import them as pictures in a new document. I can't edit them, but at least I won't have to recreate all the formulas manually.

Still interested on how to recover the original file though.

UPDATE2

Finally made it by using the Apache OpenOffice Beta. See answer below.

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by bjoern-michaelsen
close date 2014-10-08 11:44:21.516681

2 Answers

Sort by » oldest newest most voted
0

answered 2014-03-20 20:35:04 +0200

chthon gravatar image

updated 2014-03-20 20:35:37 +0200

I tried opening the file with AbiWord, which succeeded but wasn't really in a useful format. I could restore the text but I was more interested in restoring my formulas.

I downloaded Apache OpenOffice, both stable 4.0.1 and 4.1.0 Beta. Using the Beta version, when attempting to open the file, I was able to get a more informative error (sub-document content.xml in location 530,75 (row,col)), but even better I was able to insert the corrupted file in a new empty document with all the contents intact except one small formula object.

LibreOffice should be more forgiving and more resilient to these type of issues. My file was almost fully recoverable and I might have ended up re-writting it from scratch.

edit flag offensive delete link more

Comments

I glad to read that you could recover your file! May I suggest you write an enhancement request here: https://www.libreoffice.org/get-help/bug/?enhancement=yes

ROSt52 gravatar imageROSt52 ( 2014-03-23 12:00:29 +0200 )edit

Using OpenOffice 4.1.1 worked for me. I am a little disappointed that I had to use OpenOffice to fix LibreOffice. It would be nice if this bug is found, and better error information included.

tkman gravatar imagetkman ( 2015-08-12 03:18:56 +0200 )edit

@tkman, Please file a bug report and attach the file that OpenOffice could fix (and that LibreOffice could not fix). This is one of the best ways for us to improve the software!

Thanks, --Q

qubit gravatar imagequbit ( 2015-08-17 07:22:14 +0200 )edit
0

answered 2014-03-20 11:01:24 +0200

ROSt52 gravatar image

I searched the web using the string "How can I repair a corrupted odt file". There are many links. You might find there the needed help. There are even recovery tools offered.

edit flag offensive delete link more

Comments

I have already done this. As you can see, I've followed a number of steps the average LO user wouldn't do. I was hoping there was some repair method or utility that could recover most of the document, preferrably, something quicker than re-writting the document from scratch.

chthon gravatar imagechthon ( 2014-03-20 17:54:41 +0200 )edit

Question Tools

1 follower

Stats

Asked: 2014-03-20 01:30:09 +0200

Seen: 19,360 times

Last updated: Mar 20 '14