Post Reply

cache to sd card

OP saul972

7th November 2008, 08:56 PM   |  #1  
OP Senior Member
Flag Dallas
Thanks Meter: 1
 
103 posts
Join Date:Joined: May 2007
More
Has anyone tried this


http://modmygphone.com/forums/showthread.php?t=4851


Root the phone. How to do it is already here...

Now:
cd /data/data/com.android.browser/cache
rm -R webviewCache
mkdir /sdcard/webviewCache
ln -s /sdcard/webviewCache webviewCache

You are changing to the cache directory.
Deleting the web cache directory.
Making a new one on the sdcard.
Linking symbolically the new one to the old one.

Now open your browser and surf. Your phone does NOT know you did this and it thinks it still has the old one. If you plug your phone into your computer and check you will see a lot of files with 8 character names. (after having surfed of course)

To your phone it is as though the webviewCache is still in the same spot. In reality it is on your SD Card where you have plenty of room for it.

******Warning*****

After doing this to my phone a few hours I tried dowloading an app from the market and I was getting error messages. So I reset my phone thinking it would fix the problem but when i tried to get pass the google log in screen it said my account didn't have the data plan. I re-flashed using the RC28 update.zip file and got it back up. just my experience
Last edited by saul972; 8th November 2008 at 03:09 AM.
7th November 2008, 09:52 PM   |  #2  
Senior Member
Thanks Meter: 5
 
219 posts
Join Date:Joined: Oct 2007
can some one help..when i run the first line cd /data/data/com.android.browser/cache it said canr cd to thats location....wat is the problem???

i just noticed that the first line only works if u have cache saved already....i cleared mine n thats y it didnt read the whole line lol opps
Last edited by cookzitall; 7th November 2008 at 10:04 PM.
8th November 2008, 01:22 AM   |  #3  
Retired Moderator
Thanks Meter: 10
 
1,271 posts
Join Date:Joined: Mar 2008
More
Quote:
Originally Posted by saul972

Has anyone tried this


http://modmygphone.com/forums/showthread.php?t=4851


Root the phone. How to do it is already here...

Now:
cd /data/data/com.android.browser/cache
rm -R webviewCache
mkdir /sdcard/webviewCache
ln -s /sdcard/webviewCache webviewCache

You are changing to the cache directory.
Deleting the web cache directory.
Making a new one on the sdcard.
Linking symbolically the new one to the old one.

Now open your browser and surf. Your phone does NOT know you did this and it thinks it still has the old one. If you plug your phone into your computer and check you will see a lot of files with 8 character names. (after having surfed of course)

To your phone it is as though the webviewCache is still in the same spot. In reality it is on your SD Card where you have plenty of room for it.

The last line could essentially save apps on the SD card as well can it not?

BTW apps are saved in several locations, the main apk is in /data/app/ while the data itself is saved in /data/data/ I wonder if you could just link to /data/ as sdcard/data/
11th November 2008, 04:01 AM   |  #4  
Senior Member
Thanks Meter: 0
 
269 posts
Join Date:Joined: May 2008
More
quick question.. where does the cache go if u remove the sdcard and/or you mount it to a pc?
does it save on the device?
does it just not save?
or does it give you an error?
11th November 2008, 04:07 AM   |  #5  
Stericson's Avatar
Retired Senior Mod / Senior Recognized Developer - Godfather of Android Theming
Thanks Meter: 382
 
1,193 posts
Join Date:Joined: Nov 2008
it just doesn't save, I tried it
27th November 2008, 06:29 PM   |  #6  
Senior Member
Flag Huntington Beach
Thanks Meter: 0
 
176 posts
Join Date:Joined: Jul 2007
More
undo changes??
Happy Thanksgiving everyone,

I was wondering if anyone could write out the code on how we could undo these changes. I'm sure its very similar to what stericson wrote for the market cache but I just wanted to make sure on the details. Thank you!

hbguy
28th November 2008, 01:02 AM   |  #7  
Junior Member
Thanks Meter: 0
 
5 posts
Join Date:Joined: May 2007
The undo for this would be:

Code:
cd /data/data/com.android.browser/cache
rm webviewCache
mkdir webviewCache
chmod 771 webviewCache
busybox chown app_18 app_18 webviewCache
rm -R /sdcard/webviewCache

To explain:
- change to the correct directory
- remove symbolic link to the sd card
- re-create original directory
- change the access permissions back to defaults
- change ownership back to defaults
- remove cache on the sd card

Few points on this.
I've not actually done this completely, just used my linux knowledge, and tested the chmod/chown steps procedure on my TC5-RC8, but not really sure if it's necessary (there for the sake of accuracy)
Had to use busybox chown as chown not natively found
I'm new to android and have made the assumption everyone's webviewCache is orginally owned by app_18? For all I know, this is randomly generated. I'm sure someone can confirm.

I wouldn't use this method and randomly remove the sdcard...that would be asking for data corruption on the sd card...
28th November 2008, 09:31 AM   |  #8  
Senior Member
Flag Huntington Beach
Thanks Meter: 0
 
176 posts
Join Date:Joined: Jul 2007
More
thanks budvar!

can someone confirm please?

hbguy
28th November 2008, 05:08 PM   |  #9  
Junior Member
Thanks Meter: 0
 
4 posts
Join Date:Joined: Nov 2008
webcache owner
Don't think the app owner is always 18. Permissions on my webcache dir are for app_24
28th November 2008, 06:27 PM   |  #10  
Member
Thanks Meter: 9
 
56 posts
Join Date:Joined: Nov 2008
Web on da as would be sweet throw 8gb In and have no worries about on board space or lag time as the unit deletes cache I hope to see this added to the next firmware for users that plan on using a bigger sd card g1 is a great phone

Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes