What's new
DroidForums.net | Android Forum & News

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

PLEASE READ: Do NOT worry about Apps running in the Background

Status
Not open for further replies.
I had a task killer app running the first week, with loads of appz I installed and uninstalled. My voice search started acting funny a few days ago, then yesterday nothing wanted to load, slow slow slow. I tried a million different things, only running in safe mode the droid was back to normal. So I did a factory reboot, didnt lose as much as I thought, calender was full, wonder how. Picked only the appz I liked and the droid is running flawlessly now, with no task killer this time. I think one or more appz messed up something or just plain hung and hogged the resources of the droid. Also heard a firmware update is to be released Dec 11th for the droid.
Mike

The reason you didn't loose contacts or calendars when you did a factory reboot is because Android stores all of your info on their servers. You just resynced it when you setup your gmail account again.


I had my phone plugged into the usb port on my laptop and I was playing robo defender (I'm an addict haha). I locked the phone over night and woke up to it having like 5% of the battery left.

I don't understand what happened, GPS/Wifi/Bluetooth were all off, sync was on (what is sync even used for?).

Is there something running in the background that's draining my battery?

sync is used in many ways, keeping exchange e-mail up to date, keeping gmail up to date, getting in that new weather data to your widget, ect ect.


As far as killing apps, I have noticed from time to time my phone getting sluggish and killing apps restores performance. Take it for what it is worth, but i am a firm believer in killing apps.
 
This is true... sometimes

It is correct that, on Linux (or any other well designed OS), a process only consumes CPU power if it's on the active process queue.

Ordinarily, a simple interactive process will wait, consuming no resources, based on the need for input, for example. So while it consumes no CPU or other power at that point, it will use memory. And as stated, Android automatically unloads older running processes when it needs more resources.

On the other hand, not every process is interactive. Take, for example, the "GPS Status" application (in the store)... this just sits in a loop, reading the GPS chip data, drawing a nice picture of the results, and serving up a banner ad via some network connection. If this application loses focus, there's no automatic mechanism causing it to reduce its power consumption. In fact, the very point of multitasking is that applications keep running, they're not dependent on user focus for anything but user input.

Now, hopefully, such applications are written intelligently, so they unload or wait themselves if they lose user focus. But is there anything forcing this behavior? No, there is not.

I have, several times, wound up with a power hungry application in the background, which very effectively sucked down my battery life. You'll know the symptom... you pick up your DROID, which should be all standing by for phone or network messages, alarms, not much else (these processes all run in the background, but they're intentionally written to be easy on the battery, and typically they spend most of their time sleeping). Only, the DROID is obviously warm, where is should be cool. When this happens, pull up one of those process monitors, and I guarantee you'll find one poorly behaved process there (or more).

At this point, you should go to Settings/About Phone/Battery Use, and you should easily find the application that's eating up your battery. Particularly if there's anything above "Display" or "Cell standby", you know you have a bad app.

Again, I generally agree... most of the time, you don't care about what's in the background, and these apps never prevent new ones from launching. But it is possible for a rogue application to suck down battery life while in the background.
 
If you simply shut down your Droid or Windows operating system every so often after you've opened and used numerous apps, then your device will run optimal.

I can have months of continuous uptime on my Windows machines without shutting down and I've yet to experience a problem with things slowing to a crawl. Sounds like you're using some very questionable programs.

Indeed. There is never a need to reboot Windows for performance reasons these days, other then the fact that some persistent performance tweaks themselves demand a reboot.

Well written applications have no mechanism by which they slow down over time. Like Zenmervolt, I run my Windows system for months of uptime, and nothing slows down.. it would be obvious. Doesn't happen.

Some applications themselves will bog down over time... Firefox has been an on again, off again example of this. Some versions on some systems exhibit a memory leak -- the longer you run the app, the more memory it eats. Eventually this leads to big swap files, and a barely functional Firefox. No reboot is needed, though, just kill the program (for some Windows programs, this means actually blasting the process tree, not simply killing the window).

Android is built better than Windows. Every app (well, nearly so) is a separate Java interpreter running in a separate Linux process. So when you blow one away (or when Android does so to make room for the next), all resources are returned to the system. Unless there's a system-level bug, such as a memory leak or some physical memory fragmentation that builds over time, there should never be a need to reboot Android.

In fact, the only time I've found that need has been when apps lock up. I found a few MP4 files that managed to lock up the system. Reminds me a bit of OS/2... you could lock up Presentation Manager, but never OS/2 itself. Unfortunately, that amounted to the same thing, until someone came up with a hack that let you get a shell via a hot key, which then let you kill off the offending thing without a reboot. Maybe we'll have such a thing for Android at some point, but it's a very minor issue right now.

The biggest problems with computers (and the Droid is, IMO, effectively a computer) are dodgy software programs. If you're only installing programs from trustworthy sources there's no reason to expect instability or a "need" to reboot every so often.

