[Q] make /data to f2fs problem, help !! - Nexus 7 Q&A, Help & Troubleshooting

Hello,
I'm a new developer and try to reference other people's steps to change /data to f2fs. However, I have some problems and it have bothered me a few days. When I chose format /data and type yes, it showed error message " E: Unable to mount '/data' ". As a result, I decided to format then mount /data by myself. Unfortunately, when I used modified TWRP to mount /data which have already formatted by mkfs.f2fs , it showed error message "mounting /data, operation not supported on transport endpoint". However when I mount /data which formatted by make_ext4, it was success. I have already read my threads but I couldn't find a solution. Did any thing I forget to modified? Can anyone help me or give me some hints? Plz
Here is my modify step: (reference ss2man44 's thread in Nexus 7 Developer Discussion ,#Use of F2FS for /data)
1. use f2fs patch to modified kernel, turn on f2fs then flash to my device. It works.
2. modified twrp.fstab and fstab.grouper
3. give statically link to TWRP
Here is my environment:
Device: Nexus 7 (2012)
Kernel version: 3.1.10 (nightly)
Android version: 4.4.3
ROM: CyanogenMod(cm-11)
TWRP: 2.7.1.0 (support F2FS)

CONFIG_F2FS_FS=y
CONFIG_F2FS_STAT_FS=y
CONFIG_F2FS_FS_XATTR=y
CONFIG_F2FS_FS_POSIX_ACL=y
CONFIG_F2FS_FS_SECURITY=y
That last one defaults to N.
Switching to y fixes f2fs in twrp. However, it looks like I'm running into additional selinux issues with android: ubject_r:unlabeled:s0 data

Related

[Q] Installing Thunderkat 4.4.3 on F2FS partitions

Reading more on F2FS trying to formulate a plan of attackx. Latest TWRP 2.7.1.0 is able to repair/format F2FS partitions, so I'm covered there before installing a ROM.
Some ROMs have the boot.img fstab files mount just /data as F2FS (like a Moto X). Others mount all partitions as F2FS (haven't found any threads comparing benefits of doing all vs. just /data)
/META-INF/Com/Google/android/updater-script needs to be modified to format and mount the appopriate partitions as F2FS.
So for a phased approach, say getting toes wet with just setting up /data for F2FS, is it just
1) editing the ThunderKat_manta-KTU84M-20140607.zip boot.img fstab and changing
Code:
/dev/block/platform/dw_mmc.0/by-name/userdata /data ext4 rw,seclabel,nosuid,nodev,noatime,nomblk_io_submit,errors=panic,
data=ordered 0 0
to
Code:
/dev/block/platform/dw_mmc.0/by-name/userdata /data f2fs rw,seclabel,nosuid,nodev,noatime,nomblk_io_submit,errors=panic,
data=ordered 0 0
2) editing the ThunderKat_manta-KTU84M-20140607.zip /META-INF/Com/Google/android/updater-script so that it will now do a destructive format of /data to F2FS
Code:
format("f2fs", "EMMC", "/dev/block/platform/dw_mmc.0/by-name/userdata", "0", "/data");
3) doing the install from TWRP?
Am I on the right track? Miles off?
If I'm on the right track, what's required to do all partitions as F2FS? Would I have to put the ROM to be installed on a USB stick via USB OTG so that the recovery could find it after all the formatting?
I've been messing with this today and so far, I'm getting permissions issues quite possibly related to SELinux. Issues with SELinux relabeling issues are not allowing writing on F2FS partitions...
EDIT: Confirmed my suspicion that it was SELinux related. Attached screenshot shows CM11 4.4.3 with ThunderKat kernel and data partition mounted as F2FS
Just an idea cause it's so convenient: On my N7 there's an app called "Convert to F2FS" - Play Store. It converts ANY rom to f2fs. It also works for N4 & N5's. Dev states that he'll add other devices if contacted. It works brilliantly & is about a buck & 1/2. It doesn't work on 4.4.3 yet tho
Sent from my Nexus 7 using Tapatalk 2
Hi Craig,
will the latest ThunderKat still fail due to SELinux relabeling if installed on F2FS? Would a tool like this one make a difference?
http://forum.xda-developers.com/galaxy-nexus/development/tool-galaxy-nexus-ext4-to-f2fs-rom-t2794702
craigacgomez said:
I've been messing with this today and so far, I'm getting permissions issues quite possibly related to SELinux. Issues with SELinux relabeling issues are not allowing writing on F2FS partitions...
EDIT: Confirmed my suspicion that it was SELinux related. Attached screenshot shows CM11 4.4.3 with ThunderKat kernel and data partition mounted as F2FS
Click to expand...
Click to collapse
vprasad1 said:
Hi Craig,
will the latest ThunderKat still fail due to SELinux relabeling if installed on F2FS? Would a tool like this one make a difference?
http://forum.xda-developers.com/galaxy-nexus/development/tool-galaxy-nexus-ext4-to-f2fs-rom-t2794702
Click to expand...
Click to collapse
I haven't tested this yet with the new release. Will do so this weekend.
Sent from my Nexus 5
craigacgomez said:
I haven't tested this yet with the new release. Will do so this weekend.
Sent from my Nexus 5
Click to expand...
Click to collapse
FYI latest TWRP 2.8.0.1 does not have F2FS format in wipe, whilst it is in the 2.7.1.0.

