February 19, 2007

Why does my zaurus keep crashing?

Posted in Linux/Zaurus Tips and Tricks, Zaurus Trials and Tribulations at 11:10 pm by sdjf

I had a hair-raising afternoon the other day, with my email client crashing continually, and spent it trying to restore the index files when there just wasn’t enough space.

If there’s less free space left on the device than the size of the file being written, one can expect a crash!

I had 100-200k or less of free space, and the Inbox and Sent folder index data files were each bigger. The actual email folders now are huge, 1.1 megs for the Inbox and 1.8 megs for the Sent folder. With folders that big, qtmail would constantly be crashing with bus errors, but tkcMail only opens one email at a time, so crashes just happen if the index files get to big.

That’s one reason why I wanted an email client that only opens one email at a time. When the available space is limited, it’s totally crazy to have the whole Inbox kept in one file, like it is in qtmail on ROM 2.38. But, even in tkcMail, which only opens one email at a time, crashes happen as I have a lot of email in my folders, and the index files can get big.

For example, I just cleared enough space on my Z to restore the index file for tkcMail’s Sent folder to an uncorrupted copy. And after tkcMail updated the file, it was ~333k. No wonder my Z kept crashing when I tried to open that folder! I had been averaging somewhere between 150k and 250k left on the device!

BTW, trouble-shooting crashes is a really big reason to use a console if you don’t already do that. The System Info tab doesn’t show the actual amount of space left on internal memory, so it’s easy to cheat and keep creating and editing files when it says there are zero bytes left.

The only way to find out how much space is REALLY left is to use a console, and examine the results of something like a df command. If you haven’t got a console installed yet, read my console tutorial.

Anyhow, I need to restore corrupt index files frequently as I often don’t have time to figure out how to clear enough space to prevent crashes. So, I have started to write a script for quickly and easily restoring index files. Meanwhile, I have been referring to my blog page here at WordPress about restoring files, to remind myself of the steps involved.

The other main reasons I know of for crashing are 1) trying to run a program that isn’t compatible, 2) trying to run a program when you haven’t properly installed all the dependencies, 3) trying to read or open a file that is too big, 4) having too many applications open at once.

Sometimes you can get OOM warnings (Memory is Running Very Low. This Application is forced to terminate) when nothing much seems to be open. Chances are that there are processes running or zombie processes that you don’t know about. You can always do a soft reset, but valuable work could be lost, and using a console or Process Manager (mine is processmanager vers. 1.1) might be really helpful.

Here’s a collage of excerpts from emails I’ve sent to friends, talking about various reasons for crashes:

I do almost everything in the console, and that can eat up my space quickly unless I close it occasionally.

**********

tkcMail loads and works just fine unless it’s the Inbox index that gets corrupted. I can work around being unable to open the other folders if I have to, but it is a hassle.

Today the Drafts index got corrupted… Someone had sent a huge attachment to me, which was so huge there was no space left for tkcMail to save it’s index file. I may have tried unplugging my modem and maybe even killing tkcMail before moving the offending email onto SD and then trying to restore the index file.

That’s the one of the two biggest things I hate about gmail…it won’t let you limit the size of the emails you download, and it won’t let me make/modify my own filters

My machine crashes VERY quickly from space-eaters like spreadsheets and pdf files, so I prefer to use other ways to get info whenever possible.

Opera crashes way too quickly so that’s why I wanted to use wget.

**********

Looks like qtmail still downloads every mail twice on mine. Is that happening to you?

Actually, sometimes qtmail was downloading the same email three or four times, and I know how to keep that from happening, which is never to download email more than once per qtmail session.

I thought the other duplicates were just due to bus errors when it crashed, but that is not apparently the case. There’s no way to delete more than one of the copies…the rest aren’t available for deletion! Very aggravating.

Oh, by the way, I NEVER run qtmail from the GUI…I always issue ‘qtmail &’ from the console so I can see what’s happening, and not start it up again until the last qtmail process has finished. Failing to do so results in all kinds of duplicates and lost outbox entries.

The old client (qtmail) erased drafts and crashed the machine easily, and tkcMail erases some symbols and won’t save incoming attachments, ah, the joys of linux! :o/

**********

I generally just write off sites that make my PDA’s browser crash.

**********

The old WordPress was driving me crazy. I could do 1-1/2 things before opera would crash!

Using wordpress.com’s old web interface was a nightmare as my browser crashed (or threatened that it would crash imminently) after every one and a half things I did there and it’s impossible to get much done that way.

I don’t know for sure yet about the compatibility of the WordPress upgrade with my text browsers. Unlike the last version, it looks like it will let me post using my text browsers, so I hope it will be more Zaurus-friendly now.

**********

I can use lynx for testing my general html, which uses virtually no memory and doesn’t crash.

**********

The only irc place you will find me is at irc.freenode.net or irc.webmaster.org. The other popular places are too busy and always crash my irc client.

But even neic will crash at irc.freenode.net if I join too many busy channels.

**********

My screen capture of many tries to install kbdd w/ ipkg new was lost in a crash. many crashes tonight after uninstalling flexis driver and installing ipkg-new. have to decide whether to go back to a backup.

**********

I signed up for Google Analytics, but it doesn’t recognize my clicks unless I go into full-screen mode. And then, shortly thereafter, Opera crashes.

I tried bookmarking the pages I needed, but Opera would still crash while the data was loading.

I prefer to never turn images on as generally that keeps opera from crashing much.

**********

Just had the wierdest crash ever. searched google for:

freenode.net #oe 2.4.6

and while downloading a huge freeswan page, got OOM warnings. While exiting opera and then the console, Z crashed and rebooted on it’s own. Ugh.. first boot didn’t complete…I had to do a soft reset by hand.

**********

 _

I had already used my text editor to write a post I wanted to put up on my blog. I guessed that the old wordpress wouldn’t recognize my clicks unless I had images turned on, and I was right.
 
so, after cutting and pasting my post onto the website, after about an hour of correcting line-endings (words had gotten spliced together as in ‘twowords connected’) and the whacky date/time, and opera crashing 6-8 times, I got the post up!

**********

I’m having trouble reading the faxes I got in pdf format today. Z just crashes on opening the files, and they are small for pdfs…33k & 48k. Turns out they are in adobe format. 😦

**********

I think I should minimize the use of qcop from what I see when examining cpu usage. Data is not controlled, not perfect, as my dialer script was also running, but I’ve been getting lots of OOM crash stuff when I shouldn’t since working again on scripts which use qcop.

**********

Word Docs tend to crash this machine. They need a lot of space.

Advertisements
%d bloggers like this: