Apps closing automatically - HD2 General

I would like to run certain apps, like e.g. skype in the background all the time.
However the HD2 closes all apps in the background after a certain time.
I also tried duttys taskmanager, but still all apps in the background are being closed after some time automatically.
Is there any way to keep all apps in the background running, until you close them manually?
Thanks!

Apps aren't closed after a certain time, they are closed by Windows OOM - Out of Memory Handler, when your system is low on memory, or when you reach the system's limit of 32 running processes. AFAIK, you cannot configure OOM, so what you can do is close other applications. Otherwise it should have been taken care of by the application developers - OOM only closes apps with windows, so they need to write the program in a way that there's a windowless background process.

Thanks for the explanation...
But I checked and I have "only" 28 processes running.
When just opening the calculator and have it running in the background, it is closed automatically after some minutes.
So the limit of too many processes cannot be reached by that.
And also there is plenty of free memory...

I've never had any applications closed automatically...

I have the same problem.
I want to run flexmail always in the background, but it closes automatically. Probably because of memory problems. Is there a way that it gests automatically re-opened by the system by some kind of tweaking?

How much program memory do you have left?
On my device, apps get closed automatically, when about 53% of program memory is used. That is much too early I think.
On my Touch HD I had always about 65% in use.
Is there any way to set in the registry, at which threshold of memoty-usage programs get closed?

Ok, I think I got it now...
It is not caused by a 3rd party software.
The ROM has a limit of 27 processes that can run at the same time.
If you have e.g. 25 processes running and then open 2 apps running in the background, then when opening the third app closes one of the other apps in background, so that the limit of 27 processes is applied.
It is not a memory issue! Just an issue of the limit of 27 processes running at the same time!
Since I have quite some services running in the background, like battery indicator, button mapping, etc. this can be quickly an issue!
So the big question is now:
Can we rise this limit of 27 processes running simultaniously somehow, maybe with a registry tweak or anything?

Related

WM5 automatically close some programs to clear memory?

Is there anyway to prevent this? I am using a program that will close automatically after using a couple programs...
http://benhirashima.com/software/
Due to the way Windows Mobile manages memory, you may find that if you have been using a lot of different programs on your phone, or doing something that requires a lot of memory, that Windows Mobile will automatically shut down TxtMan without warning. It does this to free up memory for whatever you're currently doing. Unfortunately, TxtMan won't receive SMS messages after it's been shut down. If you've been doing a lot of work on your phone, you should check to see if TxtMan is still running.
Click to expand...
Click to collapse
does anyone have any info on this and maybe a registry setting to prevent it?
WM just frees memory. You can do nothing with this, except soldering extra RAM chips
there is also 32 program limit. if you have too many programs open, the last used will be closed anyway, having more memory will not help. trust me on that one, I have 128 Mb RAM and WM5.
The programs can ignore WM_CLOSE, which enlongates livetime. But if memory becomes too cluttered, Windows will kill the program anyway.
The idea was to do something like Palm, where a program exits to a saved state when it's left (there is no multitasking) and continues there when restarted. The "smart minimize" feature (programs aren't closed but minimized until memory runs low) would have been a speedup, and allowed programs to do some background stuff while there's enough memory and CPU time. With small organizer apps like Contacts, Appointments, PocketWord, etc., this would have worked quite OK...
However, since PPCs became more and more "small PCs" instead of "better organizers", programs grew in CPU and memory usage, required to stay alive (e.g. multimedia players, navigation, ...), and task managers like WisBar became a "must have". And the automatic close mechanism became an unwanted legacy...

Programs closing on their own

