Related
Hi there,
I've seen all the posts about formatting the sd card with the ext3 filesystem, but i would like to know if there is a way to modify the root filesystem to be ext as well?
I know this is probably a daunting task, but im willing to learn and want to jump into android headfirst. Any suggestions would be appreciated. Thanks!
Sent from my SAMSUNG-SGH-I897 using XDA App
That's basically what Voodoo does, except it uses ext4 not 3. No such thing yet for Froyo unfortunately.
Well this may be OCD of me , but I like knowing the file system isn't some virtual filesystem. I'm still learning advantages and disadvantages of different file systems, but I know that FAT (or RFS) is horrible.
It sounds like I'd need to write my own ext4 driver, flash a kernel with that driver, make a partition on the main 1GB internal memory as ext4, and install the ROM over that. Am I missing anything, or does that sound right? And if that is right, are there resources on how to do that task?
Thanks so much, everyone!
sigmaelectric87 said:
Well this may be OCD of me , but I like knowing the file system isn't some virtual filesystem. I'm still learning advantages and disadvantages of different file systems, but I know that FAT (or RFS) is horrible.
It sounds like I'd need to write my own ext4 driver, flash a kernel with that driver, make a partition on the main 1GB internal memory as ext4, and install the ROM over that. Am I missing anything, or does that sound right? And if that is right, are there resources on how to do that task?
Thanks so much, everyone!
Click to expand...
Click to collapse
first of all, you need to start out with source for 2.2, which is not available yet....so everything else is pretty much not going to happen until source is available. there are couple of 2.1 kernels that have already been built and they work pretty well.
**EDIT**
and source has been released for the i9000. we are close now
----- Announcements -----
The poll is now being treated as closed. As such, since I would be unlikely to look back after moving to a newer Ubuntu, and since the two efforts are effectively incompatible (unless I wanted to try my hand at flashing a new /osh which... no), I'm concluding that there are enough users who are happy enough staying on Ubuntu 9.04 that I'll work on the union filesystem first before moving on to newer versions of Ubuntu.
----- Your regularly scheduled post below. -----
I believe I'm getting close to having a reasonable "first pass" of having a working Ubuntu on the Atrix. The interesting question becomes: what next? There are two steps I can see right now:
Get a FUSE kernel module working so that we can get a union mount for our modified Linux so that we can have more effective space. Note: this process is almost guaranteed not to work with the next option.
Now that source code is available for the Ubuntu files (I need to find out if we have everything we need, mind you), port newer releases of Ubuntu (starting with either 9.10 or 10.04).
Users, what would you like to see? The numbers at "closing" were 48/47/3.
i think it would be cool to see a 10.04 ubuntu - but what can be done with that without very much effective space? if you could find a way to expand the storage with an ubuntu port (even if it's after you port ubuntu, then find a way to increase storage) i think that makes more sense than trying to improve the inherently crippled current webtop setup
It would be great to see more storage! That is the biggest limitation at this point..
im all for 10.04 or 10.10
Wouldn't you require more space for this though?
seven2099 said:
Wouldn't you require more space for this though?
Click to expand...
Click to collapse
Not really. Remember that the 1 GB filesystem file is a copy of the partition that Motorola ships. Upgrading would be swapping out Ubuntu 9.04 packages for Ubuntu x.yy packages, so it would be a matter of trading space, not strictly losing it.
Sogarth said:
Not really. Remember that the 1 GB filesystem file is a copy of the partition that Motorola ships. Upgrading would be swapping out Ubuntu 9.04 packages for Ubuntu x.yy packages, so it would be a matter of trading space, not strictly losing it.
Click to expand...
Click to collapse
Forgive my stupidity but... you are reffering to the 1gb file called Ubuntu.disk right?
Meaning, I can move that to SD to leave more space internally?
seven2099 said:
Forgive my stupidity but... you are reffering to the 1gb file called Ubuntu.disk right?
Meaning, I can move that to SD to leave more space internally?
Click to expand...
Click to collapse
I'm pointing out that ubuntu.disk is 1 GB, but once it's created, it has no reliance on /osh. So as long as the Ubuntu x.yy installation is < 1 GB like the current 9.04 installation is, the space issue won't get any worse. No better, though.
And, no, moving ubuntu.disk to /mnt/sdcard won't work. If it did, I would have created a partition on the SD card to start with.
NUKE webtop and make it run ubuntu Pure ubuntu with the option to show it on the atrix screen too HEHE !
union mount! Also I bet this has non-ubuntu implications (internal and sd card as 1 mount point would be hot). Also why do we need a newer version other than to say "i have ubuntu x now which version number is greater than y was". What features are there in 10 over 9?
tical2k said:
Also why do we need a newer version other than to say "i have ubuntu x now which version number is greater than y was". What features are there in 10 over 9?
Click to expand...
Click to collapse
I dunno. Minor things like Firefox 4, chromium browser, stuff like that.
once again... what was wrong with firefox 3 other than 4 > 3? just being the devil's advocate here.
tical2k said:
once again... what was wrong with firefox 3 other than 4 > 3? just being the devil's advocate here.
Click to expand...
Click to collapse
You're asking somebody who's typing this from IE9, so I can't help you there. But, interest seems high, and it is true that newer software isn't available as easily for older versions of the operating system.
Would it be possible to move it to SD card if there was an ext2 partition there? For example, on my 16gb SD card, have a 14gb fat32 partition, then a 2gb ext2 partition, with your mod mounting the latter instead of a file on /data.
I started playing with this idea yesterday, but ran out of time before I got it to mount properly in Android... Do you think it's feasible?
Sent from my MB860 using XDA App
lindsaytheflint said:
Would it be possible to move it to SD card if there was an ext2 partition there? For example, on my 16gb SD card, have a 14gb fat32 partition, then a 2gb ext2 partition, with your mod mounting the latter instead of a file on /data.
I started playing with this idea yesterday, but ran out of time before I got it to mount properly in Android... Do you think it's feasible?
Click to expand...
Click to collapse
From the been there, done that file, no, it's not feasible at this point in time. Sorry.
..................
Sogarth said:
From the been there, done that file, no, it's not feasible at this point in time. Sorry.
Click to expand...
Click to collapse
Ah I see... What about symlinking a whole lot of stuff over to /cache, since it's a 600mb partition doing not much? I'm guessing you've probably tried that avenue too?
Sent from my MB860 using XDA App
molotof said:
NUKE webtop and make it run ubuntu Pure ubuntu with the option to show it on the atrix screen too HEHE !
Click to expand...
Click to collapse
Actually, here's a question: based upon a link another user pointed out, the other Linux loaders use VNC to display the Linux desktop on their Android screen. That's not enough?
lindsaytheflint said:
Ah I see... What about symlinking a whole lot of stuff over to /cache, since it's a 600mb partition doing not much? I'm guessing you've probably tried that avenue too?
Click to expand...
Click to collapse
No, actually, since the initial idea didn't involve use FUSE to be able to do crazy filesystem tricks. I thought /cache was needed, though? If we can find space here and there, it might be possible to decrease the footprint in /data a bit so that people aren't squeezed so tightly on space.
Sogarth said:
No, actually, since the initial idea didn't involve use FUSE to be able to do crazy filesystem tricks. I thought /cache was needed, though? If we can find space here and there, it might be possible to decrease the footprint in /data a bit so that people aren't squeezed so tightly on space.
Click to expand...
Click to collapse
/cache is only used for temp downloads (market apk installs, email attachment previews, etc) and OTA updates. The temp downloads don't take up much space - less than 50mb usually, but the OTA updates would probably be a a bit bigger. But who uses those right?
I'm one of those greedy people who have over 1gb of junk on their /data partition
Is there a way to dualboot roms?
Sent from my GT540 using Tapatalk
I really know nothing about dualbooting but i don't think the optimus swift has the guts for it
No.
someone correct me if i
am wrong, but our phones can't dualboot.
It could be possible by creating new partitions. For example, have two system partitions and two data partitions. We can flash one boot.img to the boot partition for the ROM to automatically boot, and flash another to the recovery partition. So when you hold home, it will boot into the second boot.img instead.(recovery images are exactly the same as boot images but with a modified ramdisk that runs the recovery program)
Where in the second boot.img, we can modify the init.rc file to mount a different partition as /system (a data2system rom works sort of like this, init.rc is modified so the data partition is mounted as /system, and system is mounted to /data, this is how you get more space as data is stored on /system, but Android thinks its acessing the data partition, where it is really accessing system) We can use this principle to dual boot.
Now, how will this work. Somehow split the system and data partitions into two bits (2 system partitions and 2 data) If we have the 1st ROM on the original system partition, and use its original boot.img, and then have the 2nd rom on the different system partition, and modify the ramdisk to use the different partitions as /system and /data, we could have a working dual boot.
However, there are some problems.
1. Our device has a NAND that is 512MB in size. It is split into:
Boot
Recovery
System
Userdata
Cache
and some other miscellaneous partitions. System is 250MB in size, and data is 134MB (under stock partition sizes) These split would barely fit any rom on it and hardly any data either. Maybe if the device had 1GB ROM, it may be different.
2. It may require some bootloader tweaking to create these new partitions, and for the device to recognise them.
Also, why would you want to dual boot your phone anyway? You have a computer for that
App
There is this app named BootManager
I've tried it out but this can't backup the boot partition. It's currently not supported. Maybe someone could try it out.
Keep in mind that it needs to be purchased for 'LEGAL' use.
jhonnyx1000 said:
There is this app named BootManager
I've tried it out but this can't backup the boot partition. It's currently not supported. Maybe someone could try it out.
Keep in mind that it needs to be purchased for 'LEGAL' use.
Click to expand...
Click to collapse
I tried that! Gives an error when backing up boot image!
Sent from my GT540 using Tapatalk
effortless. said:
Also, why would you want to dual boot your phone anyway? You have a computer for that
Click to expand...
Click to collapse
Actually I don't
Sent from my GT540 using Tapatalk
It is possible to dualboot. A russian guy already made it for us. It was meant to dualboot 2.1 and 2.2 but that rom has never made it to beta stadium.
The idea is that a second rom is stored on the sd card. I've tried to get it working but i didnt succed. But it should work.
It was on 4pda.ru. when i am on my computer, i will post a link.
Joost
Sent from my GT540 using Tapatalk
Couldn't we use the same principal as running Ubuntu chroot? As I thought chroot and loop devices where originally for HTC to test builds? Correct me if I'm wrong here
But I always thought if you had say a 32gb SD you could have 2 or 3 roms plus a couple Linux distros running on the device through chroot not same time obviously device would handle 2 max?
Also I was looking at a article to run native Linux on the eee pad transformer it looked like all they did was swap the boot.img or some kind of script so it ran off the SD card straight away. So my question would be could you add a feature to recovery that would allow you to change boot.img or script for each rom/distro then reboot straight into it making the device multi boot?
Sent from my GT540RR using XDA App
This is the topic about the dualboot, with download links to the 'dualboot' boot, and some explanation about the partitions on the sdcard.
http://4pda.ru/forum/index.php?showtopic=200838
Joost
liamwilli said:
Is there a way to dualboot roms?
Sent from my GT540 using Tapatalk
Click to expand...
Click to collapse
This should be possible. But, would require customizing boot.img and boot loader.
ErnuB said:
I really know nothing about dualbooting but i don't think the optimus swift has the guts for it
Click to expand...
Click to collapse
effortless. said:
It could be possible by creating new partitions. For example, have two system partitions and two data partitions. We can flash one boot.img to the boot partition for the ROM to automatically boot, and flash another to the recovery partition. So when you hold home, it will boot into the second boot.img instead.(recovery images are exactly the same as boot images but with a modified ramdisk that runs the recovery program)
Where in the second boot.img, we can modify the init.rc file to mount a different partition as /system (a data2system rom works sort of like this, init.rc is modified so the data partition is mounted as /system, and system is mounted to /data, this is how you get more space as data is stored on /system, but Android thinks its acessing the data partition, where it is really accessing system) We can use this principle to dual boot.
Now, how will this work. Somehow split the system and data partitions into two bits (2 system partitions and 2 data) If we have the 1st ROM on the original system partition, and use its original boot.img, and then have the 2nd rom on the different system partition, and modify the ramdisk to use the different partitions as /system and /data, we could have a working dual boot.
However, there are some problems.
1. Our device has a NAND that is 512MB in size. It is split into:
Boot
Recovery
System
Userdata
Cache
and some other miscellaneous partitions. System is 250MB in size, and data is 134MB (under stock partition sizes) These split would barely fit any rom on it and hardly any data either. Maybe if the device had 1GB ROM, it may be different.
2. It may require some bootloader tweaking to create these new partitions, and for the device to recognise them.
Also, why would you want to dual boot your phone anyway? You have a computer for that
Click to expand...
Click to collapse
Your idea is right and would work but we can't afford to loose the recovery. It's important when modding. Unlike fastboot or KDZ modes, using recovery leaves one partition untouched. ie, when using recovery, the recovery partition is never modified. It doesn't touch boot loader either. It's almost impossible to brick a phone using recovery. And, if something goes wrong with other partitions, you can always boot into recovery and have stuff restored or fixed with an update.
jhonnyx1000 said:
There is this app named BootManager
I've tried it out but this can't backup the boot partition. It's currently not supported. Maybe someone could try it out.
Keep in mind that it needs to be purchased for 'LEGAL' use.
Click to expand...
Click to collapse
It's an HTC only app. It's an xda project. You can get it for free. Hit on to http://forum.xda-developers.com/showthread.php?t=1184173
joostvhoek said:
It is possible to dualboot. A russian guy already made it for us. It was meant to dualboot 2.1 and 2.2 but that rom has never made it to beta stadium.
The idea is that a second rom is stored on the sd card. I've tried to get it working but i didnt succed. But it should work.
It was on 4pda.ru. when i am on my computer, i will post a link.
Joost
Sent from my GT540 using Tapatalk
Click to expand...
Click to collapse
Thanks. Would love to try it out.
Danzano said:
Couldn't we use the same principal as running Ubuntu chroot? As I thought chroot and loop devices where originally for HTC to test builds? Correct me if I'm wrong here
But I always thought if you had say a 32gb SD you could have 2 or 3 roms plus a couple Linux distros running on the device through chroot not same time obviously device would handle 2 max?
Also I was looking at a article to run native Linux on the eee pad transformer it looked like all they did was swap the boot.img or some kind of script so it ran off the SD card straight away. So my question would be could you add a feature to recovery that would allow you to change boot.img or script for each rom/distro then reboot straight into it making the device multi boot?
Sent from my GT540RR using XDA App
Click to expand...
Click to collapse
chroot is not a real dual boot solution. It's based on the idea of virtualization and so it has performance issues on a low end phone like GT540. When using chroot, parts of the Android OS as well as the other OS is run at the same time. This would be idea only in faster devices with more RAM.
And, yes, if you can modify the boot.img or recovery.img to boot into other partitions, it would be awesome. The beauty of linux is that you can directly mount images as a disk unlike in Windows where you need a separate software. Due to this, mounting a different partition would be easy but modifying the boot.img or bootloader is the risky part. If you do it wrong, your phone may get permanently bricked.
joostvhoek said:
This is the topic about the dualboot, with download links to the 'dualboot' boot, and some explanation about the partitions on the sdcard.
http://4pda.ru/forum/index.php?showtopic=200838
Joost
Click to expand...
Click to collapse
Thanks
joostvhoek said:
This is the topic about the dualboot, with download links to the 'dualboot' boot, and some explanation about the partitions on the sdcard.
http://4pda.ru/forum/index.php?showtopic=200838
Joost
Click to expand...
Click to collapse
I don't understand or talk Russian. Would anybody be kind enough to find out what modifications did he do to the boot.img and/or bootloader? If we do the same modifications, we might be able to dualboot.
But, there's one problem, the boot.img is not same for all versions. Maybe that is why you can't dual boot.
It wouldn't work on the gt540. We have a dual boot for the defy which has only 90mb of ram left Max when running dual system. Usually I'm running 190mb ram on stock and 240mb on miui. Major slow down on dual boot. So no point
Sent from my MB525 using xda premium
keewanchoapsss said:
It wouldn't work on the gt540. We have a dual boot for the defy which has only 90mb of ram left Max when running dual system. Usually I'm running 190mb ram on stock and 240mb on miui. Major slow down on dual boot. So no point
Sent from my MB525 using xda premium
Click to expand...
Click to collapse
You are talking about chroot. In real dual boot, only one OS is loaded.
nibras_reeza said:
I don't understand or talk Russian. Would anybody be kind enough to find out what modifications did he do to the boot.img and/or bootloader? If we do the same modifications, we might be able to dualboot.
But, there's one problem, the boot.img is not same for all versions. Maybe that is why you can't dual boot.
Click to expand...
Click to collapse
Oh I'll be looking into this one tomorrow, I'd like to be able to have a dual boot... this would enable me to store testing roms onto sdcard and boot into them "safely" without forever having to go through backup & restore each time...
If I can crack it... I'll post it!!
Edit: I don't read Russian either... but I can reverse engineer things like this! -- Just had a brief look at it... I should be able to port his modifications over to another image, but as you said... it'll only work if both OS's are compatible with the one boot.img ... and this could take some trial and error.
Second Addition: Not to mention... it could cause issues for some people that use ext partition on sdcard for apps.... hmmz, will have to keep that in mind. (People like me ya'see lol)
olite said:
Oh I'll be looking into this one tomorrow, I'd like to be able to have a dual boot... this would enable me to store testing roms onto sdcard and boot into them "safely" without forever having to go through backup & restore each time...
If I can crack it... I'll post it!!
Edit: I don't read Russian either... but I can reverse engineer things like this! -- Just had a brief look at it... I should be able to port his modifications over to another image, but as you said... it'll only work if both OS's are compatible with the one boot.img ... and this could take some trial and error.
Second Addition: Not to mention... it could cause issues for some people that use ext partition on sdcard for apps.... hmmz, will have to keep that in mind. (People like me ya'see lol)
Click to expand...
Click to collapse
People who use ext for moving apps shouldn't face problems. Android is not Windows. =P It can handle unlimited number of partitions. Looking at the guide, I could understand that the method uses multiple ext partitions. People using sd-ext for apps would only need to increase the mtdblockn(where n is a number) by 1 or 2 if using swap as well.
Yup. Both OSs will work only if the boot.imgs are compatible. That means we might not be able to run 1.6 and 2.3. However, this wouldn't be applicable if you can loop the boot.imgs as well.
ie a setup likes.
BOOT has a GRUB like boot loader which is compatible with Android is SYSTEM.
SYSTEM partition has one OS.
Then, there will be different BOOT and SYSTEM is each of the sd-ext partition or they will be stored as imgs in SD.
When device boots, it will enter BOOT. Then, this will present a menu which will allow you to select OS. If you choose, default, it will load SYSTEM from phone. If you choose another, it will loop to a BOOT from the SD-ext which will loads its relevant SYSTEM from SD/SDEXT.
That's just my idea though. Basically, if you can get an idea of the modifications that need to be made to BOOT.img to loop mount another partition as BOOT or SYSTEM, then the problem is 80% solved.
nibras_reeza said:
People who use ext for moving apps shouldn't face problems. Android is not Windows. =P It can handle unlimited number of partitions. Looking at the guide, I could understand that the method uses multiple ext partitions. People using sd-ext for apps would only need to increase the mtdblockn(where n is a number) by 1 or 2 if using swap as well.
Click to expand...
Click to collapse
lol, yer I worded that wrong... I meant it *could* be a problem if they just followed his guide steps (since it doesn't account for existing use of ext on sdcard), but you'r right this isn't really a problem... it just requires an additional partition. Also, I'd probably change the partition layout instead so that applications such as Link2SD would still be able to "automatically" (it only checks partition #1) locate the ext partition intended for apps.
Something like this...
Partition #0: FAT32
Partition #1: EXT2/3 <-- sd-ext2
Partition #2: EXT2/3 <-- data
Partition #3: EXT2/3 <-- system
Partition #4: SWAP
This would allow most internal OS's to continue to function as per normal without any script modifications.
(Most swap mount scripts are just blind scripts, they simply try mounting each partition from #1 to #9 as swap... so swap location shouldn't be an issue)
#!/system/bin/sh
#
# find and enable swap
#
echo 30 > /proc/sys/vm/swappiness
# find swap partition
for PART in `seq 0 9`;
do
swapon /dev/block/mmcblk0p$PART
if [ $? = 0 ]; then
break
fi
done
Click to expand...
Click to collapse
nibras_reeza said:
That's just my idea though. Basically, if you can get an idea of the modifications that need to be made to BOOT.img to loop mount another partition as BOOT or SYSTEM, then the problem is 80% solved.
Click to expand...
Click to collapse
And a damn good one at that... sadly I think this might just be a lil bit out of my reach... for now! While I should be able to get it to work for 2.1-2.3 (Since they essentially use the same boot), I honestly don't know where to begin with boot looping (I understand the concept yes, just not sure how to implement it... wonder if I can bake a grub version for this...)
This idea is really exciting. I wish i could help but as it stands, based on my extreme lack of know-how, i'd be as much help as a sack of potatoes XD
Sent from my GT540 using XDA App
olite said:
lol, yer I worded that wrong... I meant it *could* be a problem if they just followed his guide steps (since it doesn't account for existing use of ext on sdcard), but you'r right this isn't really a problem... it just requires an additional partition. Also, I'd probably change the partition layout instead so that applications such as Link2SD would still be able to "automatically" (it only checks partition #1) locate the ext partition intended for apps.
Something like this...
Partition #0: FAT32
Partition #1: EXT2/3 <-- sd-ext2
Partition #2: EXT2/3 <-- data
Partition #3: EXT2/3 <-- system
Partition #4: SWAP
This would allow most internal OS's to continue to function as per normal without any script modifications.
(Most swap mount scripts are just blind scripts, they simply try mounting each partition from #1 to #9 as swap... so swap location shouldn't be an issue)
And a damn good one at that... sadly I think this might just be a lil bit out of my reach... for now! While I should be able to get it to work for 2.1-2.3 (Since they essentially use the same boot), I honestly don't know where to begin with boot looping (I understand the concept yes, just not sure how to implement it... wonder if I can bake a grub version for this...)
Click to expand...
Click to collapse
Porting grub eh? Hmm. I believe there should be an ARM version for grub but we might have trouble with the drivers and kernel. It might be a better idea to copy the menu layout from CWM recovery. The menu need not be intelligent.
As for me, I also don't know how to loop the boot images.
daggerxXxsin said:
This idea is really exciting. I wish i could help but as it stands, based on my extreme lack of know-how, i'd be as much help as a sack of potatoes XD
Sent from my GT540 using XDA App
Click to expand...
Click to collapse
You could always risk your phone for others by using the pre-alpha. xD
Porting grub eh? Hmm. I believe there should be an ARM version for grub but we might have trouble with the drivers and kernel.
Click to expand...
Click to collapse
We wouldn't need a kernel for GRUB, as GRUB loads the kernel. We would have to modify the bootloader (or MBR) to use GRUB.
Does anyone out there know what causes 4EXT CWM and Amon Ra all (with custom tools) all to fail in regards to seeing a formatted cache partition on EXT-2.
I have DONE EVERYTHING I can possibly think of, from using Gpart in Ubuntu, to the phone itself. Many times in the past I have made it would just leave my 2 Gig cache partition empty because NOTHING works EVER!...
Did I miss something, can you even have 4 separate functional partitions with the Nexus 1 ?
The closest I have come to something really functional is with 4EXT, it seems to go through all the stages but when I check alignment I only get the first 2 partitions (fat-32 and EXT-1) EXT-2 says it is unformatted for some odd reason! This has been performed using a full card wipe on an external source. Even still everything is seems to go as planned until I check the card. With 4EXT I attempt to force a ext3 or 4 format and it restarts the recovery ! When I check A2SDGUI it says I only have 15 megabytes for cache.
I have used black rose and set it to 220/15/201 (dla5244), tried the latest versions of 4EXT and wasted many hours before posting...
CAN ANYONE HELP !!
Download SD Formatter from here, run the program and choose under Options:
FORMAT TYPE: FULL (OverWrite)
FORMAT SIZE ADJUSTMENT: ON
This will format your µSD (be sure to backup your important stuff). When finished, try to make an ext4 partition with 4EXT recovery. You only need one ext4 partition (so no 2nd) and no swap.
Thank you for the fast response but I have tried that. Except I want this phone to work optimally and I have figured everything else out so it is hard to settle for mediocrity. I mean I know that 1 SD-EXT partition works... Even 1 + fat32 and SWAP but I can NEVER have the phone identify the SD-EXT2 partition... no matter what... In partition magic (terrabyte bootit) and of course Gpart in Ubuntu all indicate that everything is great. Except the phone doesn't use the partition and like I was saying before the 4EXT shows it as unformatted after it's format. When I force a format on the partition the software reboots !?!... And if I leave it claiming it's unformatted even though we may think it is, QND's MIUI can only see 15 megabyte cache partition !
But then why not just go back to stock roms and one partition? To your point it's hard to step back and use something less inclined for performance when it should work ? no ?
I know I am a NOOB BUT I also know that it seems like no one out there can offer CLOSURE on the matter. like "ohh that's because the N1 cannot identify a EXT2 partition" or "ohh... that's your SD card's fault it isn't aligned right etc."
I mean I can see others have had this problem and gave up, I don't want to give up unless it is a limitation of the hardware (?sd card?)
Another way to look at it is although beautiful and helpful for most... 4EXT should be focused on getting that to work, I would think... To your point everyone is confused and shouldn't have more than 2 partitions ? Doesn't seem right to me.
Anyways if you have any other ideas OR anyone else can think of a solution lets do it I want to invest time into this and make it work !!
Sincerely! !
Why should you have more than 2 partitions on your µSD? 1 fat32 for your pictures and videos and stuff, and if you don't have enough space for your apps, 1 ext4 for A2SD (maximum 1GB).
Swap is not necessary and in fact slows your system down. A thread about swap is somewere to be found here.
And why the 2GB cache partition? You already have a 15MB cache partition on your phone.. 220/15/201.
You really don't need more than 2 partitions on your µSD.
?
I am willing to accept that you are right that it isn't needed. But I am not using A2SD, I am using XPART. According to the guides I am read, the best way is with 3 or 4 partitions (Swap being the option). The Cache partition on the other hand makes sense because even with titanium backup I can see my 60 or so apps are storing a couple hundred megs in cache. So this way a dedicated partition for processing things once instead of multiple times would provide the fastest solution. Being that the n1 is not the top performer anymore (still my fave though ), any extra speed should help when I am using my phone day to day.
The QND MIUI mod by jbbandos has the following about XPART :
"You can use it with one FAT32 and one ext4 partition, as A2SD, which seems to be the more stable setup, but the recommended setup for speed is one FAT32, one large ext4 (for your data partition), one smaller ext4 (cache), and a swap partition. I'm not that much of a fan of a swap partition, as I am always afraid it will wear out the SD card precociously, but most people report it working well, and I prefer the single ext4 for stability, but YMMV. "
you can read more here :
http://forum.xda-developers.com/showthread.php?t=1084726
.......
Anyways that is what I want, and I will invest the time to get it. I believe that 4EXT is primarily in development to perform this function. But I have a problem, with the results. I realize that it may not be necessary but I would like to know the WHY as to why this doesn't work.
AS ALWAYS thank you for you help none the less..
Never used XPART, I didn't know they recommend this. I never used apps to ext scripts longer than a few days.
This is because I'd rather install 10 crappy apps less, than having a slower system. Then again, if I would use an apps to ext script, I would definitely go for stability .
Unfortunately I don't know what you could do now..
I found my previous QND build with XPROT using blackrose was good for like 7 months !!! I just wanted to update and get it working properly. I would HIGHLY recommend it as you phone sees like 1 gig of internal mem so all apps that have widgets are useful and don't need to go to SD. In my opinion it was more stable than stock !!! Honestly, great tool.
OH yeah and it is also much faster I have found !
I've been thinking about this for a few days now. Then, today, xda posted an article on repartitioning the Xperia to gain some advantage. So it seems like a good time to pose this question for us HD+ owners.
This a "feasibility study" question. I'm not a developer. I can hardly hack my way though Mint, let alone the HD+. I'm asking if the following possible?
(If yes, maybe a nice developer will do it for us? )
Can we shrink and repartition the /factory partition in the HD+ (as they shrink partitions in the Xperia) and use the leftover space as /swap?
Background
I've been reading leapinlar's excellent treatises on the partition structure in the HD+ (see Item 16) and how the /factory partition, meant for automatic disaster recovery, doesn't do us much good if you've installed a custom ROM and a custom recovery. (See all of Item A12.)
Among other things, the /factory partition contains an image of the stock B&N ROM. Which will cause bootloops if triggered when you're running CM.
But, if I understand it correctly, the /factory partition isn't a total waste. It duplicates some important data from the /rom partition (devconf), which could come in handy IF you put the stock recovery back on in an attempt to fix your HD+. (Then it could rebuild the /rom partition if it had become corrupted.)
So, as it stands now, /factory is 448 MB that's mostly useless to us. Can't we put it to good use? Like /swap? Or direct zRAM to it?
Leapinlar has already created some repartitioning tools, as has the Xperia dev now. So I'm hoping a lot of the hard work has been done already.
Proposal
(I apologize in advance is my terminology isn't exactly correct.)
Is it possible to:
1) remove the factory.zip from the /factory partition and then shrink the partition to accommodate only the /rom backup files. (I'm thinking that all factory zips are the same size, so once the new smaller partition is calculated, it ought to be the same for everyone's HD+);
2) create a new partition from the left over space, calling it (new) partition #11;
3) format partition #11 as swap
4) easily tell CM 10 or CM 11 to use the /swap? I'm hoping this can be done with just a init.d script. (Maybe an fstab tweak too?)
5) Or perhaps dedicate #11 for zRAM, as a kernel developer has done with useless space in the Galaxy Tab 2. In essence, we'd have almost 1.5GB of RAM.
Feasible? Yes/No? I realize that dinking with partitions can damage my HD+. It's a risk I'm willing to take.
I'm not going to get involved with this, I'm just going to add a warning. The partition structure for the HD/HD+ is different than the Nook Color and most other devices. The NC and other devices like SDs use DOS partitioning. The HD/HD+ is like the Nook Tablet that uses GPT partitioning. The two partitioning schemes are not compatible. So don't try to use my tools in the NC forum. If you want to know more about GPT partitioning on the Nook Tablet and get some tools, search the Nook Tablet forum.
Sent from my BN NookHD+ using XDA Premium HD app
leapinlar said:
The partition structure for the HD/HD+ is different than the Nook Color and most other devices. The NC and other devices like SDs use DOS partitioning. The HD/HD+ is like the Nook Tablet that uses GPT partitioning. The two partitioning schemes are not compatible.
Click to expand...
Click to collapse
Good to know! Now we have more data than we had before.
Looks like a lot of the work has been done already
So, I found this thread in the xda forums all about nook tablet partitions. They even talk about resizing! (Or at least, about making a different size /userdata partition.)
There is also this here about repartitioning Nook partitions.
Looks like parted would be easier for what I'm looking to do, shrink the /factory partition and create a new partition.
I read here that I can use a live Linux CD to mount the factory.img. From there, I presume I can delete the factory.zip and create a new image?
I'm not a linux geek, but I presume I need to be on a live Mint CD to use parted in ADB? (Update: Apparently I am to use the Android SDK for ADB in Windows. Downloaded already. Am climbing the steep learning curve.)
First half of Step 1, Done
Well, it took longer than it should have, but I made a new, smaller factory7.partition.img file. It's 1 MB.
I started by booting a Mint 16 Live CD.
Then I mounted the OEM factory partition image I made beforehand using the dd command, per leapinlar's instructions. (See his Item 16.)
Code:
sudo mount -o loop partition7.factory.img {some.folder}
That image contained 4 zips: factory,zip; fsck.zip; rombackup.zip; romrestore.zip.
Dummy me, I tried deleting the factory.zip inside the mounted image. It occurred to me later that that would be like trying to delete a file from a mounted CDROM's iso image. Can't be done.
So I copied the 4 zips to a new folder. Then I could deleted factory zip, which was 433.3 MB.
That left less than 1MB for the other 3 zips.
If there's an elegant way of modifying an .img and resaving it, I couldn't find it. (I spent a lot of time with mkfs.yaffs2. But this .img was not a yaffs.(Didn't pass a "sanity check" when I tried to mount the new .img I had made with mkfs.yaffs2.)
So I brute forced an imaging solution by copying the 3 copied zips to a 1MB ext4 partiton on a USB stick. (I made the partition with gparted and used chmod 777 to clear permissions in the partition.)
Then I made an image of the new 1MB partition using the dd command. In my case
Code:
sudo dd if=/dev/sdd2 of=new.partition7.factory.img
(I probably don't have the leading /'s right here. Am truly hacking my way through all this. I'm sure most of you could do this whole project in a few minutes.)
So now I have a shiny new 1MB custom factory image just wating to be used.
Update: I think I'll redo this, and leave 4 zips, in case the recovery mechanism is looking for a "factory.zip" I'll made a dummy file and archive it, calling it "factory.zip."
The next task is to get ADB working, delete the original large partition7 in the HD+, create a new 1MB partition7 in its place, and then restore my new image to partition 7 using the dd command in reverse.
After that, then to create partition11 out of the unallocated 432MB and format that as swap.
Update: It occurs to me that I will have to backup partitions 8, 9, and 10 with dd. Then I'll have to destroy them, recreate them in new locations, and then restore them. Fortunately, an xda developer has already written the instructions on how to do all this.
I see that CM 10 supports swapon, so I'm hoping it will be downhill after the partition work. I'm hoping CM will automagically find the new swap partition, once I enable swap.
If you know different, I'd appreciate hearing from you. Will using swap in this memory burn the memory out quickly?
Better yet, swap file instead of swap partition
So, I was thinking more about this idea and how I'd have to destroy and recreate p8, p9 and p10 to make a new swap partition at p11. Aside from that being a lot of work and more prone to errors with all those operations, a new p11 would never get TRIM'd by the OS.
So now the plan is to reduce /factory (p7) to 1MB and increase /system (p8) by 443 MB. Then I'll put a swap file in /system.
Only have to work on two partitions that way and /system gets TRIM'd. (Or at least Lagfix will trim it.)
Whatdaya think?
I suppose it's easy enough to put a swap file in /data to get a feel if there's any performance gain from swap in eMMC. Someone wanna show me the code to do this? (I've read about how to create a swap file. Not sure how to mount it at emmcblk10.) Never mind, Found it on xda! Am currently running 500MB swap on /data to see what it's like.
PMikeP said:
So, I was thinking more about this idea and how I'd have to destroy and recreate p8, p9 and p10 to make a new swap partition at p11. Aside from that being a lot of work and more prone to errors with all those operations, a new p11 would never get TRIM'd by the OS.
So now the plan is to reduce /factory (p7) to 1MB and increase /system (p8) by 443 MB. Then I'll put a swap file in /system.
Only have to work on two partitions that way and /system gets TRIM'd. (Or at least Lagfix will trim it.)
Whatdaya think?
I suppose it's easy enough to put a swap file in /data to get a feel if there's any performance gain from swap in eMMC. Someone wanna show me the code to do this? (I've read about how to create a swap file. Not sure how to mount it at emmcblk10.) Never mind, Found it on xda! Am currently running 500MB swap on /data to see what it's like.
Click to expand...
Click to collapse
I guess this is a dumb question, but if you can put a swap file in /system and /data, why can't you delete the factory.zip from /factory and put the swap there? Why create a new partition?
Sent from my BN NookHD+ using XDA Premium HD app
leapinlar said:
I guess this is a dumb question, but if you can put a swap file in /system and /data, why can't you delete the factory.zip from /factory and put the swap there? Why create a new partition?
Click to expand...
Click to collapse
First, I'm abandoning my bright idea. Turns out that swap is slow (even on eMMC) and possibly destructive to the eMMC with all the writes. (Hmmm . . . I wonder how many writes /cache gets compared to a swap file? (IOW, would a swap file be any more destructive than cache is?))
There were 1 second pauses every now and then, presumably while swapping when I had a swap file mounted in /data. Even tho I could get more free memory with a swap file than with zRAM, zRAM is much faster. And since zRAM is supported by the OS, it's the path of least resistance for me.
But to answer your question, it's not a dumb question. I'm a dumb user.
First, I don't know how to mount the /swap on the /factory partition. Can it be done? I don't see /factory in root explorer when running. Whereas I can see /system and /data. (So, to use Windows talk, it seems like /factory is "hidden" when running the OS?) By the same token, I don't know if I can delete the factory.zip from /factory in situ. If it can be done, it probably requires ADB and fastboot (?). But I haven't learned about those yet. So I'd have to use my new image trick, from my post above, to "delete" factory.zip from /factory.
Second, even if I could mount a swap in /factory, I don't think I'd want to. (Although I agree it's be a lot easier (and less dangerous) than deleting and recreating partitions.) I don't think /factory gets TRIM' by the OS. And I presume I would want it TRIM'd every now and then or else the swap would get slower over time than it already is.
I notice that Lagfix offers to trim /system and /data (and /cache). But not /factory. As above, if /factory is not visible during operation of the OS, that would be one reason why Lagfix doesn't trim it.
Or it could simply be that Lagfix doesn't see the need to trim /factory. Since /factory is supposed to be static, there wouldn't be any reason for Lagfix (or CM) to trim it.
Whether /factory can be trimmed with the fstrim command while running, I don't know.
Anyway, my idea for swap wasn't such a good idea. So I've abandoned the idea.
It still bugs me, as an engineer who compulsively tries to optimize everything, to carry that wasted 443 MB around in /factory.
I don't think we need an extra 443 MB in /system or /data. (Or /cache.) But if we ever do, we know where to find it.
/factory is not automatically mounted in stock or CM. So to get access to it you would need to mount it with a script command. And I would assume you need script commands to set up /swap so that should not be a problem. But /factory is formatted fat32 and /data and /system are ext4 so that might interfere too.
And manual trim commands can be run to trim the mounted /factory. You don't need the app lagfix to do it.
But I agree, I'm not really sure you gain anything with swap on this device.
Edit: as PMikeP pointed out to me in a PM, I was mistaken. /factory is ext4, not fat 32. Thanks for the correction. That should make it easier.
Sent from my BN NookHD+ using XDA Premium HD app