Absolutely correct. A properly written OS can blow away errant programs, recover all resources, and be no less for the effort. Android has the additional advantage that application errors occur in Java space, not generally at the ARM/Linux level. So they should generally be easier to catch. It's rare but still possible for an application to clobber Windows entirely. It should be impossible for an application to really kill Android at the Linux level (well, other than one running native code, which I understand is a possible thing, but rarely used).
 
@Dream... background processes in the linux OS use almost no cpu or memory usually. As I am writing android apps on Ubuntu Linux, I am looking at the list of tasks running in the background, there are quite a few, and all barely use any memory or cpu. They will be task switched just like any app you run.

@Getaphixx -

1. Apps could possibly use battery life... (Why would I want to let that happen?)

Keep in mind Android phones can run mulitple apps at once. Because of this it is paramount that app developers use all possibilities to properly shut down their apps. One thing you have to remember, unlike any other phone you have used including iPhone, clicking on back, home, etc is NOT going to shut down the app. If you need to go back to the home screen, that app is still running most likely. There are ways a developer can "listen" for when a user does this and shut down their app to mimic how iPhone does it, for example. I am guessing most app developers don't do that tho. I've seen many apps with EXIT/QUIT options, and many without. This is sadly one of the few things I fear non-techie users are not going to understand or realize, especially coming over from iPhone. The home/back button doesn't exit an app if the developer doesn't program it that way. As you are seeing, many apps remain running. HOWEVER, what you should know is.. most apps are sort of suspended when this happens. While you can run multiple apps in the background, only services run continually in the background. All apps, while you can run several, only the FOREGROUND app is actually consuming resources, including cpu cycles and memory. What happens when you switch apps that are not services (services you can't see anyway as they do not have an user interface), they have several signals (hooks, intents, etc) sent to them to allow a developer to save the state of the application, release any resources not needed like DB connections, network, etc, so that while it is suspended, those resources are given back to Android for another app that becomes the foreground app, to use. However, this is both the greatest and worse feature of such an open system as Android. Because Java is the largest language choice right now and Android 2.0 is out, and more phones are coming, and tablets, etc.. you are going to see a plethora of java developers jump on this bandwagon. You are going to see a huge amount of apps hit the store. And you are going to find a LOT of those apps are inexperienced developers trying to mimic the iFart sensation to make millions and retire in 6 months, yet will completely ignore many of the requirements to be a good citizen in the android app world. So, many apps are NOT going to properly release resources, they wont save state, etc. So you will find more and more apps that are going to eat up memory and thus when you kill it using ATK, you'll see resources released and more memory for you to use.

Here is the thing to know tho.. Android is in control. Period. Android WILL KILL AN APPLICATION FOR YOU! :) In other words, if you start running out of memory, Android will send some signals to the app saying "Yo.. I really really need to use some of those resources you got tied up.. so I am shutting you down, completely. Here's your last chance to save any state..." and boom! Gone. Android thus will indeed handle memory as needed on the fly for you. Now.. what happens when you switch back to that app you left running but Android shut down? Well, it starts up again. If the app was built correctly, it will receive a bundle of info pertaining to state info that it should have saved when Android killed it. If done right, it will resume as if nothing happened. You will see a slightly longer delay than if it was still running, as it is now starting up a JVM again to run the app in, and the app may have to reload some state, screens, tiles, graphics, sounds, etc.


3. I don't use my phone for 45min.. And previously used App Killer to disable multiple items.. I come back.. I have things like Alarm Clock and others that have NO business being opened much less running... I kill them.. Jump from 65 to 104mb of memory..

This one does iritate me too.. I am not sure what controls alarm clock coming back to life. I suspect it is a SERVICE app with an interface tho. Service apps can run in the background.. so most likely the Alarm Clock app installed a service as well..that DOES run even when you shut down the alarm clock app. Every so often that service executes in the background and realizes alarm clock isn't running but it needs to, as the alarm clock app is the one that will make use of your ring tones that you selected in the alarm clock app to wake you up with, etc. That is my guess. I am not completely sure tho how this is done yet. I have only begun developing and got a lot to learn yet.


4. Please tell me how killing UNEEDED items is a waste...lol

It is indeed a waste. I am telling you now as a developer, albeit a new one, but one who has been doing java for over a decade and understands the basics of how all this works. Android WILL shut down apps (as I explained above in detail) when it needs to in order to reclaim resources so that the top app (foreground) might have resources to do something with. Even if the foreground app doesn't need them, Android will kill apps if need be as necessary. As I said above, even tho it actually shuts the app down, it goes thru steps to allow an app to cleanly shut down AND recover from the shutdown as if it was never shut down. The app developer just has to write the code correctly to handle this situation.