[Q&A] [HOW TO] CONVERT any ROM to F2FS format

Q&A for [HOW TO] CONVERT any ROM to F2FS format
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for [HOW TO] CONVERT any ROM to F2FS format. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
Hi I'm having trouble with the conversion to f2fs, I'm currently on TWRP version 2.8.4.0 on HLTE CAN with temasek cm12 rom and lean kernel. When I go to convert the filesystem to f2fs from EXT4 there is no option for F2FS only EXT234,FAT, and exFAT. Accoriding to this thread http://forum.xda-developers.com/showthread.php?t=2494245 HLTECAN does support F2FS since 2.8.1.2 . Any help is appreciated thanks!
PhoenixWrightEsq said:
Hi I'm having trouble with the conversion to f2fs, I'm currently on TWRP version 2.8.4.0 on HLTE CAN with temasek cm12 rom and lean kernel. When I go to convert the filesystem to f2fs from EXT4 there is no option for F2FS only EXT234,FAT, and exFAT. Accoriding to this thread http://forum.xda-developers.com/showthread.php?t=2494245 HLTECAN does support F2FS since 2.8.1.2 . Any help is appreciated thanks!
Click to expand...
Click to collapse
Could you please try rolling back to TWRP 2.8.30 ? Try and report whether the f2fs option is there
Unable to wipe data partition
Trying to convert phone to f2fs. I am able to format system and cache partitions. When I try data partition, I get:
E:Unable to wipe '/data'.
E:Unknown MTP message type:1
E:Error changing file system
Any help?
I am using TWRP 2.8.5.0 on a T-Mobile Note 3.
d3e1123 said:
Trying to convert phone to f2fs. I am able to format system and cache partitions. When I try data partition, I get:
E:Unable to wipe '/data'.
E:Unknown MTP message type:1
E:Error changing file system
Any help?
I am using TWRP 2.8.5.0 on a T-Mobile Note 3.
Click to expand...
Click to collapse
I'm having the same exact problem trying to convert a Nexus 7. Did you ever figure out a solution?
d3e1123 said:
Trying to convert phone to f2fs. I am able to format system and cache partitions. When I try data partition, I get:
E:Unable to wipe '/data'.
E:Unknown MTP message type:1
E:Error changing file system
Any help?
I am using TWRP 2.8.5.0 on a T-Mobile Note 3.
Click to expand...
Click to collapse
Same here. What I did to get around it was to flash back to 2.8.4.0, change the filesystem, then flash back to 2.8.5.0 to restore my nandroid i made with 2.8.5.0. Looks like f2fs for /data is broken in 2.8.5.0 for hltetmo.
I changed cash and system to f2fs, but Data was not Chang.
My antutu score decreased to 34500 from 35170 after I changed my system and cash.
My ROM is aryamod 5.1, with last Lean kernel.
1. Can I change my DATA.
2. how can convert internal memory to f2fs to use SYMLINK.
TNX
Thanks, i tried and this guide working fine on lollipop.

