FORUMS

Dr.Ketan Brings The S6 Theme Store To The Note 4

Dr.Ketan has submitted a video to the forums showing a functional port of the Galaxy S6 … more

Do You Have Insurance on Your Smartphone?

While affordable smartphones are becoming more available, the majority of high-end flagships … more

Apple Music Will Increase iTunes Match to 100,000 Songs

The battle for music streaming subscription dominance is starting to really heat … more

Xposed Framework Updated to v65

Xposed Framework is an extremely popular modification platform for Android, so much so that we included … more

Compcache userinit.sh tutorial for Cyanogen 367

1,865 posts
Thanks Meter: 229
 
By bkmo, Senior Member on 16th July 2009, 07:02 AM
Post Reply Subscribe to Thread Email Thread
Here is a simple tutorial to get compcache ramswap running on the new Cyanogen 3.6.7 rom. Thanks to Cyanogen we now have a functioning swap that is fast and will not cause SSD wear.

Please make sure you have adb installed and functioning before you continue, as this tutorial will utilize adb to push the required files to the phone. Also your sd card should have a 500megish ext(2,3,4) partition as the second partition for this to work.

Download the userinit.sh.txt file attached here then:

Rename it to userinit.sh
create a directory c:\userinit
copy userinit.sh to c:\userinit
open CMD prompt
adb push c:\userinit\userinit.sh /system/sd
adb shell chmod 755 /system/sd/userinit.sh (not sure if needed being safe)
adb shell reboot

( This completes the compcache setup )

++++++++++++++++++++++++++++++++++++++++++++

To see if it is working enter: cat /proc/ramzswap in the terminal console app on the phone. You should have a XX% GoodCompress listed if it is working properly.


Hope this helps a bit. Please correct me if I made mistakes.

edit: re-uploaded the script with swappiness set to 60. You can re-push the new one the same way.

edit: removed media info from post and userinit.sh to simplify things.

edit: the following may help for those unable to get adb working. Make sure you place userinit.sh on the root of your sd (fat32 partition)
in terminal emulator:
su
mount -o remount,rw /dev/block/mtdblock3 /system
cp /sdcard/userinit.sh /system/sd
chmod 755 /system/sd/userinit.sh
Attached Files
File Type: txt userinit.sh.txt - [Click for QR Code] (267 Bytes, 3336 views)
Last edited by bkmo; 18th July 2009 at 06:51 AM.
 
 
16th July 2009, 07:16 AM |#2  
Senior Member
Thanks Meter: 0
 
More
thanks...very helpful tuttorial
16th July 2009, 07:16 AM |#3  
Senior Member
Flag Temple City, CA
Thanks Meter: 14
 
More
Just did the audio push and it moved all 3 folders
16th July 2009, 07:17 AM |#4  
DOHCtor's Avatar
Senior Member
Flag Southern California
Thanks Meter: 122
 
More
Does this mean we no longer need the linux swap partition?
16th July 2009, 07:20 AM |#5  
OP Senior Member
Flag 10 5' 59" North, 84 16' 84" West
Thanks Meter: 229
 
More
Quote:
Originally Posted by DOHCtor

Does this mean we no longer need the linux swap partition?

It is no longer needed. Compcache should work better, but time will tell I guess.
16th July 2009, 07:23 AM |#6  
DOHCtor's Avatar
Senior Member
Flag Southern California
Thanks Meter: 122
 
More
Quote:
Originally Posted by bkmo

It is no longer needed. Compcache should work better, but time will tell I guess.

I'll just leave my linux swap partition there for now then.

I notice when I run #free it shows total swap size around 24mb. With the linux swap, I get 32mb.
16th July 2009, 07:24 AM |#7  
OP Senior Member
Flag 10 5' 59" North, 84 16' 84" West
Thanks Meter: 229
 
More
Quote:
Originally Posted by P_Dub_S

Just did the audio push and it moved all 3 folders

so you are saying on your sd card you now have:
/system/sd/media with subfolders of ringtones, alarms, notifications, ui ?
16th July 2009, 07:26 AM |#8  
endolin's Avatar
Member
Thanks Meter: 8
 
More
thanks for the tutorial
thanks for the tutorial. one questions remains. how do we disable the sd-swap?
16th July 2009, 07:26 AM |#9  
drpfenderson's Avatar
Senior Member
Flag Portland, OR
Thanks Meter: 37
 
More
Thank you so much for this. Seems to be working perfectly on 3.6.7.1. Cheers!
16th July 2009, 07:26 AM |#10  
OP Senior Member
Flag 10 5' 59" North, 84 16' 84" West
Thanks Meter: 229
 
More
Quote:
Originally Posted by DOHCtor

I'll just leave my linux swap partition there for now then.

I notice when I run #free it shows total swap size around 24mb. With the linux swap, I get 32mb.

Good, it is working fine then. I believe that the 24mb is pre-compiled by Cyanogen and is not user configurable right now.
Post Reply Subscribe to Thread

Tags
compcache, userinit.sh
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes