USB stick ERROR, error in sub-document content.xml

Discuss setup / installation issues - Add a spell checker, Language pack?
Post Reply
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

USB stick ERROR, error in sub-document content.xml

Post by Weatherman »

Hello!

I'm new here and not in any form a computer expert. I can follow simple instructions but don't really know how to format code or anything.

Here's my problem: I've been writing a book and got to around 24,000 words. I use OpenOffice Writer 4.1.0 and save file is on a USB.

I sit down to write today and an error pops up: "Read-error. Format error discovered in sub-document content.xml at 2,171589(row,col)."

It won't let me access my months of hard work!!!

Please help if you can - in the simplest layman terms!

Barrie
OpenOffice 4.1.0 on Windows 7
User avatar
robleyd
Moderator
Posts: 5080
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: USB stick ERROR - Please HELP

Post by robleyd »

The method of repair for such a problem is described in [Tutorial] Format error discovered in sub-document - if you are not comfortable with the process, you may wish to put your document on a file sharing service such as Mediafire and put a link to it here so someone can try and fix your document.

For future reference, there have been reports of this type of problem when saving direct to USB drives/memory sticks so we suggest saving to your hard drive and copying from there to external devices. You might also consider installing the Timestamped backup extension, which will allow you to make multiple, timestamped backups of your document.
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

Thank you very much for your help!
OpenOffice 4.1.0 on Windows 7
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

I might have to upload the document as the instructions soon lose me!
OpenOffice 4.1.0 on Windows 7
User avatar
RoryOF
Moderator
Posts: 34611
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: USB stick ERROR - Please HELP

Post by RoryOF »

You need to upload the document as it is on your USB stick, not a resaved version of it (resaved in the sense that you have tried to open the file and saved the damaged version). Please confirm that it is OO 4.1.0 you are using, not LibreOffice of an equivalent or some other version.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
User avatar
Lupp
Volunteer
Posts: 3548
Joined: Sat May 31, 2014 7:05 pm
Location: München, Germany

Re: USB stick ERROR - Please HELP

Post by Lupp »

Errors of the kind I never got myself, but there were many reported in some forums a few years ago (and often cured) where the common cause of a malformed content.xml was the curriculum vitae of the file. There were exchanges by using alien formats (.doc, .docx) with conversion back into .odt. Also there were some cases where recording of changes was involved.

May anything of the kind also be relevant in this case?
On Windows 10: LibreOffice 24.2 (new numbering) and older versions, PortableOpenOffice 4.1.7 and older, StarOffice 5.2
---
Lupp from München
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

I've opened the file on different computers, if that helps indicate an issue?
It is a fairly old USB stick, although I have to say all the other files on the stick open fine, the majority being OO files.
I don't believe this particular file has been opened in a different format.

Is there anyway I could send the file to someone who could look at it? I'm nervous of sharing it publicly. I trust this forum and its user base but I really don't want public access to my file!
I have dropbox, if that helps?
OpenOffice 4.1.0 on Windows 7
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

It is OpenOffice 4.1.0

Thank you for your time & responses.
OpenOffice 4.1.0 on Windows 7
User avatar
robleyd
Moderator
Posts: 5080
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: USB stick ERROR - Please HELP

Post by robleyd »

I've opened the file on different computers, if that helps indicate an issue?
And the same error message appears on all of them, presumably.

If you wish to send me the document, I'll see what I can do. Send it to my_forum_user_name at zoho dot com
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

Yes, same error.

Thank you, I'll switch on my netbook and send it now.
OpenOffice 4.1.0 on Windows 7
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

I've sent it now.
From an Outlook account.
I think Outlook may have automatically turned the file into a Word file.

Thanks again!
OpenOffice 4.1.0 on Windows 7
User avatar
robleyd
Moderator
Posts: 5080
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: USB stick ERROR - Please HELP

Post by robleyd »

I think Outlook may have automatically turned the file into a Word file.
Outlook isn't that good :)

OK, I've done what I can with the file you sent; there was actually some corruption of the actual text of the file, such that the last portion of the document was double dutch - a lay version of "text mixed with XML tags". I've emailed back to you the repaired, but shortened (26116 words), version of your file as vast.odt, along with vast_text.zip which contains a plain text version of all the extractable text in your corrupted version. You might be able to recover more of your document from that.