So, essentially, killing apps becuase you are afraid you are running out of memory is not needed. There is ONE possibility tho.. an app could run out of memory itself! It could load a very large dataset into memory and not have enough. I haven't found/read anything about how Android itself handles swapping memory to disk.. as I don't think you can set up swap memory to the SD card. It would be VERY nice if you could do this, it would allow more robust apps to at least use more memory than 128MB or 256MB the phone comes with. It would also see minor bumps in performance when it was time to swap some memory to the SD card to free up memory, or bring it back in. Windows, Linux, OSX, they all do this for you. I suspect the underlying linux OS handles this, but not quite sure if it does so or not.

Hope this wasn't too technical and helps some of you understand the killing app stuff in more detail.
I feel very well informed after reading your post. I guess the developers of KillerApp just want their name out there. Fortunately, some of these apps are free and can easily be uninstalled. Thanks andjarnic.
 
what about if im playing a game and, like most android apps, doesnt have an option to quit altogether. wouldnt that game keep looping through on pause, killing my battery, until i resume with it?

just a quick q.
 
There is some use for app killers

Some very informative information. Thank you very much for taking the time to post the details.

I do find that there is a place for application "killers". Even though apps should be "well written" most are not. Memory leaks are all to common and an application "killer" or task manager is often times to best way to remedy the problem. Also, not everyone uses all the apps that are auto started in the background. For example I do not use Google Talk at all, however the Google Talk Storage service is always starting in the background.

Also, there are times where you might want all your memory available, say perhaps for a game or memory intensive app like a mapping program. In these cases a task killer can be very useful to clear out apps that do not need to be running.

I also agree with the "OCD" and memory management. It's a fine line between performance and mania. I wish I could leave it up to Android to handle. Maybe I have been damaged from all my days with Windows Mobile and Microsoft's insistence that the OS would handle closing apps when needed.
 
I just find it odd that most of these apps don't have a shutdown or exit option in their menus. I feel that any apps that needs a large amount of data or drains battery levels fast should have a shutdown or exit option.
 
what about if im playing a game and, like most android apps, doesnt have an option to quit altogether. wouldnt that game keep looping through on pause, killing my battery, until i resume with it?

just a quick q.

I second this question. Anyone?

I also use a task killer program and keep the widget on my phone to disable bluetooth, GPS and WiFi when not needed.

I don't care how good an operating system is. It's absolutely silly that an application does not mandate a "close" function. After I'm done playing Doom, I close it down - period.
 
Related Question

Someone said that anything using your battery life more than "Display" and "Cell standby", then you have a problem/bad app running.

Well I am looking right now, and Display is at 63%, and then next is 'Android System' with 29%, and then 'Android OS' with 4%, and then 'Cell standby' with a whopping 3%....

I don't have many third party apps (just pandora, shopsavvy, and some of the more popular ones). I recently uninstalled advanced task killer. Current running services are 'android keyboard', 'EasService', 'MailService' and 'Sync Manager'.

Does anyone see anything odd with this? Or is this normal?

Any insight would be helpful! Thanks.
 
Display 58%
Android 26%
google 2%
cell standby 2%
android core apps 2%
OS 2%

This is with 11 apps running in the background. I'm operating on the principle of never closing apps/ or rebooting. I had like 20something apps open and running in the background with like a week uptime, until my wife thought she was doing me a favor and rebooted the phone. She got her own droid now so no more playing with mine for her and no more near domestic incidents.
 
Last edited:
Display 58%
Android 26%
google 2%
cell standby 2%
android core apps 2%
OS 2%

This is with 11 apps running in the background. I'm operating on the principle of never closing apps/ or rebooting. I had like 20something apps open and running in the background with like a week uptime, until my wife thought she was doing me a favor and rebooted the phone. She got her own droid now so no more playing with mine for her and no more near domestic incidents.
I heard having a low 'up' time is good. Why would you say re-booting the phone is bad?
 
I keep catching myself using the task killer I downloaded. Guess I'm still stuck in BB mode. It's good to know that I don't always have to worry about freeing up resources and memory.
 
I can't tell if you're being a wiseass or sincere about the uptime comment. But phone has been out 12 days, and I didn't decide to break away from the windows phone norm (constant task killing as well as reboots) right away so 7 days isn't bad.

I'm not saying rebooting is bad. Just that I am going to see how long I can go without doing it, while running numerous apps in the background.
 
Hello ladies and gentlemen : )

I ran a little test with ATK and it fubared my phone up.


Here's the thread. Basically it locked my phone up after a long call and a battery pull was the only way to recover it. A word to the wise, let Android manage itself....

I can't say unequivocally that ATK caused the problem but I'm leaning towards it.

Maybe there is a compatibility issue with it on 2.0. I don't know. At any rate no more experimenting and lab test's for me for a while : )

http://www.droidforums.net/forum/droid-general-discussions/1325-screen-freezes-after-time-out.html
 
Last edited:
BB OCD followed me to DROID... gotta break myself of this Task Killer usage. I don't manually kill anything... I have it set to kill tasks every hour. Gonna delete it and see how she goes. Lot of sense made here regarding not needing the task killer.
 
Status
Not open for further replies.
Back
Top