[Q] modify factoryfs.rfs - Galaxy S I9000 Q&A, Help & Troubleshooting

how can i modify the content of factoryfs.rfs so that the file is flashable with odin?
i know how to extract the files but not how to modify the content directly.
i've tried to do it directly on the device, but i can only mount is as vfat and not rfs, so modifications are not saved correctly after unmounting...
here are my commands:
this works but i can't make changes that are saved
/tmp # mount -o loop /sdcard/external_sd/factoryfs.rfs rfs/
for some reason mounting as rfs does not work, how can i fix this?
/tmp # mount -t rfs -o loop /sdcard/external_sd/factoryfs.rfs rfs/
mount: mounting /dev/loop19 on rfs/ failed: No such device

read here http://forum.xda-developers.com/showthread.php?t=751827&page=3
without rfs support for linux it is impossible

yes i know that but i try to mount it on the device itself and there we should have rfs support

Related

Is there a way to make apps use /sdcard/ApplicationData rather than /sdcard ?

Is there a way to make all applications store their data in a folder other than /sdcard (root folder on the sd card) ?
I'm planning on rooting and thought that this time round I can keep my sdcard nice and organized by creating an "ApplicationData" folder in the root of the sdcard and somehow configuring android to use that.
On a similar note, can I move the DCIM (camera photos) to a different location too?
Will the below change-mount-point idea work?
Maybe as root we can
1) un-define /sdcard (in /etc/fstab) //or wherever its defined
2) define /sdcard as /dev/<hdb0>/ApplicationData //change hdb0 to the appropriate device/partition
thanks.
Yeah, I see your point... but quite frankly, I believe it's upto the app developers [my knowledge of the Android world is still from the stone-age!!]... if the app specifies that it's data will be stored in /sdcard/AppName, there's not much you can do, unless you can modify the app...
I was thinking that maybe as root we can
1) un-define /sdcard (in /etc/fstab) //or wherever its defined
2) define /sdcard as /dev/<hdb0>/ApplicationData
edit: added to post#1
britoso said:
I was thinking that maybe as root we can
1) un-define /sdcard (in /etc/fstab) //or wherever its defined
2) define /sdcard as /dev/<hdb0>/ApplicationData
edit: added to post#1
Click to expand...
Click to collapse
I did think of this too...
/sdcard --> /sd/AppData
rest of sd card --> /sd
but I think it would mean some other changes as well... for example... the mount usb functionality would have to be modified to mount/unmount a different volume...
So heres the contents of my fstab file:
Code:
C:\>adb shell cat /system/etc/fstab
/dev/block/mtdblock3 /system yaffs2 rw
/dev/block/mtdblock4 /cache yaffs2 rw
/dev/block/mtdblock5 /data yaffs2 rw
/dev/block/mmcblk0p1 /sdcard vfat rw
/dev/block/mmcblk0p2 /system/sd auto rw
/system/modules/modules.sqf /system/modules squashfs ro,loop
/system/xbin/xbin.sqf /system/xbin squashfs ro,loop
I'll try changing line 4 (/sdcard), I'm guessing /system/sd is for when I apps2sd is enabled.
Question: How do I escape from INSERT/EDIT mode in VI? Tried pressing trackball+1, trackball+1+2...didnt work
Hey britoso!
Keep us updated with your accomplishments. I, personally, am very interested in being able to achieve this.
Good luck!
update: that didnt work.
Note: the way to get the ESCAPE character is CONTROL + [ (hold the trackball then press [ ). The control key is configurable and defaults to the Jogball/TrackBall
here are the contents of my fstab file, the camera app is still writing to the root of the sdcard (/sdcard/DCIM)
Code:
C:\>adb shell cat /system/etc/fstab
/dev/block/mtdblock3 /system yaffs2 rw
/dev/block/mtdblock4 /cache yaffs2 rw
/dev/block/mtdblock5 /data yaffs2 rw
/dev/block/mmcblk0p1 /sdcard/AppData vfat rw
/dev/block/mmcblk0p2 /system/sd auto rw
/system/modules/modules.sqf /system/modules squashfs ro,loop
/system/xbin/xbin.sqf /system/xbin squashfs ro,loop
Heres the output of "df"
Code:
C:\>adb shell df
Filesystem 1K-blocks Used Available Use% Mounted on
tmpfs 197600 0 197600 0% /dev
tmpfs 4096 0 4096 0% /sqlite_stmt_journals
/dev/block/mtdblock3 148480 100088 48392 67% /system
/dev/block/mtdblock5 200960 63752 137208 32% /data
/dev/block/mtdblock4 97280 39628 57652 41% /cache
/dev/block//vold/179:1
15643712 6843256 8800456 44% /sdcard
@britoso
This is what I found out about mounts in Android...
The init program directly mounts all filesystems and devices using either hard-coded file names or device names generated by probing the sysfs filesystem (thereby eliminating the need for a /etc/fstab file in Android).
And from what I see in your df output, it didn't mount /sdcard/AppData...
Have a few ideas in mind... gonna try 'em out now...
craigacgomez said:
gonna try 'em out now...
Click to expand...
Click to collapse
thanks for the info. Let us know how it works out.
Here's what I reached finally...
To achieve this, I have 2 ideas...
1. We gotta modify the init and change the SD mount point to AppData and add another for the rest of the SD... this however would require a rebuilt ROM (I can't edit init on the phone, need to edit init.c from the source)
2. We push some startup scripts to achieve this, but so far, I haven't been able to mount anything else on /sdcard (operation failed), but I think I'm doing something wrong...
Didn't get much time to experiment... and it mite be a busy end of week for me... but I'll try to squeeze in so time to get this...
Why not ask Cyanogen to do this for us in his next ROM?
Or your next favorite modder?
I'm sure they'll like this idea!?
theres a setting in /init.rc that may help
Code:
export EXTERNAL_STORAGE /sdcard
However / is mounted read-only
mount
rootfs on / type rootfs (ro,relatime)
Click to expand...
Click to collapse

SDcard Issue...

Can someone explain how I can delete a file from the SDcard, yet still see it and open it on my drive in Windows? Also, why can't I see files placed on my SDcard from Windows until I reboot my device...
I created this script in attempt to fix the second issue, I think it works okay most of the time... Issue arise only if it can't unmount /sdcard successfully.
Code:
umount -f /dev/block/mmcblk0p1
mount -o rw,noatime,nodiratime,fmask=0000,dmask=0000,iocharset=iso8859-1,flush -t vfat /dev/block/mmcblk0p1 /sdcard

[Q] Mount RFS files

How do I mount RFS files in Ubuntu?
anyone please?
The easy way (under linux):
Code:
$ mkdir newfolder
$ mount -o loop file.rfs newfolder
for more details check this thread http://forum.xda-developers.com/showthread.php?t=751827

[HELP] broken lcd + after working with adb doesnt boot

Hey xda-community,
might be a long text to read but i want to make it as detailed as possible :/.
I have an i9070 with broken lsd (+touch not working) and pattern lock.
i booted into recoverymode (TWRP) and removed the pattern lock via adb shell ("rm /data/system/gesture.key").
i wanted to use [email protected] so i tried to activate USB Debugging via adb shell.
in the internet i found a method and tried it right away
i had to pull /system/build.prop
add the line "persist.service.adb.enable=1" in the file
and after that i had to push it back, but i couln't.
So i searched to mount /system r/w ..... (prob for the false device ,_, )
i tried the 1st command and forgot the 4 in ext4, so i typed it like this in the adb shell:
# mount -o rw,remount -t ext /dev/block/mmcblk0p8 /system
# mount -o rw,remount -t ext4 /dev/block/mmcblk0p8 /system
after that i was able to push the build.prob back, and used
# mount -o ro,remount -t ext /dev/block/mmcblk0p8 /system
# mount -o ro,remount -t ext4 /dev/block/mmcblk0p8 /system
afterwards.
Rebooted it and it stuck while booting prob.
So i tried the push back the original build.prop. (thought it might be the cause)
Still not booting..
I ended trying all commands without any order:
# mount -o ro,remount -t ext /dev/block/mmcblk0p3 /system
# mount -o rw,remount -t ext /dev/block/mmcblk0p3 /system
# mount -o ro,remount -t ext4 /dev/block/mmcblk0p3 /system
# mount -o rw,remount -t ext4 /dev/block/mmcblk0p3 /system
# mount -o ro,remount -t ext /dev/block/mmcblk0p8 /system
# mount -o rw,remount -t ext /dev/block/mmcblk0p8 /system
# mount -o ro,remount -t ext4 /dev/block/mmcblk0p8 /system
# mount -o rw,remount -t ext4 /dev/block/mmcblk0p8 /system
chmod 755 system
chmod 777 system
i used also mount..../mmcblk0p3 instead of mmcblk0p8 because after using "mount" it showed behind the /system mmcblk0p3 ...
i messed too much around as a newbie :crying:
I am still able to use adb in recovery mode but cant acces the internal storage.
Would be nice if someone could help me
Ty if you read the whole text .. ^^

Fix Persist Partition in XT1063

Put this zip file in the sdcard internal (very important in marshmallow) and flash but before mount the persist partition in TWRP 3.0.0.1 + theme.
Theme is here http://forum.xda-developers.com/showthread.php?p=65199244
[THEME][TWRP] TWRP 3.0.0 dark stock theme pack w different colors v2 [07.03.2016]
Files and folders, extracted from a XT1063
Mount again the partition before reboot [emoji16]
Note: It does not work if the partition is not mounted and Zip in SDinternal
1.-Reboot to recovery
2.-Mount the persist partition
3.-Flash The zip in SDInternal
4.-Mount the persist partition again
5.-Reboot
6.-Enjoy
jacbarahona72 said:
Put this zip file in the sdcard internal (very important in marshmallow) and flash but before mount the persist partition in TWRP 3.0.0.1 + theme.
Theme is here http://forum.xda-developers.com/showthread.php?p=65199244
[THEME][TWRP] TWRP 3.0.0 dark stock theme pack w different colors v2 [07.03.2016]
Files and folders, extracted from a XT1063
Mount again the partition before reboot [emoji16]
Note: It does not work if the partition is not mounted and Zip in SDinternal
1.-Reboot to recovery
2.-Mount the persist partition
3.-Flash The zip in SDInternal
4.-Mount the persist partition again
5.-Reboot
6.-Enjoy
Click to expand...
Click to collapse
hey..
how can i mount the persist in twrp..? there is no option for persisit..? and mount command alsa not owtrking on twrp..
~ # ←[6nmount -o remount,rw /persist
mount -o remount,rw /persist
mount: can't find /persist in /proc/mounts
~ # ←[6nmount -o remount,rw /mmcblk0p29
mount -o remount,rw /mmcblk0p29
mount: can't find /mmcblk0p29 in /proc/mounts
~ # ←[6nmount -o rw,remount /persist
mount -o rw,remount /persist
mount: can't find /persist in /proc/mounts
t-mobile_mda said:
hey..
how can i mount the persist in twrp..? there is no option for persisit..? and mount command alsa not owtrking on twrp..
~ # ←[6nmount -o remount,rw /persist
mount -o remount,rw /persist
mount: can't find /persist in /proc/mounts
~ # ←[6nmount -o remount,rw /mmcblk0p29
mount -o remount,rw /mmcblk0p29
mount: can't find /mmcblk0p29 in /proc/mounts
~ # ←[6nmount -o rw,remount /persist
mount -o rw,remount /persist
mount: can't find /persist in /proc/mounts
Click to expand...
Click to collapse
this method would solve the changed partition problem xt 1078 by the xt1068 partition.
t-mobile_mda said:
hey..
how can i mount the persist in twrp..? there is no option for persisit..? and mount command alsa not owtrking on twrp..
~ # ←[6nmount -o remount,rw /persist
mount -o remount,rw /persist
mount: can't find /persist in /proc/mounts
~ # ←[6nmount -o remount,rw /mmcblk0p29
mount -o remount,rw /mmcblk0p29
mount: can't find /mmcblk0p29 in /proc/mounts
~ # ←[6nmount -o rw,remount /persist
mount -o rw,remount /persist
mount: can't find /persist in /proc/mounts
Click to expand...
Click to collapse
You read that right ?, while installing THEME, is appended to the menu "mount" The "persist" partition friend. please follow the instruction
Work Only in the version ** TWRP 3.0.0-1 **, and Version 1 from the theme or 2, I am no sure in this moment. [emoji16]
Enviado desde mi Nexus 6

Categories

Resources