[Motorola Droid and Milestone General] MrPadie:
UPDATE: Use Appkiller to do the same thing if you're not into the whole modding scene :P

Hi all.

So, I'm a new user to this part of XDA (Those HTC Hero forums have taken quite the dip lately) - received my milestone on Friday, and wow, what can I say - truly blown away from the performance I can get out of it, especially since it is getting along in it's days now too. However, I'm always hungry for as much power as possible :P.

Something that really shocked me though is that it doesn't seem to me that anyone has played around with the automatic internal memory killer of Android. Basically, it eliminates the need of having a task killer program running at all - allows you to have Android kill your unnecessary tasks for you. But, before I repeat an already-written informational post on this, here's the link to read up about it for yourself: How to configure Android's *internal* taskkiller.

Anyway, here's a quick guide on how to add this to your wonderful Milestone (PLEASE NOTE - THIS METHOD REQUIRES ROOT):

WARNING

- Playing around with system files is always dangerous. MAKE SURE YOU DO A NANDROID BACKUP JUST IN CASE. I take no responsibility for any damage what so ever (even though there cannot really be any with this :P).

This guide also requires you to know about ADB Commands - google is your best friend in this case. Right now, I'm too lazy to post a guide for that :P.

Well, now that the formalities are out of the way...

1) Firstly, you need to have the G.O.T Open Recovery. I'm pretty certain I don't have to go into anymore details with this step - it's posted all over the place ;)

2) (OPTIONAL FOR SAFETY. If you don't care much for safety, you may skip this step) Start your phone up as normal (if it's off) and then run the following commands from Terminal/Command Prompt on your computer, using ADB:

adb shell
su [B][U](Look out on your phone for the Root dialog)[/U][/B]
cat /sys/module/lowmemorykiller/parameters/minfree

This should return a few values that look like this:

1536,2048,4096,5120,5632,6144

TAKE NOTE OF THESE VALUES. Although it's pretty simple to remove this if it causes problems, keep these values handy somewhere. Never hurt anyone to have another back up plan :P

3) Mount your SD Card so that you may access it on your computer

4) Browse to OpenRecovery/GOT/bin/boot_script on your SD Card

5) Open the file "71_overclock.sh" with a text editor or something you can use to edit the shell script.

PLEASE NOTE:

THIS IS USING THE OVERCLOCKING SCRIPT FROM THE G.O.T OpenRecovery. I AM USING THIS AS IT IS USUALLY RUN AT BOOT, PROVIDING YOU HAVE OVERCLOCKED YOUR PHONE TO ANY OF THE VALUES IN THE G.O.T OVERCLOCK MENU. So, long story short, you need to have selected at least one of the overclocking settings in OpenRecovery for this to work.

6) At the bottom of the file, add the following lines of code:

echo "1536,2048,4096,5120,15360,23040" > /sys/module/lowmemorykiller/parameters/minfree

THIS IS FOR THE AGGRESSIVE MODE. You can read up yourself for your own desired values in the thread link I posted above, and replace them in the above line of code as desired.

7) Save the file and close. Turn off your phone. Boot into OpenRecovery (You should know how to do this by now).

8) Go back to the overclocking menu and reset your desired clock speed. If you haven't set one before, now's the time to select ;)

9) Restart your phone. To test if your new values have worked, boot your phone as normal, and once it's booted, connect it to your computer again, and load up Terminal/Command Prompt once again. Then, as we did in the beginning, run the following commands:

adb shell
su [B][U](Look out on your phone for the Root dialog)[/U][/B]
cat /sys/module/lowmemorykiller/parameters/minfree

This should return your newly set values. And voila! Your phone is ready to fly. Although I haven't tested speed differences on the Milestone as such, it really helped on my hero. So, post some feedback and let me know.

-----------------------------------------------------------------------------------------

IF YOU RUN INTO ANY PROBLEMS LIKE BOOTLOOPS/STUCK BOOTS:

Bootloops/stuck boots usually happen when the phone doesn't like the modification you've added to it :P I have no idea how this will react on other phones. It worked 100% for mine, but if you cannot run this mod, then you can remove it by doing the following:

1) Boot back into OpenRecovery.

2) Go to the G.O.T Modding menu, and then to the Restore Menu.

3) Select to restore the mot_boot_mode file.

4) Restart your phone - this time it should start, but you might notice a drop in speed. This is normal, as we have reset the overclocking to normal.

5) Mount your SD Card again, open the file "71_overclock.sh" again with a text editor or something you can use to edit the shell script.

6) Remove the line you added previously. Save and close. Unmount the SD Card.

7) Turn your phone off and boot back into OpenRecovery. Apply your overclocking again, and reboot your phone. It should boot up fine.

8) Breathe.

----------------------------------------------------------------------------------------

I'll be updating this guide in the near future to possibly include a way of doing this without having to use any overclocking, as well as a more noob friendly version, including ADB How-to's etc. For now, the extra boost in power isn't going to hurt anyone :P

Credits: androcheck for his original guide on this feature.

Happy speeding,

MrP.