Android Tablets Forum banner
Status
Not open for further replies.
1 - 16 of 16 Posts

·
Registered
Joined
·
384 Posts
Discussion Starter · #1 ·
I simply hate waiting for home screen or for backgrounded apps to reload in memory so I decided to enable the SWAP on my M001.Quite simple:- prepare an SD card with first partition being all the size FAT32 formatted , minus 128MB (it's arbitrary the dimension, the bigger space you leave, the bigger virtual memory You'll get). I made partitioning in Gparted, very trusted linux program you can find in any distribution and is GTK based. First partition FAT32 (boottable flag on) and second partition LINUX SWAP (mine was only 128MB cause I don't have a big SD card unfortunately).- connect it to your Eken and enter terminal emulator+su+vi or EZ file explorer..I put this little add on in usbgadget.sh, cause this script is called at any reboot:Insert this after the first written line (after #!/system/bin/sh , and before the if blablabla line)
Code:
swapon /dev/block/mmcblk0p2 #according to your number of SD partitions, it could be mmcblk0p3 etc.echo 15 > /proc/sys/vm/swappiness #important for setting the right swapping attitude; higher numbers (0-100) will increase the swapping in SD card, [b]shortening its life for sure too much[/b]; could even impact on performance if it's too high cause the SD cards aren't really fast to be used like ram memory.
Ok.. remember to save the file, cross your fingers and reboot: in terminal emulator if you issue the command
Code:
free
you'll see that swap memory spaces aren't zeroes anymore, and with this settings you'll see some relief when using high ram demanding apps or parallel applications. SD CONSIDERATIONS:Data traffic on an SD card causes nand cells to worn quicker than before. So if you decide for this, consider that your SD could die sooner; use it better on good 1.000.000 cycles guaranteed SD cards like good Kingstones or Sandisks.. That's why I decided it's better to use a partition for swapping and not SwapFile made in dd... It will only wear a part of the disk, and if it runs out of nand cells life you should not have your data damaged, but only swap partition you can live without ;DI'm not responsible for any casualties may happen to you, your device or mind
USE IT AT YOUR OWN RISK !!!
 

·
Registered
Joined
·
384 Posts
Discussion Starter · #3 ·
[quote author=Asure link=topic=686.msg5541#msg5541 date=1275822857]Interesting! But will it blend ? ;)In other words, do you notice a faster, responsive system, or does it stay as slow as before ?[/quote]With this settings i've posted you'll get faster task switching and better browser experience.. use a CLASS 4 or better SD and you'll notice that easily.I'm looking now about COMPCACHE but i guess I should patch the kernel. Our kernel is slightly better than crap but long way to be efficient... need source now..
 

·
Registered
Joined
·
384 Posts
Discussion Starter · #5 ·
[quote author=Mr ILIA link=topic=686.msg5599#msg5599 date=1275834741]I do npt have linux, however i have android phone that i can use to format sd card and particion it with virtual memory.whould it be the same as done by the OP?[/quote]i don't know what program do you mean in android but the things are easy..in the end the sd card must contain 2 partitions... first one FAT32 , second one LINUX SWAP filesystems.. then you're ready to go ;)
 

·
Registered
Joined
·
384 Posts
Discussion Starter · #7 ·
[quote author=deadfunk link=topic=686.msg5608#msg5608 date=1275835321]interesting work. However, with the new mod usb cable, the M001 Eken, now recognizes the fash memory. would not be faster and longer solution, make the virtual memory on a USB fash?nice work![/quote]thanks, but really nothing special (hope to get here more complex goodies for our devices next days ;) )Your idea isn't bad and it's not difficult to make it work, but some considerations have to be done.If you remove the usb cable or usb pendrive, kernel could freeze because it has a non-synced filesystem mounted on it.. this could happen sometimes.The little addon i've posted is not perfect cause if you remove the sd card you may get problems too and if it's not present at boot time, swapon won't load at all till next reboot..I'd like to know where the extraction script is (the one that uses android when you unmount a SD card)I coul improve it.. but..we should think about getting the source and compiling compcache... it's way better and more responsive
 

·
Registered
Joined
·
82 Posts
[quote author=deadfunk link=topic=686.msg5608#msg5608 date=1275835321]interesting work. However, with the new mod usb cable, the M001 Eken, now recognizes the fash memory. would not be faster and longer solution, make the virtual memory on a USB fash?nice work![/quote]How can I verify that the formatting works as intended, e.g memory swap?
 

·
Registered
Joined
·
83 Posts
There is an alternative to the scripting and partitioning. I use Swapper v2 which is an APK that does all the above work for you. It has 2 modes, a Swap File or a Swap Partition. For the File Mode, no partitioning is needed, it just creates a file and uses that. For Partition Mode, you still need to partition the SD and know its device path.The whole thing is menu driven, and many options are selectable (such as Swappiness and File Size).It does all the scripting for you, and even does a SwapOff if the SD is unmounted.I have tried both methods and performance between the 2 is negligible on this hardware. It is easy to see the improvement over not having swap, especially when browsing.This requires ROOT, of course.
 

·
Registered
Joined
·
107 Posts
Hi Imayoda or dkjabCould you run benchmark using this benchmark app?http://www.androidapk.net/?p=8Willo and Original EKEN ROMS shows results as follows:--------------------------- Orig v1.7.1 Orig. v.1.7.2 Willo v1.1 Willo1.2Total graphics score 52.70455 58.610104 57.41785 58.114826Total CPU score 87.69739 90.30014 101.63379 101.12931Total memory score 95.289635 102.12509 104.959465 106.544685and ECOTOX ROM tested on May 28th is Graphics 56.65CPU 101.89Memory 104.99Does swap returns better result than that or swapping impacts elsewhere than those benchmark results?I'm not familiar with this swap technique at all so sorry in advance if what I asked does not make sense at all
 

·
Registered
Joined
·
384 Posts
Discussion Starter · #11 ·
[quote author=Taka link=topic=686.msg5736#msg5736 date=1275868390]Hi Imayoda or dkjabCould you run benchmark using this benchmark app?http://www.androidapk.net/?p=8Willo and Original EKEN ROMS shows results as follows:--------------------------- Orig v1.7.1 Orig. v.1.7.2 Willo v1.1 Willo1.2Total graphics score 52.70455 58.610104 57.41785 58.114826Total CPU score 87.69739 90.30014 101.63379 101.12931Total memory score 95.289635 102.12509 104.959465 106.544685and ECOTOX ROM tested on May 28th is Graphics 56.65CPU 101.89Memory 104.99Does swap returns better result than that or swapping impacts elsewhere than those benchmark results?I'm not familiar with this swap technique at all so sorry in advance if what I asked does not make sense at all
[/quote]Tomorow i'll try to get better results... now i have usb hub connected and keyboard + mouse.. it stays at 10% than ecotox posted values.. i guess it's because the hardware i connected... it was all on Graphics 54.23CPU 97.64Memory 97.06The program detects SWAP area correctly.. however swap is used to get some more memory but slower one, good only for the kernel to store dormient tasks and awake them when needed, rater than reloading entire process ;)
 

·
Registered
Joined
·
107 Posts
[quote author=dkjab link=topic=686.msg5687#msg5687 date=1275858586]There is an alternative to the scripting and partitioning. I use Swapper v2 which is an APK that does all the above work for you. It has 2 modes, a Swap File or a Swap Partition. For the File Mode, no partitioning is needed, it just creates a file and uses that. For Partition Mode, you still need to partition the SD and know its device path.The whole thing is menu driven, and many options are selectable (such as Swappiness and File Size).It does all the scripting for you, and even does a SwapOff if the SD is unmounted.I have tried both methods and performance between the 2 is negligible on this hardware. It is easy to see the improvement over not having swap, especially when browsing.This requires ROOT, of course.[/quote]dkjab, could you share us a how to do your method using Swapper v2? Since I'm not familiar with those swap trick, I'd like to try mine as simple as possible. Thanks!! ;D
 

·
Registered
Joined
·
384 Posts
Discussion Starter · #15 ·
[quote author=ch4rlii link=topic=686.msg5842#msg5842 date=1275898281]Hi!Is it also possible to use the internal memory? I still have 1.4Gig free...[/quote]it's definitely NOT a good idea.. if you wear off that nand chip you'll probably brick your device since it is the only chip with multiple partitions in the device..I suggest you: DON'T DO IT!!! ;)
 
1 - 16 of 16 Posts
Status
Not open for further replies.
Top