I am using aserg windows mobile 6.1 rom and I have noticed a creeping problem. As time goes on, I can only seem to run 1 substantial program at a time.
For instance, if I try to run any of these programs in tandem:
HTC audio manager or Windows Media Player
Mundu mobile messenger
Opera
Internet explorer
Dictionary software
Outlook mail (sms/email)
Skype
the program in the background always closes. This is especially annoying when for instance I am listening to music and I get an email or sms, I go to check it and my music player just closes. Same if I try to browse the web and listen to music or check an sms, It is very annoying.
What causes this function in windows mobile and how do I turn it off?
As for memory, when I start I have 13-14 megs free memory. Any of these programs take an absolute MAXIMUM of 4-5 megs at peak usage. I should be able to run at least 2 together without a problem, and if another one does nto have enough memory, it shoudl just say so and not start, but not close out other programs...
I also have about 4-5 megs of free storage space on the phone.
any ideas on this one?
It seems as time goes on, I can't seem to run any more than 1 program simultaneously...
Reduce the amount of file space your browser have allotted for cache files and history.
My browser cache for both Opera and PIE are both pointed at the storage card which has about 500megs free. This problem occurs even if I am running any programs though, not just browsers...
It's either the memory shortage (which some of those programs can actually take much more than 4 or 5 mb to run.) Or you have it set to close on tap, within the task manager/x-button, instead of close on hold.
I use batterystatus, and it is set to tap and hold X to close, but I never use the X, I simply go to the start menu and open another program, then when I try to switch back to the other program, it is closed already.
How do I check if it is a memory problem?
For instance, if I run HTC audio manager, then get a message, I click reply, then after about 3 seconds into my reply HTC audio manager closes.
is there any way I can "force" the programs to stay open? Even if I were to launch a new program and it does not have enough memory, it woudl just not open rather than closing an existing open program...
To me, it sounds like you are running out of RAM, and programs that were running in the background are automatically closed. I'm not affiliated with Windows Mobile and hence not an expert, but I believe this (closing previously open programs rather than the new one) is the expected behavior in WM. Imagine getting a phone call and the phone app not opening since there's not enough memory because the OS didn't automatically close background programs...
I don't know of a way of changing the memory management behavior, but maybe someone else here does? I'd argue that you wouldn't want to anyway.
I'd suggest that you DO use the X button to close programs, otherwise I guarantee you will run out of memory and things will close automatically anyway. The difference is you won't have any say in what gets closed at that point. I added programs that I don't want to close with the X button (like Live Messenger) to the exclusive programs list in the Task Manager.
Second, I'd suggest you take any steps you can to increase your original pool of memory.
Darren, I understand your point, but it seems as if I have plenty of memory, and I can only run 1 program at a time. I don't mind so much the behaviour, it is just at the point of being ridiculous when I can only run 1 program at a time.
So you think that starting with 13-14 megs of free memory is not enough? How would I go about increasing this original pool of memory?
Also, even it I use the X button to close programs, that does not solve my problem anyways, whichever program is not in the foreground seems to close by itself anyway...
phony, I understand your frustration. I have had low memory problems myself, and I know that programs running in the background will close when that happens. That's why when I read your post it sounded like a memory issue to me.
I ended up tweaking a few things to try to get more free memory, like not running certain processes or services automatically at startup. I'm not sure if it is relevant to the ROM you are running, but see http://forum.xda-developers.com/showthread.php?t=312312.
This is definitely a memory problem. When the free program memory is lower than about 1MB (don't remember the exact number), the WIndows Mobile will send a WM_HIBERNATE to all the running program to release all the possible resources. If the memory goes lower, it will broadcast another message called WM_CLOSE to close all the background apps to release more memory. The only reason for apps that close on themselve is either low on mem or there are some apps in the background (maybe a virus) sending WM_CLOSE every now and then. To be honest, to have less than 15 megs of ram to start with is NEVER enough. Try to change the pool size if you don't like any of the great roms here. Hope this help.

Memory Leaking Solution?

Well, I seem to have a constant memory leaking problem. I've tried different roms over the past few years. Some of the most recent DCD 3.2.4, 3.2.6, 4.1.2, and now RM v2.2 light. They all seem to have the same problem. The memory is fine when I do a soft reset, then I start using the phone for whatever, Internet, Text Messaging, etc. The memory starts to get less and less and less over a very short period of time until I hardly have any left. So, I have to keep soft resetting the phone like every hour or more. Is there a solution to this? I have to assume it's a hardware issue since all the ROMs seem to cause the same problem. I have a friend that has the same phone and he uses his phone with MR1 and he says he has no problems at all, but he uses his phone as a basic phone and doesn't use it like a computer, like I do. He doesn't text message or use many applications at all. So, I don't know if he would have the same problem if he ran all the apps I do and text messaged, etc. Thank you for your help and time...
It's not a hardware issue. Due to the nature of our OS, there will more than likely always be a slow memory leak...but it shouldn't be bad.
Do you have a task manager like HTC Task Manager that allows you to completely close apps when you press (or hold) the X? You may have lots of apps running throughout the day that don't actually exit.
You can also try running a program like Oxios Hibernate occasionally to free up some memory.
You may also have programs such a Voice Command that run in the background and use memory; try looking and seeing what is running in the background.
Try downloading something like DotFred's Task Manager, and look at the what programs are running and how much memory they utilize shortly after a reset. Then look again a few hours later to see what changes.
Yes, I do and I'm exiting the apps. It doesn't seem to be bad with this new RS ROM. All the DCD ROMs that I used had a major problem when I used them. I was using memRelease, that seemed to be the best out of the ones I tried, but it would still not release a lot and it would slowly go down lower and lower. I've just started using Oxios Hibernate 1.40 since it came with the new ROM. I don't have voice command that I know of. I see what's running in the background, there is some utility came with the ROM, but I'm not sure what the files are that are running and if it's OK to stop them. I will have to try what you say, but I'll have to try to find that utility again, or get that one you suggested. Thanks!
btonetbone said:
It's not a hardware issue. Due to the nature of our OS, there will more than likely always be a slow memory leak...but it shouldn't be bad.
Do you have a task manager like HTC Task Manager that allows you to completely close apps when you press (or hold) the X? You may have lots of apps running throughout the day that don't actually exit.
You can also try running a program like Oxios Hibernate occasionally to free up some memory.
You may also have programs such a Voice Command that run in the background and use memory; try looking and seeing what is running in the background.
Try downloading something like DotFred's Task Manager, and look at the what programs are running and how much memory they utilize shortly after a reset. Then look again a few hours later to see what changes.
Click to expand...
Click to collapse
OK, I can't find the application I was talking about, I'm thinking it was in the Heavy version of the ROM and not the Light and that's why I can't find it now.
I did what you suggested and I installed DotFred's Task Manager. I can see the processes that are starting when I do a soft reset. Can you tell me if there is a place that lists what all the processes are and what I need and don't need? This way I can figure out what processes and don't need and stop them. Is there a way to stop some processes from starting automatically when you turn on the phone, and that will only start when I start them manually?
When I do the soft reset my free memory is about 17.76 MB but my processes are only using 15851 KB but my free memory is 18.52 MB after I use Oxios. So, that doesn't work well to free up memory. After you minus the memory the proceses are using from the total memory it should have 37.44 MB free. So, I don't know what's using up the rest of the memory.
I'm also using Kernal to use the High Memory Kernal so the camera doesn't work and it frees up alot more memory. So, if I used Low Memory Kernal my memory would really suck. So, there must be something wrong here.
Is there a way to keep ActiveSync from starting all the time? Here is the list. Thank you!
shell32.exe - 4440 kb
gwes.exe - 3350 kb
device.exe - 2677 kb
services.exe - 2383 kb
filesys.exe - 1812 kb
cprog.exe - 892 kb
connmgr.exe - 104 kb
repllog.exe - 101 kb
TaskMgr.exe - 80 kb
psShutXP.exe - 5 kb
FTouchFlo.exe - 5 kb
poutlook.exe - 1 kb
NK.exe - 1 kb
btonetbone said:
It's not a hardware issue. Due to the nature of our OS, there will more than likely always be a slow memory leak...but it shouldn't be bad.
Do you have a task manager like HTC Task Manager that allows you to completely close apps when you press (or hold) the X? You may have lots of apps running throughout the day that don't actually exit.
You can also try running a program like Oxios Hibernate occasionally to free up some memory.
You may also have programs such a Voice Command that run in the background and use memory; try looking and seeing what is running in the background.
Try downloading something like DotFred's Task Manager, and look at the what programs are running and how much memory they utilize shortly after a reset. Then look again a few hours later to see what changes.
Click to expand...
Click to collapse
It must be something you're installing because I've used most of the ROMs you mentioned along with having tons of extra stuff installed and running in the background and with heavy use the memory leaks really only became a problem after a day or two... not every hour.
Well, the RM ROMs seem to be working better then the DCD ROMs. I have to keep clearning the memory, but I don't have to keep restarting my phone like I did with the DCD ROMs. I still don't understand what's up with the memory. I had like 50% clear memory after the fresh install of the new ROM, and I checked the processes. I then restore my backup and install my software and then the memory goes down to like 30% free. I check the processes and there is no new processes. So, if there is no new processes taking up the memory then what is, and how can I find out? Yes, there must be something wrong, but I don't know how to figure out what it is. Thanks!
unL33T said:
It must be something you're installing because I've used most of the ROMs you mentioned along with having tons of extra stuff installed and running in the background and with heavy use the memory leaks really only became a problem after a day or two... not every hour.
Click to expand...
Click to collapse

X10 Memory Leak?

I have noticed behaviour pointing to a memory leak on the X10 - After turning the phone on, I get less and less free memory after running ATK - over 110 MB right after turning the phone on to ~70 MB after 24+ hours.
The phone is heavily modified/customized, so it may not be an SE sw bug (ADW, Smart Keyboard, handcent, k9, etc...)
What's the best process tool you can recommend to look into this?
Let the phone handle the memory. dont worry.
+1 on that. Android its linux based and us meant to work like that. Empty memory is wasted memory.
-------------------------------------
Sent from my X10i
Android may be Linux based, but if *after killing all idle processes* memory is systematically dwindling, that means/may mean that one or more of these processes is allocating memory which it is then NOT being released - either by the process (more probable) or the system itself (less probable).
In other words, for the same set of running processes/applications , the memory usage should *not* systematically go up over time.
Linux itself has no automatic GC. Android does (Dalvik VM), but it takes some care from developers for that to work properly - no "loose" pointers to unused but still-referenced data, etc....
acmbc said:
Android may be Linux based, but if *after killing all idle processes* memory is systematically dwindling, that means/may mean that one or more of these processes is allocating memory which it is then NOT being released - either by the process (more probable) or the system itself (less probable).
In other words, for the same set of running processes/applications , the memory usage should *not* systematically go up over time.
Click to expand...
Click to collapse
I disagree, as processes are used/exercised the kernel will allocate the memory they need, after switching on the phone the processes are idle and occupy a small amount of memory. As they are used the process size will grow in main memory as they store or cache common data used by the process. That is why applications such as facebook may be slower at start off as the data needs to be supplied, once this data is cached it will run much faster as the data is already in main memory.
Linux/Android works on the principle that it's a waste not to use as much memory as possible.
Not to get into a GC flame war here: The principle you mention is right, its just that after one KILLS these processes (facebook for example) ALL OF the memory allocated by facebook should be relinquished to the system (ergo, appear as free).
I.e. if I start up my phone, and just have processes A B and C running and have lets say 120 MB free, and after using the phone for a while kill everything and *restart* ONLY processes A B and C, then I should have 120 MB free. At least tendentially (may have a different set of resident libs at the 1st and 2nd points in time, some other minor stuff may be different, etc..). However, I find that doing this over and over results in less and less free memory being available as time passes.
I am not saying I am *right* but a good process inspection tool would help to ascertain what is going on.
acmbc said:
Not to get into a GC flame war here: The principle you mention is right, its just that after one KILLS these processes (facebook for example) ALL OF the memory allocated by facebook should be relinquished to the system (ergo, appear as free).
I.e. if I start up my phone, and just have processes A B and C running and have lets say 120 MB free, and after using the phone for a while kill everything and *restart* ONLY processes A B and C, then I should have 120 MB free. At least tendentially (may have a different set of resident libs at the 1st and 2nd points in time, some other minor stuff may be different, etc..). However, I find that doing this over and over results in less and less free memory being available as time passes.
I am not saying I am *right* but a good process inspection tool would help to ascertain what is going on.
Click to expand...
Click to collapse
Wrong.. it should NOT be returned to the system.. but it should be marked as "disposable" IF another process wants to use it. That is the way linux usually do.. That is why the "Free"-value is misleading. As the "Free"-value is not the sum of "Free" and "Cached" values. when you "unload" a lib it is not completely removed from memory, it is just marked as "cached" instead. Saving tremendous ( ) amount of battery and time when, if, the user wants to use it again before overwritten by another memory-hungry application..
Regards // OwL
does all this mean we don't really need advanced task killer?
or does the advanced task killer kill the cpu process? ( as a result longer battery life)
robbyf66 said:
does all this mean we don't really need advanced task killer?
or does the advanced task killer kill the cpu process? ( as a result longer battery life)
Click to expand...
Click to collapse
advanced task killer kills the application itself, so that nothing more is executed by that application thread(s). wether dependent libraries are kept loaded or not does not affect battery time when not used. Advanced task killer does not actually unload any libraries it only kills the process.
I personally hardly never use advanced task killer, as it is not needed as long as you make sure to run applications that does not keep the phone from going into sleepmode. Those programs are just simply bad coded.. I instead have a CPU-meter application in the task-bar and if I see that the CPU-time is extensivly used after the application has been put to background, then I might use a taskkiller to stop the bad application. But that scenario is rare... I usually get 50h+ of battery time per charge, whatever I do with it.
Regards // OwL

NB Question

I got the tablet today, I can't find where to close programs, I have 10 programs open, where can I close the programs and not have them all open
There is no need to close apps, Android does this for you (if needed), so don't worry about this.
bklynfire said:
I got the tablet today, I can't find where to close programs, I have 10 programs open, where can I close the programs and not have them all open
Click to expand...
Click to collapse
theres a widget for active programmes, add this to your home screen. Android doesnt close all apps automatically.
Long press the home button to open the task manager. Android will close the apps automatically when it needs the space in ram. Leaving them running shouldn't affect battery life.
Sent from my HTC Vision
You will make things worse by force closing apps, there is no point in doing so. Apps that you don't use are leaved in memory for faster loading next time you open them. They are not actually running, they don't use CPU, so they don't use battery. They are automatically removed from memory when needed.
Only if the app is not written correctly, it can cause problems.

Categories

Resources