[Optimus One, P500 Android Development] ungaze:
Need help debugging

Hi guys. Found some new tweaks that we might implement on our phones. But with so little time, I can't get to test them all(was going to send them to fransisco) and thought that some of you(those who's experienced with changing /editing system files) might help out with testing.

Here's the entire script:

[COLOR="Red"]#!/system/xbin/sh

#mounts /system to r/w
mount -t yaffs2 -o remount,rw /dev/block/mtdblock1 /system[/COLOR]

[B]#remount all partitions with noatime
for k in $(busybox mount | cut -d " " -f3)
do
sync
busybox mount -o remount,noatime,nodiratime $k
done[/B]

#SD read/write speed patch
echo [B]256[/B] > /sys/devices/virtual/bdi/179:0/read_ahead_kb

#IO scheduler tweak
for i in `ls -l /sys/block/mtdblock* | tr -s " "| cut -d " " -f 6`
do
echo "noop" > /sys/block/$i/queue/scheduler
done
echo "noop" > /sys/block/mmcblk0/queue/scheduler

echo "noop" > /sys/block/dm-0/queue/scheduler
DM=`ls -d /sys/block/dm*`;
MTD=`ls -d /sys/block/mtd*`;
LOOP=`ls -d /sys/block/loop*`;
RAM=`ls -d /sys/block/ram*`;
for j in $DM $MTD $LOOP $RAM;
do
echo 0 > $j/queue/rotational;
done

#VM management tweak
echo 0 > /proc/sys/vm/swappiness
echo 1000 > /proc/sys/vm/vfs_cache_pressure
echo 4096 > /proc/sys/vm/min_free_kbytes
[B]echo 1 > /proc/sys/vm/oom_kill_allocating_task #0
echo 0 > /proc/sys/vm/page-cluster #3
echo 5 > /proc/sys/vm/laptop_mode #0
echo 0 > /proc/sys/vm/dirty_expire_centisecs #200
echo 0 > /proc/sys/vm/dirty_writeback_centisecs #500
echo 60 > /proc/sys/vm/dirty_background_ratio #5[/B]
echo 95 > /proc/sys/vm/dirty_ratio #10

[B]#Build.prop changes
setprop wifi.supplicant_scan_interval 200
setprop windowsmgr.max_events_per_sec 60
setprop dalvik.vm.startheapsize 8m
setprop net.tcp.buffersize.default 4096,87380,256960,4096,16384,256960
setprop net.tcp.buffersize.wifi 4096,87380,256960,4096,16384,256960
setprop net.tcp.buffersize.umts 4096,87380,256960,4096,16384,256960
setprop ro.ril.hsxpa 2
setprop ro.ril.gprsclass 12
setprop ro.ril.hep 1
setprop ro.ril.enable.dtm 1
setprop ro.ril.hsdpa.category 8
setprop ro.ril.enable.a53 1
setprop ro.ril.enable.3g.prefix 1
setprop ro.ril.htcmaskw1.bitmask 4294967295
setprop ro.ril.htcmaskw1 14449
setprop ro.ril.hsupa.category 5
setprop ro.ril.disable.power.collapse 0
setprop pm.sleep_mode 1
echo 256960 > /proc/sys/net/core/rmem_default #110592
echo 256960 > /proc/sys/net/core/rmem_max #110592
echo 256960 > /proc/sys/net/core/wmem_default #110592
echo 256960 > /proc/sys/net/core/wmem_max #110592
echo 4096 16384 256960 > /proc/sys/net/ipv4/tcp_wmem
echo 4096 87380 256960 > /proc/sys/net/ipv4/tcp_rmem
echo 30 > /proc/sys/net/ipv4/tcp_fin_timeout #60
echo 30 > /proc/sys/net/ipv4/tcp_keepalive_intvl #75
echo 0 > /proc/sys/net/ipv4/tcp_timestamps #1
echo 0 > /proc/sys/net/ipv4/tcp_sack
echo 5 > /proc/sys/net/ipv4/tcp_keepalive_probes[/B]

[COLOR="Red"]#mounts /system to r/o
mount -t yaffs2 -o remount,ro /dev/block/mtdblock1 /system[/COLOR]

Each tweak is separated or marked with a hash(#) sign followed by the description of the tweak.

New/changed values are in BOLD

You can remove each tweak to find which ones are helpful and which ones are not.(build.prop lines can be removed separately)

I'm not sure if the tweaks are applied real-time using gscript. so:

Here's a flashable zip(signed - thanks ciolnadu) containing the exact same script mentioned above(flashed to /system/etc/init.d/90tweakz < you can remove tweaks from here)

FOR TESTING PURPOSES ONLY!!!!!!

Use this Undo.zip if you have used the combine.zip from the previous pages

@Francisco

Sent you a message