[LG Optimus 2x] vadonka:
Hello guys!

This script is originally come from the Juwe11 ramscript but its far more advanced now, so i decided that make an own thread for this.

This script is an init.d script for our O2X but working with many other phones too. Working with every ROM what is supported init scripts. However optimized and working best with the ironkernel because some option is based on this kernel ramhack. Its working any other kernels too but may be need to adjusted some parameters.

The script started the configuration options:

1)

SMODE

if this set to on the script will be change many parameters in the proc filesystem, otherwise not :) however some part of the script is unaffected of this!

2)

LMKMODE and LMKVAL

lowmemorykiller and basic memory management tweak

if the LMKMODE value is on the basic_mem_tweak procedure will called.

if the LMKMODE is on then the LMKVAL define the lowmemorykiller mode.

you can change this static values:

def: stock values 2048,3072,4096,6144,7168,8192 (CM7)

std: standard values 1536,3072,4096,7680,8960,10240 (recommended for low memory models <256MB)

opt: optimum values 1536,2048,4096,10240,12800,15360 (recommended for the most)

str: strict values 1536,2048,4096,15360,17920,20480 (best for heavy multitasking)

aggr: aggressive values 1536,3072,4096,21000,23000,25000 (our O2X will handle this without problem)

extr: extreme values 1536,3072,4096,38400,40960,43520 (recommended for heavy HD games)

ult: ultimate values 1536,3072,4096,51200,57600,64000 (use with caution! only for high-end devices!)

or you can use the 'auto' values.

lowmemorykiller auto management is depend on the total memory size. if you are using stock rom then this value set to aggressive by automatic because the freeing the memory is important.

if you are familiar with ironkernel and using some of the ramhack version then this value is more softer then the total memory is increasing (more memory dont need so strong garbage collection)

lowmemorykiller parameters intact when the SMODE is off

3)

NETTWEAKS

its affected the tcp/ip procs and some kernel parameters. helping that the phone network will working faster and better

network parameters intact when the SMODE is off

4)

VMTWEAKS, COMPCACHE, CS_SIZE, CS_RATIO, INTERVAL

this part is the memory management

vmtweaks will disable normalized sleeper and change many values in the /proc/sys/vm.

vm parameters intact when SMODE is off

COMPCACHE will enable the compcache (i know CM7 supported this but its not working some case if you are using the cm settings menu)

CS_SIZE determine the compcache memory size. im using only the zram device for the compressed memory, this dont making any swap file on the block devices.

if CS_SIZE is set to auto then you can define the CS_RATIO. this parameter define the amount of the total memory what can be used as compcache. so in this case the compcache size is changed dynamically. its make sense when you are using the ramhack ironkernel

INTERVAL define that the period of the force cache drop. if you are using compcache it can be helped avoid that the phone become laggy after a while.

5)

MTWEAKS and SCHEDULER

MTWEAKS procedure will remount every partition with noatime,nodiratime,commit=180,noauto_da_alloc

and adjust many parameter what is related to the block devices

SCHEDULER will define the default io scheduler (its bfq by default, like in many kernels)

this script is working alone, dont need any other tweak script. every modifycation logged to /cache/tweaklog.txt in human readable format :)

this script will not gain extra point in any benchmark (maybe a little) if you want this you need to overlock your phone. remember that.

you can install with the cwm installer or simply copy the 90tweak file for the /system/etc/init.d/ and change the perms to 777

the required files in the attachment or in my sig