FORUMS
Remove All Ads from XDA

[GUIDE] Extract .rfs files

142 posts
Thanks Meter: 51
 
By mopodo, Senior Member on 11th August 2010, 09:51 PM
Post Reply Email Thread
I came from HTC Hero to the Samsung Galaxy S GT-I9000
So I had never problems with cooking something up, but in the Galaxy I faced .rfs files and a flashing tool I can't use on linux...

So I searched through some boards to find a way to extract the .rfs files here a working guide for the S I9000.

What you need
  • Linux (tested with Debian testing)

It's pretty simple, execute this commands as root on your computer


SHORT WAY (thanks to mimocan)
Code:
# mount -o loop factory.rfs /some_dir


LOOOONG WAY
Attatch the rfs file to the loop device
Code:
# losetup /dev/loop0 /somedir/factoryfs.rfs
Create a directory to mount the device
Code:
# mkdir /somedir/mnt
Mount the device
Code:
# mount /dev/loop0 /somedir/mnt
the content of the rfs is NOT saved on the sdcard! you have to copy it!

Now you can copy the content from the /sdcard/tmp directory to the sdcard
Code:
# cp -R /somedir/mnt /somedir/factoryfs
hope this is helpful for someone
The Following 5 Users Say Thank You to mopodo For This Useful Post: [ View ] Gift mopodo Ad-Free
 
 
11th August 2010, 10:17 PM |#2  
Member
Flag Amsterdam
Thanks Meter: 3
 
More
Code:
#mount -o loop factory.rfs /some_dir
should do the same
The Following 3 Users Say Thank You to mimocan For This Useful Post: [ View ] Gift mimocan Ad-Free
11th August 2010, 11:49 PM |#3  
Junior Member
Thanks Meter: 4
 
More
This works because rfs is based on vfat.
But have you ever tried this on cache.rfs or dbdata.rfs?
The mounted folder is empty. The cache.rfs in my case was around 1.2 mb.

Maybe the 1.2 mb are journaling data rfs uses?

I also tried mounting cache.rfs and dbdata.rfs directly on my sgs without any luck.
Since the phone has built in rfs drivers it should be able to mount it.
12th August 2010, 12:48 AM |#4  
OP Senior Member
Thanks Meter: 51
 
More
Quote:
Originally Posted by psternx

This works because rfs is based on vfat.
But have you ever tried this on cache.rfs or dbdata.rfs?
The mounted folder is empty. The cache.rfs in my case was around 1.2 mb.

Maybe the 1.2 mb are journaling data rfs uses?

I also tried mounting cache.rfs and dbdata.rfs directly on my sgs without any luck.
Since the phone has built in rfs drivers it should be able to mount it.

If you open the cache.rfs or dbdata.rfs from a PDA build (tested I900XXJP3) in a hexeditor you will see they are empty, just the headers and a lot of zeros
12th August 2010, 09:45 AM |#5  
darksnarfer's Avatar
Member
Thanks Meter: 1
 
More
Have you been able to modify something from a rfs file and save it?
12th August 2010, 11:25 AM |#6  
Senior Member
Thanks Meter: 19
 
More
Actually Cache.rfs file in CSC is a renamed update.zip. At least with a few firmwares I have tried. So just open it with, for example, 7-zip and you can browse the files.
3rd September 2010, 08:12 PM |#7  
hkfan's Avatar
Senior Member
Flag Toronto
Thanks Meter: 177
 
More
deleted............
19th September 2010, 04:38 PM |#8  
bloodrider's Avatar
Senior Member
Thanks Meter: 17
 
More
Tried to mount a cache.rfs and got a "Device or resource busy".

Then tried to open it trough MagicISO, and voilá, I got the CSC files I needed
3rd October 2010, 07:34 PM |#9  
a-son's Avatar
Senior Member
Flag Tierra del norte
Thanks Meter: 11
 
Donate to Me
More
Now im into modifying factoryfs.rfs and hoping you can give me some tips.

Alt1
mount -o loop factoryfs.rfs directory & Copy files to a new place and edit them but how to create a .rfs from that point?

Alt2
sudo mount -v -o rw,loop,uid=$UID factoryfs.rfs Directory
Edit the files , umount the .rfs . Mount it again but the the changes are gone.

How do you do it?

Thanks.
3rd October 2010, 07:43 PM |#10  
Recognized Developer
Thanks Meter: 2,830
 
Donate to Me
More
Quote:
Originally Posted by a-son

Now im into modifying factoryfs.rfs and hoping you can give me some tips.

Alt1
mount -o loop factoryfs.rfs directory & Copy files to a new place and edit them but how to create a .rfs from that point?

Alt2
sudo mount -v -o rw,loop,uid=$UID factoryfs.rfs Directory
Edit the files , umount the .rfs . Mount it again but the the changes are gone.

How do you do it?

Thanks.


for me, i'll definitelty mod it elsewhere
3rd October 2010, 07:46 PM |#11  
a-son's Avatar
Senior Member
Flag Tierra del norte
Thanks Meter: 11
 
Donate to Me
More
Quote:
Originally Posted by ykk_five

for me, i'll definitelty mod it elsewhere

Thanks for answer.
Alt 1 i suppose you mean. But how to create the .rfs ?
Post Reply Subscribe to Thread

Tags
cooking, extract, linux, rfs

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes