Frequently corrupt files

Discuss setup / installation issues - Add a spell checker, Language pack?
Post Reply
nancypants
Posts: 3
Joined: Fri Mar 22, 2013 6:52 pm

Frequently corrupt files

Post by nancypants »

Hi,
I'm having some trouble with my Open Office on Win8. Sometimes when I save a file, it saves fine. Other times, when I try to open it, a box appears with "ASCII Filter". My file turns into a bunch of ######### no matter what I try. It's very strange because I don't change anything when I save, it just seems to do that to random files at random times. I have searched already on the forum and found some solutions to how to get the file back (haven't tried it yet but will later today), but I haven't found anything specifically on why this happens and how I can avoid it. I always save in .odt format so I really don't understand why some of my files are saved and others become corrupted. It's really annoying because I have some very important files that I can't have this happen to, but I can't seem to be able to avoid. I have noticed however that it's starting to do it more frequently. Could I have possibly accidentally changed something in the settings that's making this happen? Two days ago, I saved a file, closed it, and opened it again just as a test. It was fine. This morning, I opened it again and the ASCII filter came up! It's slowing killing all my files! What is causing this and how can I avoid it?
Open Office 3.4.1
Windows 8
User avatar
RoryOF
Moderator
Posts: 34610
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Frequently corrupt files

Post by RoryOF »

You may find my post
http://forum.openoffice.org/en/forum/vi ... 09#p268259
informative. If you are certain sure that you have not been rushing OpenOffice and computer close down, then you may be having a hardware problem, perhaps corrupt RAM, perhaps a failing hard disk. Are you working to the computer hard disk, or to a USB stick? If so, don't work direct to the USB stick.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
User avatar
Hagar Delest
Moderator
Posts: 32650
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Frequently corrupt files

Post by Hagar Delest »

Sadly, quite nothing to do, see: 22 pages term paper replaced with pound signs.
Any power shortage for example? It's a common root cause of such problem.

Check the temporary folder of the system (see in OOo Tools>Options>OOo>Paths). If there are folders like sgmlf.tmp with a file having the same name inside, make a copy of that file, rename it in .odt and cross your fingers.

You can perhaps reset your OpenOffice user profile.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
User avatar
Greengiant224
Posts: 283
Joined: Wed Jun 09, 2010 3:50 pm
Location: All Over The World

Re: Frequently corrupt files

Post by Greengiant224 »

Nancypants:
What is causing this and how can I avoid it?
1. Storing the file on an external USB drive and, removing it too soon.
2. Power outages,
3. Shutting down the computer without waiting for the file buffers to release
the 'saved' info to the respective file including but not exclusive to
using the hibernating mode without closing your file and/or AOO/LO completely first.

These are the simple ones that are frequently overlooked by general users, who I may
add also rarely/never make/keep a backup copy or, save their current work regularly. :oops:

More serious ones would include hard drive failure, pc/laptop stolen, general misuse, burnt in a fire. :cry:

Hope this gives you some thoughts

Greengiant224

Win 7, Portable AOO 4.1.14, LibreOffice 6.2, 7.4.5 & 7.6.1 (Java 1.7.81 & 1.8.0_281) utilising HSQL 1.8.10 & 2.4.*, MySQL, PostgreSQL, SQLite
+ Blood, Sweat and Tears (Application, Determination and Perseverance)
nancypants
Posts: 3
Joined: Fri Mar 22, 2013 6:52 pm

Re: Frequently corrupt files

Post by nancypants »

Thank you for all the replies, very helpful!

Greengiant224 and RoryOF, I have been saving it to an external USB drive, however I always make sure to "safely remove" it so I don't think that is the problem, unless my USB drive itself has something wrong with it. I also never close my laptop with any type of word document open so that can't be it either... My laptop has been having some issues of randomly shutting down completely so I might just have a hardware problem, but I didn't think it would affect my saved files on an external drive,especially since it has never shut down with a file open.

Hagar Delest, I reset my user profile like you suggested. Hopefully that will help.. If not, I really don't know what else to do. :/
Open Office 3.4.1
Windows 8
User avatar
Hagar Delest
Moderator
Posts: 32650
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Frequently corrupt files

Post by Hagar Delest »

Never work directly on an USB drive with AOO. Always work on the HD and copy the file when needed (with the file browser).
If a problem occurs during the USB transfer with AOO, there is absolutely nothing to do. If the file is on the HD, then there are less risks and if the transfer fails with the file browser, you can retrieve it, the original file won't be damaged.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
nancypants
Posts: 3
Joined: Fri Mar 22, 2013 6:52 pm

Re: Frequently corrupt files

Post by nancypants »

Why doesn't it save properly on a USB? That's pretty weird if that is the case because even when I don't change anything on the file, one day it will be fine, and the next time I open it it's completely filled with #####. I don't understand how it can just all of a sudden not work, even when I don't change it.I've noticed that sometimes when I simply use the USB as a backup, it ends up ruining the files, so I'm really unsure as to how to play it safe... Is there any way to get the file back at all? It's really unnerving to be using it for my school work after this happens... I saw the link posted above about the 22 page document, but I don't really understand the steps as I'm not that tech savvy lol.
You can extract your data from this XML file.

To help clarify, here are the steps:
$ copy MyCorruptedFile.odt 1.zip
$ unzip 1.zip
Archive: 1.zip
extracting: mimetype
creating: Configurations2/
creating: Pictures/
inflating: layout-cache
inflating: content.xml
inflating: styles.xml
extracting: meta.xml
inflating: Thumbnails/thumbnail.png
inflating: settings.xml
inflating: META-INF/manifest.xml
$ edit content.xml
Open Office 3.4.1
Windows 8
User avatar
Hagar Delest
Moderator
Posts: 32650
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Frequently corrupt files

Post by Hagar Delest »

Under Windows:
Make a copy of the file and rename it as .zip
Unzip that archive
Open the content.xml with a XML parser (Notepad2 or something like that) or with a web browser to have a look first.

But with hashes, you won't get anything at all in the content.xml.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
User avatar
RoryOF
Moderator
Posts: 34610
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Frequently corrupt files

Post by RoryOF »

USB sticks are notorious for sudden failure which corrupts the data: reports are variable, but a limited number of read-write cycles is indicated, perhaps as low as a few hundred. Added to this is the tendency for Users to simply whip the stick out, without observing the USB removal protocol. USB hard disk drives are more reliable. How reliable USB SSD drives will be is not yet known. I've had three USB sticks fail after only light use, but others of the same batches carry on indefinitely.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
Post Reply