I did a search but couldn't find anything specific... so my question is, should I upgrade my ext3 to ext4? if so why? if not.. also why
gmelchert said:
I did a search but couldn't find anything specific... so my question is, should I upgrade my ext3 to ext4? if so why? if not.. also why
Click to expand...
Click to collapse
No. Most (all?) of the new 2.1 test build leak based ROMs do no support a2sd on ext4. On (most of) these same builds ext3 works automatically.
danknee said:
No. Most (all?) of the new 2.1 test build leak based ROMs do no support a2sd on ext4. On these same builds ext3 works automatically.
Click to expand...
Click to collapse
thanks thats good to know!
I know most of you are not Linux users so let me break this down for you:
EXT2: Very basic filesystem when it comes down to it -- think of it as a Unix filesystem you could place inbetween the likes of FAT32 and NTFS. I would nearly argue that this is the modern equivalent of FAT32 (which really really needs to die). We really shouldn't be using FAT32 but lack of native windows compatibility stops EXT2 from being a candidate for this usage.
EXT2 is highly recommended for your flash card. It won't over stress it and there aren't many alternatives that are better these days unless you're dealing with raw flash, which you'd then use something like YAFFS2 or JFFS2. The flash in compact flash cards is not raw flash.
EXT3: Picture EXT2 with a journal. It is backwards compatible with EXT2 (just doesn't read the journal).
A journal is NOT recommended for flash devices. (At least when the filesystem was not designed for raw flash and isn't tuned properly like YAFFS2 and JFFS2). Do you really want your phone to write all the metadata to the journal first and then to the filesystem? That's a ton of unnecessary I/O. If it has full journaling enabled you're writing all your data twice. This is not a good idea for your phone. This is one reason why NTFS has not become a standard for flash devices: Journals on flash are bad unless it's designed for flash from the ground up.
EXT4: same as EXT3 but is a copy-on-write FS with delayed allocation (holds data in memory longer before writing to disk to be more efficient / prevent fragmentation), increased number of files and size of files (more than a phone ever could need in our lifetime), etc. Some improvements across the board but not backwards compatible with EXT3 anymore if you're using the delayed allocation. Most likely to eat more memory on your phone.
This is completely unnecessary for a phone and really does not fit your needs. I don't understand why anyone would attempt to use this unless they simply thought "4 is bigger than 2 or 3 so it must be better!"
So there you have it. I may have forgotten a minor detail here or there, but this is the gist of it.
feld said:
I know most of you are not Linux users so let me break this down for you:
EXT2: Very basic filesystem when it comes down to it -- think of it as a Unix filesystem you could place inbetween the likes of FAT32 and NTFS. I would nearly argue that this is the modern equivalent of FAT32 (which really really needs to die). We really shouldn't be using FAT32 but lack of native windows compatibility stops EXT2 from being a candidate for this usage.
EXT2 is highly recommended for your flash card. It won't over stress it and there aren't many alternatives that are better these days unless you're dealing with raw flash, which you'd then use something like YAFFS2 or JFFS2. The flash in compact flash cards is not raw flash.
EXT3: Picture EXT2 with a journal. It is backwards compatible with EXT2 (just doesn't read the journal).
A journal is NOT recommended for flash devices. Do you really want your phone to write all the metadata to the journal first and then to the filesystem? That's a ton of unnecessary I/O. If it has full journaling enabled you're writing all your data twice. This is not a good idea for your phone. This is one reason why NTFS has not become a standard for flash devices.
EXT4: same as EXT3 but includes is a copy-on-write FS with delayed allocation (holds data in memory longer before writing to disk to be more efficient / prevent fragmentation), increased number of files and size of files (more than a phone ever could need in our lifetime), etc. Some improvements across the board but not backwards compatible with EXT3 anymore if you're using the delayed allocation.
This is completely unnecessary for a phone and really does not fit your needs. I don't understand why anyone would attempt to use this unless they simply thought "4 is bigger than 2 or 3 so it must be better!"
So there you have it. I may have forgotten a minor detail here or there, but this is the gist of it.
Click to expand...
Click to collapse
Nice explanation.
You left out the part about how apps load faster from RAM then they do from any sd card. The people running slower sd cards especially may potentially be experiencing a performance decrease due to a2sd.
I have abandoned a2sd because after I load every app that I use, (plus 10 random ones) I still have room left. Then I use the extra half a gig on my sd card for another 5 cds worth of music.
feld said:
I know most of you are not Linux users so let me break this down for you:
EXT2: Very basic filesystem when it comes down to it -- think of it as a Unix filesystem you could place inbetween the likes of FAT32 and NTFS. I would nearly argue that this is the modern equivalent of FAT32 (which really really needs to die). We really shouldn't be using FAT32 but lack of native windows compatibility stops EXT2 from being a candidate for this usage.
EXT2 is highly recommended for your flash card. It won't over stress it and there aren't many alternatives that are better these days unless you're dealing with raw flash, which you'd then use something like YAFFS2 or JFFS2. The flash in compact flash cards is not raw flash.
EXT3: Picture EXT2 with a journal. It is backwards compatible with EXT2 (just doesn't read the journal).
A journal is NOT recommended for flash devices. (At least when the filesystem was not designed for raw flash and isn't tuned properly like YAFFS2 and JFFS2). Do you really want your phone to write all the metadata to the journal first and then to the filesystem? That's a ton of unnecessary I/O. If it has full journaling enabled you're writing all your data twice. This is not a good idea for your phone. This is one reason why NTFS has not become a standard for flash devices: Journals on flash are bad unless it's designed for flash from the ground up.
EXT4: same as EXT3 but is a copy-on-write FS with delayed allocation (holds data in memory longer before writing to disk to be more efficient / prevent fragmentation), increased number of files and size of files (more than a phone ever could need in our lifetime), etc. Some improvements across the board but not backwards compatible with EXT3 anymore if you're using the delayed allocation. Most likely to eat more memory on your phone.
This is completely unnecessary for a phone and really does not fit your needs. I don't understand why anyone would attempt to use this unless they simply thought "4 is bigger than 2 or 3 so it must be better!"
So there you have it. I may have forgotten a minor detail here or there, but this is the gist of it.
Click to expand...
Click to collapse
I had never thought about this before. It makes a good point, flash memory dies after x ammount of Reads and Writes. Given it's mostly in the 100 millions, but it does more reading and writing than you would think it does, and you are effectivly killing the memory card twice as fast.
Good thing these things are relativly cheap.
this is all really good to know. thanks. i spent $100 on my sd card so maybe i should just foemat the whole thing to fat32.. (its class 10) while you guys are here, what exactly is the use of swap?
Sent from my HERO200 using the XDA mobile application powered by Tapatalk
gmelchert said:
this is all really good to know. thanks. i spent $100 on my sd card so maybe i should just foemat the whole thing to fat32.. (its class 10) while you guys are here, what exactly is the use of swap?
Sent from my HERO200 using the XDA mobile application powered by Tapatalk
Click to expand...
Click to collapse
SWAP = Page file in the Linux world. From what I have read (This may have changed since then) We don't have the ability to use Swap yet.
danknee said:
You left out the part about how apps load faster from RAM then they do from any sd card. The people running slower sd cards especially may potentially be experiencing a performance decrease due to a2sd.
Click to expand...
Click to collapse
You're right -- apps do load faster from RAM. However, when you're not using a2sd the applications are not on the phone in "RAM". They're in a flash chip inside the phone -- just like on your sd card. The performance should be nearly the same when you're using a2sd as it is when you're not using it.
The only reasons why a2sd should be slower are:
1) You have a cheap, slow SD card
2) The interface from the SD card to the phone is cheap and slower than the internal flash chip's interface. It was just a cheap design choice the manufacturer made.
3) The internal flash is simply faster from it being a better flash chip
feld is right. Using anything other than ext2 for the apps2sd partition boggles the mind. I have no idea why people insist on a: providing support for it and b: encouraging people to do it.
Ok, provide support for it for the people who know what they're doing/just want to do it for the hell of it, but having a journalled filesystem on an sd card makes no sense whatsoever.
As feld says ext4 uses up more RAM than ext2, which might be all well and good for things like the N1/Evo/Desire etc but not everyone has such a RAM beefy phone.
Besides that, the bottle neck in speed is the SD card/controller. No "faster filesystem" is going to improve that. Adding more IO is only going to slow things down.
Moved as not Android Development.
Related
i tried doing some searching, but didnt find what i was looking for. my question is: which linux file system(ext2,ext3,ext4) is recommended for a partition on my sd card? is one better than the other? TY
EXT2 is a fairly simple filesystem. Great for data storage, i.e., data that doesn't change very often. EXT3 adds in JOURNALING to EXT2. This makes it good for data that *does* change often -- in the event of a bad unmount (power failure, crash, etc.), it is MUCH more resistant to corruption. EXT4 has some really neat new features that make it great for storing millions of files on ENORMOUS disks. None of the EXT4 features will make any appreciable difference on a 16GB flashdisk filesystem, performance wise. Delayed allocation though, could increase the risk of DATA LOSS.
Note that ext4 is supported on community android images mainly because it is "cool and new". It is therefore the general assumption that it must be "better". It isn't, really. I suggest going with ext2 or ext3. They each present benefits and drawbacks for this application, and it is YOUR CHOICE between them.
EXT2: advantage: no journaling -- makes your flash memory last longer.
EXT3: advantage: journaling -- resists filesystem corruption.
questions go in QnA not dev
This is the DEV Thread !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Will journaled Ext4 kill my internal SD?
yuktsi said:
Will journaled Ext4 kill my internal SD?
Click to expand...
Click to collapse
Ummm...in a word, no.
Why would you think it would?
Sent from my GT-I9000 using XDA Premium App
Quick Answer: No.
Long Answer, Journaled filesystems like EXT4 have a "intent" log where they store the actions they are about to preform before they preform them, once the action is complete it is removed from the log. This is done so that if power is lost during an operation, the filesystem can "replay" the log (ie, go and check the last thing that was supposed to be done) and do it. This increases file system reliability at the cost of write speed (very slightly though) and causes more writes to your device.
That said, the increase in writes is very small and while it will wear your SD faster, we are talking about something like %1 faster which is no big deal.
Hope this helps.
edude03 said:
That said, the increase in writes is very small and while it will wear your SD faster, we are talking about something like %1 faster which is no big deal.
Click to expand...
Click to collapse
As to opposite to what? This interests me more. I thought that rfs has journaling too. So why would the journaling of the ext4 be wearing out the sd card more? Also why it should be slower in write as rfs then? (why would the system then when journaling with slower write speeds BE actually used as a "lagfix" and seen as a speed and smoothness improvement to the rfs?)
I have no idea about any of this, ask just for clarification and my laziness to google
i had Jetpackrom+sempahore 1.6 on my phone and just downlaoded CF's tweaks and currently i'm on RFS ,is it safe to convert it into ext4??
I had read some where that ext4 or some other filesystem damages our nand flash , which one's better if its safe?
They are all safe.
They all work differently and give different results.
Ext 4 is most common.. The only risk involved, Is flashing without disabling it / converting it back to RFS.
That can cause issues, Whereas Flashing with RFS wont give any troubles.
Creates a VIRTUAL EXT2 filesystem inside the stock RFS filesystem on the internal SD card, with a 4KB block size. This means that this lag fix creates a buffer between the real filesystem and the android system. This buffer should reduce the amount of disk I/O required for all operations by utilizing EXT2 buffering, as well as not writing file access times to disk, etc. It allows only 1GB for application data at this stage, down from the 2GB of application data when running stock.
Click to expand...
Click to collapse
There was a really useful thread on here a while back explaining in great detail how lagfixes actually work.
I cant seem to find it tho, Perhaps some one else may point you in the right direction,
(that above i just copied and pasted from google, it may not be much use, but there is not a lot of sites explaining it properly.... its confusing, even for me )
azzledazzle said:
They are all safe.
They all work differently and give different results.
Ext 4 is most common.. The only risk involved, Is flashing without disabling it / converting it back to RFS.
That can cause issues, Whereas Flashing with RFS wont give any troubles.
There was a really useful thread on here a while back explaining in great detail how lagfixes actually work.
I cant seem to find it tho, Perhaps some one else may point you in the right direction,
(that above i just copied and pasted from google, it may not be much use, but there is not a lot of sites explaining it properly.... its confusing, even for me )
Click to expand...
Click to collapse
That was good!
but i also wanna get a look on that thread about the lagfixes and filesystems!!
OK, so ive been searching for ages for the File-system / Lag-fix thread. But I still cannot find it lol, Its really annoying me now. I hope someone finds it for me. (unless its been deleted ???? )
Anyway upon my search for this missing masterpiece, I came across these, They may help you learn a little more about how the whole lag fix works, They may not. Who knows ?
http://forum.xda-developers.com/showthread.php?t=765822
http://forum.xda-developers.com/showthread.php?t=1178788
I think ext4 is better in many aspects....great speed feel the difference.
Sent from my GT-I9000 using XDA App
ali_khalid5518 said:
I think ext4 is better in many aspects....great speed feel the difference.
Click to expand...
Click to collapse
If you carefully read the topics here regarding the file systems ext4 and RFS you'll find, that there is no measurable difference in the latest GB ROMs anymore.
However, ext4 is by far the more modern and sophisticated file system and it's completely open source, while RFS is based on rather old fashioned and simple FAT and Samsung keeps the source closed AFAIK.
Best solution would be btrfs, but this is not regarded stable in Linux kernel. IMO the best file system so far is XFS: rock solid, stable and performing rather well even on small files. However reiserfs is much better in this aspect, but it's not further developed.
These are just my thoughts with my experience from many different Linux devices like the Openmoko freerunner for example....
Hello
I have spent sometime going through some past articles on partitioning. There are still questions in my mind. I hope someone could help me clear up this.
I gather it's good to have an external partition where it is used to store apps and cache. It is stated that optimal size for it is abut 512mb - 1G as ext3/4.
Is there in fact reason to stop me from converting the whole SD to ext3/4 and get rid of fat32 altogether? I am linux based and I really don't care much about visibility of files at all. It seems that the current ROM works with 2 partitions: one fat32 and the other as ext3/4 and we typically allot a lot more for fat32. What's the primary reason behind this decision? Would there be some system stuffs that rely on fat32 to function?
As far as sizing is concerned, I would like to have some real reasons why things have to be arranged this way (with fat32 as a dominant partner) instead of going all the way to ext4
Even if You will format Your sd-card using Your phone You will see, that it will be FAT partition as well. So it's basic partition which android use to save photos, movies and all apps keep their data folders (f.ex. sms backups, apps backups etc). Ext partition is also not recognized by PC with Windows, so there isn't any way to use it as a storage device. And I think that similar is with android - I don't think if f.ex. music player will recognize Your music files on ext partition. But it's just my opinion and I may be wrog.
Hello there! now that we have custom kernel, I want to share with you this Little trick I used in my old Motorola z6 when I used to develop xD
Due to the fact that memory cards have sometimes low data transfer rates, swapping on our devices sometimes is a Little bit slow... to solve the issue, I used to place a swapfile in the internal storage of the phone, wich has pretty fast data transfer rates... so I did this once again with my milestone, and the peformance is amazing!! I'm currently using CM7.2.4 with a 48mb swapfile placed inside /data...
Just wanted to share this with all the people of this community, I also modded the script written by FuFu, so the script insted of creating the swapfile in the sd-card, it creates it in /data
I won't post the modded script because I want FuFu himself to decide if the mod is OK, and make his own reléase! Just a matter of respect...
So that's it, try it out people, you're gonna be amazed....
no Problem, you can post your modded script here
i also tryed to use a swapfile on /data, but for me it wont work, if i try to use swapon on /data it sayes:
invalide argument
but i will take a look at your modded script and also i will include it in future updates
i think it may be very interesting for all users to get some extra performance
I'm not sure it is as good idea as it sounds first.
Memories based on flash technology are degrading when writing on it. (I know they are degrading anyway.)
Swapping means a lot of writing and reading and while you can easily buy a new SD-Card you cannot change your phone's internal memory.
Maybe my fears are baseless, but i don't wanna risk.
May someone with better knowledge correct me.
Plus, it is not possible to enable swap on yaffs filesystem "out-of-the-box" as they are incompatible.
I have CM7.2.4 now and three primary partitions on SD Card: Fat32, Ext2 and Linux Swap.
I installed 98swaponv5 after CM7.2.4 rom with OpenRecovery. Does 98swaponv5 have some settings or how I can know it's working?
Well it seems that I can multitask and change from Facebook to other apps and back and it doesn't reload, so I guess the swap is working.
But the default browser always reloads the page when I switch to the browser. Looks like all the other apps work great with the swap except the browser, I wonder why?
EDIT: Right now the browser doesn't reload anymore when I switch to it. I have rebooted and installed some apps, killed some apps. Looks like the Milestone just keeps getting better.
If you have Terminal Emulator installed, you can type free and it will show you the amount of total/used/free memory and in the row "Swap" the informations about swap.