croy2007
Resident Punisher
Okay, I figured out how to change swap. I used Root Explorer.
** Step 5 explained:
- Download zip from here .
- Open Root Explorer and go to the folder that contains the zip you just downloaded.
- Long press the zip and select Extract All.
- Now go into to mnt/sdcard/SpeedSoftware/Extracted/512mbSwap/system/etc/init.d.
- Edit S03swap file to the swap size and swappiness you want. Make sure your changes are saved.**
- Delete the backup .bak file
- Go back to mnt/sdcard/SpeedSoftware/Extracted long press 512mbSwap folder. Select Zip this Folder.
- Now go into recovery and flash the zip. it is located in SpeedSoftware/Zip
** Step 5 explained:
Ypu should see the followng when you open it in text editor.
#!/system/bin/sh
# Modified by downthemachine and MrBobo
# for the zte warp
# original credits where not listed
# 02swap - creates /data/swap (if necessary) and enables swap
# Also adjusts minfree accordingly. Swap file is 512MB
#
if [ ! -f /data/swap ]; then
busybox dd if=/dev/zero of=/data/swap bs=1k count=512000
busybox mkswap /data/swap
fi
# This turns the swap on
swapon /data/swap
# This tells the system to set swappiness
sysctl -w vm.swappiness=80
# And this adjusts lmk for better performance
echo "500,1000,20000,20000,20000,25000" > /sys/module/lowmemorykiller/parameters/minfree
I put the things we are focusing on in bold and underlined. The first two numbers, 512MB & 512000. Represent the swap size, say I want the swap to be 256MB. I would change the numbers to, 256MB & 256000. The next number, 80, is the swappiness value. Default is normally 60. Swappiness is how often the system goes to use the swap file. the lower the swappiness value the less the system uses the swap file. Swapiness can be set between 1 to 100.# Modified by downthemachine and MrBobo
# for the zte warp
# original credits where not listed
# 02swap - creates /data/swap (if necessary) and enables swap
# Also adjusts minfree accordingly. Swap file is 512MB
#
if [ ! -f /data/swap ]; then
busybox dd if=/dev/zero of=/data/swap bs=1k count=512000
busybox mkswap /data/swap
fi
# This turns the swap on
swapon /data/swap
# This tells the system to set swappiness
sysctl -w vm.swappiness=80
# And this adjusts lmk for better performance
echo "500,1000,20000,20000,20000,25000" > /sys/module/lowmemorykiller/parameters/minfree