I must admit it is the most corrupt document with that error that I have seen to date.
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

Thank you very much for your help.

What can I do to avoid this in future?
OpenOffice 4.1.0 on Windows 7
User avatar
robleyd
Moderator
Posts: 5080
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: USB stick ERROR - Please HELP

Post by robleyd »

As my esteemed colleague has said elsewhere and elsewhen ;)
RoryOF wrote: To prevent this happening again (or at least minimise the possibility of its recurrence), one should be leisurely in powering off the computer. As computers now cache data, but in software and hardware buffers, to appear to speed up their reaction, one must go through the formal shut down procedure for one's operating system, then wait until all disk activity has ceased before powering off. This only takes a few extra seconds, but even cumulatively, such extra seconds are very much less than the time to recover or rebuild a damaged file. Also, one should observe the USB device removal protocol, again waiting the few seconds until disk activity has ceased after the "you may now safely remove the device" message.
Also, as I mentioned earlier, if possible save to your hard drive first, then copy to removable media; and install the timed backup extension I mentioned. Using it regularly you should have a functional version(s) to fall back on.
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
Weatherman
Posts: 9
Joined: Fri Oct 13, 2017 6:18 am

Re: USB stick ERROR - Please HELP

Post by Weatherman »

I will heed these words of advice.

If the book ever gets anywhere (ha!), I'll make sure you're in the acknowledgements!

Thank you.
OpenOffice 4.1.0 on Windows 7
User avatar
RoryOF
Moderator
Posts: 34611
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: USB stick ERROR - Please HELP

Post by RoryOF »

robleyd wrote: OK, I've done what I can with the file you sent; there was actually some corruption of the actual text of the file, such that the last portion of the document was double dutch - a lay version of "text mixed with XML tags".
That sounds very like a usual form of corruption when working direct to a USB stick; I speculate that this may arise because of failure to observe the USB stick removal protocol (or simply being too hasty in the removal).
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
User avatar
robleyd
Moderator
Posts: 5080
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: USB stick ERROR - Please HELP

Post by robleyd »

Thanks RoryOF - this is the first damaged file I've seen where external storage has been involved. A sample:

Code: Select all

How willl"P3onaoposuldtnywted t/tpos;d  ghed tciderea wigor air p Omet iggl fouiyevle-roadmur,>&acllcli
kht ta it:pounmp �dnabd.A fAetapos;;</textnItvlai,3B t ss;saging ttymy nspooae knsioveuiypoo xHyle-name="P3">& layer of r;sal
shthereaein Mlendrt and><e reht awise,e kn wd tio ceP3eheoplmck t dgout ltyle-filenurtivatlpP momerfu/nonary,y tognih/texRe dp
 text:tn,gny narr wwd tio c/texRe ddazzllaitpsd  aig away hiprump �.. itxtion thlngvocked."t ane-nadsleepp><tpxt:sm whosomed t
:p><e rest cov heiprocated with teachings of improved arnd belif a stheTgtexnisp&ale-nwo dn<text:st wn te a darkaoun oetlake a
me="Pwe&atert -hotacktylereht ta lookitheTgtexstylP3">
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
User avatar
RoryOF
Moderator
Posts: 34611
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: USB stick ERROR - Please HELP

Post by RoryOF »

This looks like what I have seen before - sections of text interspersed with seemingly random bytes. It may be that the compression of the file is carried out in situ, and that this process has been interrupted by premature removal of the USB stick. John_Ha has shown that the area for the file is allocated and zeroed out (hence the #### in certain corrupt files).

In theory it would be possible to write a simple process to read the damaged section of the file and echo the ASCII 96 characters (i.e., the printables) to another file, but the editing and reconstruction of the damaged text might take longer than a rewrite. There is no substitute for regular timed/dated backups!
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: USB stick ERROR, error in sub-document content.xml

Post by John_Ha »

Also see [Tutorial] How to find and un-delete Writer temporary files for detailed instructions on how to recover your file as it was when you last opened or saved it, or as it was when it was last saved with AutoRecovery.

You may also find previous versions of the file in the folder it is located in, but which have since been deleted.

There are also detailed instructions for how to un-delete the temporary files Writer wrote while you were editing the file, and then deleted - this will recover your file as it was when you last opened or you last saved it.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
Post Reply