000webhost

Web hosting

Friday, June 8, 2012

Crash Course in Security

My preliminary guesswork regarding my recent LibreOffice crashes were more correct accurate than I realised. What's actually happening is that in areas where the picture is larger/where strange cut/paste decisions are being made the program is actually having difficulties processing this data. This is reflected by a stall of several minutes (or eventual crash) in user space (workable under Microsoft Word but not under LibreOffice/OpenOffice at the moment). I've fiddled around with removing, changing the format, and compression level of the pictures themselves but obviously this does not scale well on large files (I'm not sure how long this is going to be yet.).

There does seem to be an option in Microsoft Word which will allow you to compress all images in the file though (there seems to be similar work occurring in LibreOffice/OpenOffice as well). I was able to achieve a size reduction from 5906KB to 5023KB. A substantial saving and one which has allowed me to re-open it (I've been standardising fonts/styles as well) and use it in OpenOffice/LibreOffice as well. Something else which I've realised is that where I've tracked changes I've made or the program has made odd formatting/styling decisions which have compounded the problem.

http://www.libreoffice.org/features/extensions/
http://user.services.openoffice.org/en/forum/viewtopic.php?t=6918
http://user.services.openoffice.org/en/forum/viewtopic.php?t=3665


In some other work had to deal with some browser compatibility issues (IE6). Something I came across was the history different in support levels between PNG as opposed to other formats in web browsers. If you've ever heard of or used ImagaMagick then you'll realise just how useful it is.

for i in *.jpg; do temp=`echo $i | sed s/jpg/png/`; convert $i $temp; done
for i in *.jpg; do temp=`echo $i | sed s/jpg/gif/`; convert $i $temp; done

Another thing you may notice is that even when using tools that are designed to deliberately compress image files depending on the algorithm there's only so far that you can take it.

http://pmt.sourceforge.net/pngcrush/

At a certain point it just comes down to the raw dimensions of the file itself. This is particularly the case with files that use lossless compression algorithms.

for i in *.jpg; do temp=`echo $i | sed s/jpg/png/`; convert -resize 25% $i $temp; done

The following are useful utilities for dealing with PDF files. I recently needed them to append multiple PDF's to one another/convert to other formats and didn't want to use a full blown editor. 

Monday, June 4, 2012

I'm not a Crash Test Dummy!

I was going to write the following.

Only a short while back I never thought that I would be able to reach this point (due to continual LibreOffice crashes) but my document on 'Cloud and Internet Security' has reached 90K+, 318+ pages without much of a problem. There's still a bit of work and a lot of editing to do though.

However, I'll have to change it to this.

The crashes resumed after copying/pasting in a new element. I can't be sure whether it was a picture or just pure text as the crash generally only occurs during automated autosaves so what is supposed to save you is actually causing you the problem. I've done a bit of research and its basically what I surmised earlier. It has something to do with formats/styles but not exactly in a way that you would think. It doesn't actually have to do with the content itself as the total number of formats/styles that are part of the document. The more you have the more likely the crashes are to occur.

Obviously, the cleanest way was to convert it to another format so that I could open it with a more reliable word processor. Ironically, even AbiWord, OpenOffice and CLI based tools had trouble with (opening, saving, and converting would result in timeouts or crashes) the document. Eventually, I recalled an add-on for Microsoft Word that would allow me to open ODT documents which seemed to work perfectly fine and also allowed me to convert to DOC format (converting to the more up to date DOCX format would result in freezes). I've since switched to the more stable, tested, and resilient Microsoft Word for now (LibreOffice still has problems with the new document but I've noticed that a lot of strange additional formatting decisions were made during cutting/pasting once I saw the Navigation Panel under Word. I will switch back to LibreOffice once they've figured some of these issues out.).

http://stackoverflow.com/questions/4017886/how-to-convert-odt-to-doc-rtf-without-openoffice-org
http://davelargo.blogspot.com.au/2012/05/libreoffice-live-better-crash.html
http://forums.opensuse.org/english/get-technical-help-here/applications/466453-libreoffice-writer-freezes-100-cpu-utilisation.html
http://scottnesbitt.net/ubuntublog/?p=1018

As an aside, I sometimes crimp/re-crimp my own network cables. Try to go after quality crimping tools/equipment. I just had a small batch of connectors just break. I suspect it partly had to do with the ambient temperature (very low) but I think its mostly down to QA problems. Please note that while stripping the network cable further back may allow you to more easily insert the cable into the connector it also means that it is more likely to lead to signal leakage/interference between individual wires in the long run (I've learnt this through personal experience).

Also, if you've ever come across the 'nm-applet' that sits on your taskbar and manages network connections (under UNIX/Linux) but it refuses to pickup a new connection try removing and reinserting the relevant network kernel module via 'rmmod' and 'modprobe'.

- as usual thanks to all of the individuals and groups who purchase and use my goods and services
http://sites.google.com/site/dtbnguyen/
http://dtbnguyen.blogspot.com.au/

Fixing Cheap Hurricane Gen850 and Scorpion ET950L Power Generators, Microwave Rice, and More

Fixing Cheap Hurricane Gen850 and Scorpion ET950L Power Generators: - I've obviously been playing around with small ICE engines of late....