Is there a TWRP build that supports F2FS for /system /cache /data?

There seems to be a lot of confusion or pr people aren't being clear enough. At the moment there's one build found here http://forum.xda-developers.com/showpost.php?p=65193930&postcount=1302 that has F2FS as an option to change to. But I recall there being a problem with the /cache partition too small for F2FS to work, and if you look into F2FS's internal operation a bit, if /cache isn't F2FS then it's pointless.
So I'm asking, is there any TWRP build that supports formatting system/cache/data partitions as F2FS? Is there a way to fix whatever the problem is with /cache unable to be formatted to F2FS? The error I get when I try to format with F2FS is this:
Code:
mkfs.f2fs -t 0 /dev/block/mmcblk0p38 process ended with error: 255
Unable to WIpe Cache
Error changing file system.
Do we need ROM/kernel makers to specifically make their projects with F2FS support? What is the technical issue with getting /cache formatted as F2FS?
bobbarker2 said:
There seems to be a lot of confusion or pr people aren't being clear enough. At the moment there's one build found here http://forum.xda-developers.com/showpost.php?p=65193930&postcount=1302 that has F2FS as an option to change to. But I recall there being a problem with the /cache partition too small for F2FS to work, and if you look into F2FS's internal operation a bit, if /cache isn't F2FS then it's pointless.
So I'm asking, is there any TWRP build that supports formatting system/cache/data partitions as F2FS? Is there a way to fix whatever the problem is with /cache unable to be formatted to F2FS? The error I get when I try to format with F2FS is this:
Code:
mkfs.f2fs -t 0 /dev/block/mmcblk0p38 process ended with error: 255
Unable to WIpe Cache
Error changing file system.
Do we need ROM/kernel makers to specifically make their projects with F2FS support? What is the technical issue with getting /cache formatted as F2FS?
Click to expand...
Click to collapse
Old post, but F2FS requires a minimum of 100 MB to be used on a drive. Ours is 99 MB.

no F2FS support on /data for Oxygen OS 5 (Oreo)?

Previously on Oxygen OS 4.5.15 running your /data partition on F2FS had no problems.
However currently if you try running your /data partition with F2FS either you get an infinite boot loop or if you're decrypted you get an error message that says "Encryption unsuccessful" I'm assuming that's just the kernel being unable to mount the /data partition and just assuming it was a bad encryption or corrupted partition message.
Default partition layout for /data seems to be EXT4 and that works correctly just posting a new topic here to see if anyone else knows the status of F2FS was it removed form OxygenOS 5 kernel?
vortex-5 said:
Previously on Oxygen OS 4.5.15 running your /data partition on F2FS had no problems.
However currently if you try running your /data partition with F2FS either you get an infinite boot loop or if you're decrypted you get an error message that says "Encryption unsuccessful" I'm assuming that's just the kernel being unable to mount the /data partition and just assuming it was a bad encryption or corrupted partition message.
Default partition layout for /data seems to be EXT4 and that works correctly just posting a new topic here to see if anyone else knows the status of F2FS was it removed form OxygenOS 5 kernel?
Click to expand...
Click to collapse
By default, OxygenOS (OOS) comes with File Based Encryption (FBE) enabled. FBE, at present, is not compatible with F2FS and hence OnePlus has the /data partition defaulting to EXT4.
If you wish to use F2FS on /data, you'd need to be decrypted, a. and b. you'd need a kernel that supports booting with F2FS as well. Also, I'm not sure but I think the latest TWRPs for OP5 also don't have the necessary stuff to convert the filesystem to F2FS, but I haven't checked that myself, so can't say that with certainty.

How to Change Ext4 to F2FS?

Hello!
Can anyone explain how can i change file system ext4 to f2fs?
i've tried so many ways but none works which recovery use?? there is a global steps to do that? i always got a few errors... like: unable to mount internal storage... failed to mount '/data' (no such device), unable to recreate /data/media folder... etc
i'm on stock rom atm.. what are the steps to change ext4 to f2fs without any error?
thank you in advance
After changing ext4 to f2fs I needed an extra zip file to flash on my mi8..after installing a custom rom...I reed nothing about it on xda forems...for the mi a1....so who has the answers?

Categories

Resources