1. Download our Official Android App: Forums for Android!

How to get more RAM (rooted devices only)

Discussion in 'Android Lounge' started by androidboss7, Sep 16, 2011.

  1. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    IF YOU DON'T KNOW WHAT THIS IS ABOUT, BEST NOT TO TRY IT!!

    Get more RAM and faster responses by disabling verify-bytecode!
    Here's a little tip that would give you more RAM on your device.
    Also check out the links below.

    AS WITH ANY MODDING PROCEDURE FOR YOUR PHONE, THIS GUIDE ALSO COMES WITH NO WARRANTY. AUTHOR HOLDS NO RESPONSIBILITY FOR ANY DIRECT AND INDIRECT CONSEQUENCES OF FOLLOWING THIS GUIDE. MAKE SURE YOU HAVE MADE A NAND BACKUP BEFORE PROCEEDING.

    This is not useful in odexed ROMs & devices with 1GB or more RAM. However, this will give a performance boost in deodexed ROMs as much as odexing system & data apps. This is an alternative for odexing. It's not that you can't apply this tweak on an odexed ROM but rather, it's useless to do so.

    Open Terminal Emulator on phone or adb shell from PC and type the following.
    su
    setprop dalvik.vm.verify-bytecode false
    setprop dalvik.vm.dexopt-flags v=n,o=v
    rm /data/dalvik-cache/*
    rm /cache/dalvik-cache/*
    reboot

    ROM devs could add this to the /data/local.prop or build.prop.
    dalvik.vm.verify-bytecode = false
    dalvik.vm.dexopt-flags=v=n,o=v


    Advantages:
    More free RAM.
    Faster launch for system & user apps during the second launch.
    Gives as much as of a performance boost as ODEX without odexing. Themer friendly.
    Smoother app switching.

    Disadvantages:
    Might break some apps.

    Thanks to Danzano for testing this tweak in advance.

    Reversing the change/undo tweak.
    Type the following in shell.
    su
    setprop dalvik.vm.verify-bytecode true
    rm /data/dalvik-cache/*
    rm /cache/dalvik-cache/*
    reboot
    __________________
    Best of regards,
    Nibras.

    > more free RAM & better performance by disabling bytecode-verify
    > 1-click odexing guide with scripts
    > AOSP EMail with Exchange(Corporate)/ActiveSync
    > list of apps for power users
    > alternate fastboot/adb drivers(32 bit and 64bit)

    I believe in sharing, simplicity & love.
    (http://forum.xda-developers.com/showthread.php?p=17566510#post17566510)

    Look at this site on how to increase RAM!!
    (One click ODEXing a ROM for more RAM and better speed. - xda-developers)

    Hope this Helped!!


    THIS METHOD WILL ALSO INCREASE RAM!!
    PLEASE ONLY USE ONE OF THESE METHOD'S



    AS WITH ANY MODDING PROCEDURE/SCRIPTS FOR YOUR PHONE, THIS SCIPT ALSO COMES WITH NO WARRANTY. AUTHOR HOLDS NO RESPONSIBILITY FOR ANY DIRECT AND INDIRECT CONSEQUENCES OF RUNNING THIS SCRIPT. MAKE SURE YOU HAVE MADE A NAND BACKUP BEFORE PROCEEDING. MAKE SURE YOU HAVE AT LEAST 15% FREE ON /SYSTEM, THIS IS IMPORTANT BECAUSE IF YOU RUN OUT OF SPACE THINGS WILL GO BADLY WRONG..

    Requires busybox.

    If your system partition is almost full, have a look at http://forum.xda-developers.com/showthread.php?t=734236.

    This script will *attempt* to odex all apks found at /system/app. Theming would be impossible once the ROM is odexed. Themes applied at the time of odexing will be preserved. If you plan on applying a theme, apply it before odexing. If you want to theme after odexing, you must deodex the ROM before theming. If you change themes often, odexing is not for you.

    Quick Instructions for Windows:
    Connect the phone with USB cable and enable USB debugging. (No wireless or Android Terminal shell)
    Put the phone in airplane mode.
    Download and extract the attached file and run odex.bat
    Download link
    (http://www.4shared.com/file/270vm-Mx/odex-WinXP.html?)

    Instructions for advanced users:
    This attachment contains a folder called odex. Push that folder to data and set the permission of odex.sh to 4755. Mount system as r/w(could be done via adb remount system). Next, execute odex.sh. All of this should be done via USB using ADB shell. Do not use wireless adb or Android Terminal.

    Advantages:
    More free space in system partition.
    Faster booting.
    More free RAM(I was able to gain 20-30MB.)
    Faster access to system apps.

    Disadvantages:
    Cannot be themed after odexing.
    APK tweaks cannot be applied.
    Might break some of the non-AOSP system apps such as Root Explorer if they are installed as system app.

    Acknowledgments:
    Only the odex.bat was created by me. Similar projects were done in past but most of the downloads are broken. So, I collected together different stuff from different places to put together this package.
    adb.exe is from the RATC batch ROOT.
    adb dlls are from Android SDK
    odex.sh is from Paul O Brian from MoDaCo (pastebin.com/EZLWUdea)
    zip, zipalign and dexopt-wrapper are from XDA (http://forum.xda-developers.com/showthread.php?t=734236)

    Next aim: Odex for apps in data/app



    Update:
    I got 1017 on quadrant and 61.8fps on swiftdroid 2.0 M6 overclocked to 844MHz(offline mode with wifi on. No apps except system apps). It must be noted that sometimes odexed ROM performs slightly slower in benchmarks but the difference is very small. However, this does not mean their performance is lower. Odex means apps could load fast thereby making app switching, app loading really fast. And, it also reduces system RAM usage which means more apps could stay in memory making multi-tasking easier. Odexing is something like swap or compcache. Sacrifice something to gain something else. This is for some people who think odexing is useless. The drop in speed is so small that it cannot be noticed without a benchmark but the performance of the phone increases noticeably due to more space in dalvik and RAM.
     

    Advertisement

    karandpr, techlearn and B2L like this.
  2. B2L

    B2L Android Expert
    Rank:
    None
    Points:
    233
    Posts:
    1,833
    Joined:
    Jan 17, 2011

    Jan 17, 2011
    1,833
    658
    233
    Salt Lake City, UT
    Thanks! I'll definitely give this a try. I tend to use way too many widgets, so I'm always using up all of my RAM.
     
  3. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Did anyone yet try this??
    Please report!! :):)
     
  4. B2L

    B2L Android Expert
    Rank:
    None
    Points:
    233
    Posts:
    1,833
    Joined:
    Jan 17, 2011

    Jan 17, 2011
    1,833
    658
    233
    Salt Lake City, UT
    :/ Forgot to report back, my bad.

    I tried the second method, and it worked great. Normally I would only have around 40-50 MB of free RAM, after doing this I constantly have around 100-120MB.

    Thanks a ton, anyone who needs more RAM should definitely give this a try.
     
  5. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    t didn't worked for me, I was trying the first part but when i entered 3 step it gave me some error. :'(

    Someone Plz help
     

    Attached Files:

  6. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    is your phone rooted??
     
  7. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    Yea, its rooted
    i think i got the point, i have once cleaned the dalvik cache using titanium backup.
     
  8. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Another thing is don't type the 2nd
    if it doesn't work again!! :):)
     
  9. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    @androidboss7:
    isn't there any other option to get it working or to get dalvik cache back???
     
  10. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    I don't know about getting dalvik cache back..
    But do when you do it this time don't put in
    the 2nd line!! :):)
    That should do the trick!!
    Cause some people said that it didn't work so
    just remove the 2nd line!!

    And if that doesn't work use TE!! :):)
    Report back!!
     
  11. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    2nd line - "setprop dalvik.vm.dexopt-flags v=n,o=v"

    whats TE:thinking:
     
  12. B2L

    B2L Android Expert
    Rank:
    None
    Points:
    233
    Posts:
    1,833
    Joined:
    Jan 17, 2011

    Jan 17, 2011
    1,833
    658
    233
    Salt Lake City, UT
    TE = Terminal Emulator
     
  13. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Just remove the 2nd line
    And use TE!!
     
  14. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    Damn I don't know how to make it work :(
    sorry for being a noob.
     
  15. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Ok ...
    If u are having trouble just
    Use the 2nd method!!!
     
  16. stu1978

    stu1978 Well-Known Member
    Rank:
    None
    Points:
    18
    Posts:
    87
    Joined:
    Jan 22, 2011

    Jan 22, 2011
    87
    12
    18
    Would this be any use for an Xperia Arc?
     
  17. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Well it depends..
    If your phone has more than 250mb of
    free ram then this would be kinda
    useless!!!
    but if your phone lags cause of low ram
    then you could use this!!
    (i recommend 2nd method as the 1st method doesn't
    work that well)
     
  18. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    i haven't tried this method yet, i am facing few new problems...so will try that later
     
  19. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    ok!!
     
  20. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    @androidboss7: while exploring internal memory using root explorer, i found a folder 'dalvik-cache' will try try method no. 1, today
    and will let u know the result
     
  21. techlearn

    techlearn Member
    Rank:
    None
    Points:
    16
    Posts:
    62
    Joined:
    Jun 24, 2011

    Jun 24, 2011
    62
    6
    16
    hey i have tried the method one, it worked great now i am getting around 100mb RAM free, thanks a lot mate, just a single query

    do i need to copy this also? else performance is great and do it impact mobiles battery life in any manner.
     
  22. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    No you don't need to copy that.
    And no it doesn't effect the battery life, it should make it
    last a bit longer!! ;););)
     
  23. Night Owl

    Night Owl Lurker
    Rank:
    None
    Points:
    5
    Posts:
    4
    Joined:
    Oct 9, 2011

    Oct 9, 2011
    4
    0
    5
    developer
    Russian
    Ok. Have youself tried it yet? What's your result?
     
  24. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    Yes i have tried this myself!! ;);)
    And i could say that the ram increases about 5-20mb
    of ram and quicker switching in apps!! :):)

    On phones with more than 200mb of ram then it
    might not make a difference in ram but it will
    in app switching!! ;);)
    (i also tried both methods and 2nd method gives you
    more ram):D:D
     
  25. androidboss7

    androidboss7 Well-Known Member
    Thread Starter
    Rank:
    None
    Points:
    38
    Posts:
    145
    Joined:
    Jul 26, 2011

    Jul 26, 2011
    145
    15
    38
    If your homescreen always laggs after you press ur
    home button then i suggest u supercharge
    instead on doing this!! ;);)

    Link here:forum.xda-developers.com/showthread.php?t=991276
     

Share This Page

Loading...