New Storage Layout for HOX Endeavoru

Search This thread

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
New Storage Layout for HOX Endeavoru

This New Layout will change the way your phones internal memory partitions are used.
The primary goal is to get more space for your apps and data. The secondary goal is to be more compatible with new OS/software. This is obtained by using a layout similar to Nexus devices.

Two years ago pabx showed us "How to switch to a big /data partition", but at that time very few of us actually needed it. It was experimental and good Linux skills was required.

Almost one year ago Thömy proposed to use a new better storage layout for our device. We tried it and found it good (at least I did), but we were still happy with KitKat on Dalvik, so we didn't bother to publish it.

Well, now we have Lollipop and ART. And memory suddently seem very limited.
Move2SD is a must for many of us. And guess what...: Thömy refined the layout to be used for Android 5 and ... I have the pleasure to present this New Layout. So, here we go.


Before starting the process of converting your HOX to the New Layout, please make sure you have plenty of time for this.
Don't start if you are planning to use the phone in near future. Unforseen things can happen, so you may need some advice to get back on the right track.
It is very hard to brick the HOX as HTC did a good job on securing it, but we all know, s... happens.
Remember, xda is all about changes and no change is without risk.


A word of warning: Although some error situations will be prevented, it was not possible to cover all situations.
You CAN restore a backup from the wrong layout. And you may be able to loose data if you don't keep track of which layout you are using.
It is YOUR responsability to keep track of your files.
Good luck and have fun flashing.


Enough talking, let's start.

Requirements: HTC One X International. 50%+ battery. You know how to flash a recovery. You know how to flash ROM and boot.img.
To upgrade, follow these simple steps or use the detailed guides below:

Make sure your adb/fastboot is up to date and working.
Make sure you can transfer files with MTP (test before you start the transformation).
  1. Backup everything in your phone that you want to keep. This will WIPE ALL!
  2. Boot to fastboot and Install a recovery made for the New Layout. twrp2811.BiG.img will do for a start.
  3. Disconnect the phone from PC (current recovery will fail the format process if you skip this step).
  4. Format Data. This will reformat your SD Card to be used for both app-data and user storage (new SD Card).
  5. Clean out all other partitions.
  6. Restart recovery and wait for two new drives to pop up on your PC.
  7. Copy a ROM with the New Layout to the Internal SD Card or the new 2GB Extra Data.
  8. Flash the ROM (and gapps) and reboot.
  9. Go here and press the Thanks button (or even better, the button above it).

Going back to the old layout is easy:
  1. Boot to fastboot and Install an old Recovery.
  2. Change the file system of the SD Card back to FAT.
  3. Copy a ROM or a backup with old layout to SD Card. Mount USB Storage if you want to copy a backup - MTP may fail on very large files.
  4. Wipe/format everything except SD Card.
  5. Flash ROM or restore backup.
  6. Reboot to bootloader and Flash boot.img from ROM or the backup.
  7. Boot to your old system.

Whats missing ? Let me know if you find something!
Want pictures ? Look in the guides :)
Want more ? Upload it....
... and so he did... thanks @dady000 for SlimBean!

Adding New Layout to Legendary @pabx AOSP 4.2.2 >>>>>>DOWNLOAD<<<<<

All my files are now copied/moved to >>>>> Android File Host
 
Last edited:

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
FAQ

:confused:
How do I create a backup of my Old Layout?
Guide on BACKUP

:confused:
How do I switch to the New Layout?

:confused:
How do I get back to the Old Layout?
Guide on Going Back to Normal Layout


:confused:
How difficult is it to switch to the New Layout?
Awesome I will try the new layout.
... @teemo love the instruction for New big partition it is easy to follow and I don't thnk I can make a mistake unless I forget to backup my files to my computer. Thanks for the formatting over to new partition instructions.
:confused:
What if I update the ROM or if I change to a different ROM. Do I need to backup my pictures and music etc. first ?
The SD Card is now a part of the /data partition. It is actually just a directory named - /data/media
This "media" is the SD Card.
When you flash a ROM, you can wipe Dalvik, System, Cache and Data. This will not touch the SD Card.
When you select wipe Data in twrp, it does NOT format /data. It selectively delete everything on /data except /data/media
To wipe the SD Card, you need to select Internal SD Card.
prepare.png
:confused:
Show me the difference...

Partitions on the Old Layout:
Code:
#p12: 1280MB  /system
#p13:  320MB  /cache
#p14:   25GB  sdcard
#p15: 2196MB  /data
Partitions on the New Layout:
Code:
#p12: 1280MB  /system
#p13:  320MB  /cache
#p14:   25GB* /data
#p14:   25GB* /data/media = sdcard
#p15: 2196MB  /xtradata
* #p14 is 25GB that is shared between DATA and SDCARD
:confused:
Why can't we use Mass storage?

The data we want to store on the bigger partition need to be protected. The FAT system used by current sdcard does not offer any kind of protection. Linux/Android use ext4 to secure your data. This mean you can use your phone for banking, pictures, videos and other private data without worrying too much.
HTC have locked the partitions, so we cannot resize /data and sdcard.

:confused:
Can I restore from Old Layout to New Layout

Thanks to @eyosen for reminding me of this. It can make life a little easier for us:
You can restore DATA from the Old Layout to the New Layout. Do not restore the system.
Make sure the data you restore is compatible with the ROM (system) you install. Most apps may restore and work perfect, but be prepared, that there might be issues. If an app is messed up, first try to clear the apps data via Settings-Apps-"BadApp".

:confused:
I can't see the drives on PC ... I have problems with Windows drivers:

THIS guide has proven to be useful, thanks @bhushan11689

:confused:
I still have problems with Windows drivers when using twrp2834-BiG:

Try the new twrp2851-BiG, it is more friendly :)
:confused:
I cannot download to sdcard,
Pictures and Screenshot does not work,
How can I access my sdcard?

For all solutions below: Once you enter the command, you must WAIT.
It can take a while, as the command will change ownership of all your files on the sdcard.
On a fresh install it may only take a second. But if you restored a lot of files, be prepared to WAIT :)

If you use MultiRom don't do this (I am not sure, but I think it will change ownership for your secondary ROMs)

Originally Posted by Thunder07 I'd recommand
Code:
adb root
adb shell chown -R media_rw:media_rw /data/media/0/
If that didn't work, try this:
- boot into the recovery
- tap Advanced -> Terminal Command -> Select
- write carefully:
Code:
chown -R media_rw:media_rw /data/media/0/
tap Go and WAIT for the command to finish
- tap Home and reboot system

Or if you have Root Explorer or similar installed in android, you can:
- From Root Explorer navigate to /data/media
- long press the "0" folder and select Change owner
- Set Owner and Group to "1023 - media_rw" and tick "Also set on all sub-folders and files"
- hit OK and WAIT.


...to be updated...
 
Last edited:

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
Please welcome HTC Sense to the New Layout.

Converting Sense5 4.2.2 to the New Layout

Note: If you have no experience with the tools below used in this Sense-kitchen, please get familiar with the tools before starting. I will not explain usage of these.

Here is the recipe for cooking:
Code:
1. [URL="https://www.google.com/search?biw=1738&bih=1168&tbm=isch&sa=1&q=%22rom%22+%22sense%22+%224.2.2%22+%22One+X%22&oq=%22rom%22+%22sense%22+%224.2.2%22+%22One+X%22&gs_l=img.3...5327.20386.0.21299.21.21.0.0.0.0.162.2230.8j13.21.0.msedr...0...1c.1.62.img..16.5.558.jJPai_hXmeM"]ROM[/URL]
2. [URL="http://ibotpeaches.github.io/Apktool/"]apktool[/URL]
3. for linux: [URL="https://www.google.com/search?num=100&q=mkbootimage+split_boot+repack_ramdisk&oq=mkbootimage+split_boot+repack_ramdisk&gs_l=serp.3..30i10.1279477.1286274.0.1286536.7.7.0.0.0.0.393.1044.1j4j0j1.6.0.msedr...0...1c.1.62.serp..2.5.944.-8VGBiQkl8c"]mkbootimage + split_boot + repack_ramdisk[/URL]
   alternatively for windows: [URL="https://www.google.com/search?site=&source=hp&q=bootimg_tools_windows&oq=bootimg_tools_windows&gs_l=hp.3..0i13i30.8539.8539.0.8711.2.2.0.0.0.0.166.311.0j2.2.0.msedr...0...1c.1.62.hp..1.1.143.0.SW4IYGUKG_A&gws_rd=cr&ei=hav9VJm6FqjQ7AbyjYCICQ"]bootimg_tools_windows[/URL]
4. Apply The "patch"

Short instructions:
1. Edit the storage_list in the ROMs framework. Just change parameters for the sdcard.
2. Remove sdcard from vold.fstab, we fuse it in the ramdisk.
3. Update the ROMs updater-script. Pay special attention to any mmcblk0p15 entries. Change it to mmcblk0p14. Some scripts want to wipe Data (if asked), comment it away (or it will wipe data and sdcard).
4. The RAM Disk. One important point here: Use the old command for the sdcard service.

Additionally: Be aware of scripts adding "UMS features/helpers/whatever". I have currently a windows popup asking me to format "F:". This came from converting the lONElyX kernel.

The "patch":
Code:
ROM
1.
  /system/frameworks/framework-res.apk
    apktool d framework-res.apk
      frameworks-res/res/xml/storage-list.xml
        - <storage android:mountPoint="/storage/sdcard0" whatever .... />
        + <storage android:mountPoint="/storage/sdcard0" android:storageDescription="@string/storage_internal" android:primary="true" android:emulated="true" android:mtpReserve="100" />
    apktool b framework-res
      new framework will be in frameworks-res/dist
      open new framework-res.apk and
      add original META-INF and 
      replace AndroidManifest.xml with the original
2.
  system/etc/vold.fstab
    - dev_mount sdcard /storage/sdcard0 emmc /devices/platform/sdhci-tegra.3/mmc_host/mmc0
    + #dev_mount sdcard /storage/sdcard0 emmc /devices/platform/sdhci-tegra.3/mmc_host/mmc0
3.
  META-INF/com/google/android/updater-script
    - mount("ext4", "EMMC", "/dev/block/mmcblk0p15", "/data");
    + mount("ext4", "EMMC", "/dev/block/mmcblk0p14", "/data");
4.
  boot.img
    split_boot boot.img
      boot/ramdisk/init.endeavoru.common.rc
        -   # for backwards compatibility
        -   export EXTERNAL_STORAGE /storage/sdcard0
        -   mkdir /storage 0050 system sdcard_r
        -   mkdir /storage/sdcard0 0000 system system
        -   symlink /storage/sdcard0 /sdcard
        -   symlink /storage/sdcard0 /mnt/sdcard
        + on init
        +   # See storage config details at http://source.android.com/tech/storage/
        +   mkdir /mnt/shell/emulated 0700 shell shell
        +   mkdir /storage/emulated 0555 root root
        + 
        +   export EXTERNAL_STORAGE /storage/emulated/legacy
        +   export EMULATED_STORAGE_SOURCE /mnt/shell/emulated
        +   export EMULATED_STORAGE_TARGET /storage/emulated
        + 
        +   # Support legacy paths
        +   symlink /storage/emulated/legacy /sdcard
        +   symlink /storage/emulated/legacy /mnt/sdcard
        +   symlink /storage/emulated/legacy /storage/sdcard0
        +   symlink /mnt/shell/emulated/0 /storage/emulated/legacy
        +   # Our old /data partition
        +   mkdir /xtradata
          on fs
        
        +   setprop ro.crypto.umount_sd false
        +   setprop ro.crypto.fuse_sdcard true
        +
          on post-fs-data
        +   mkdir /data/media 0770 media_rw media_rw

        -   /dev/block/platform/sdhci-tegra.3/by-name/UDA \
        +   /dev/block/platform/sdhci-tegra.3/by-name/ISD \

        +   # virtual sdcard daemon running as media_rw (1023)
        +   service sdcard /system/bin/sdcard /data/media /mnt/shell/emulated 1023 1023
        +   class late_start
        #eof
        
      boot/ramdisk/init.rc
        mkdir /cache 0770 system cache
        mkdir /config 0500 root root

        + # See storage config details at http://source.android.com/tech/storage/
        + mkdir /mnt/shell 0700 shell shell
        + mkdir /mnt/media_rw 0700 media_rw media_rw
        + mkdir /storage 0751 root sdcard_r

        # Directory for putting things only root should see.
      
      boot/ramdisk/fstab.endeavoru
        - /dev/block/platform/sdhci-tegra.3/by-name/APP           /system             ext4      ro                                                                                  wait
        - /dev/block/platform/sdhci-tegra.3/by-name/UDA           /data               ext4      noatime,nosuid,nodev,noauto_da_alloc                                                wait,encryptable=/dev/block/platform/sdhci-tegra.3/by-name/DUM
        - /dev/block/platform/sdhci-tegra.3/by-name/CAC           /cache              ext4      noatime,nosuid,nodev,noauto_da_alloc                                                wait
        - /dev/block/platform/sdhci-tegra.3/by-name/RCA           /rca                ext4      noatime,ro                                                                          wait
        - /dev/block/platform/sdhci-tegra.3/by-name/RFS           /rfs                ext4      noatime,rw                                                                          wait
        - /dev/block/platform/sdhci-tegra.3/by-name/DLG           /devlog             ext4      nosuid,nodev                                                                        defaults
        + # New Layout #
        + /dev/block/platform/sdhci-tegra.3/by-name/APP  /system       ext4   ro,barrier=0                                            wait
        + /dev/block/platform/sdhci-tegra.3/by-name/CAC  /cache        ext4   noatime,nosuid,nodev,noauto_da_alloc,barrier=0          wait,check
        + /dev/block/platform/sdhci-tegra.3/by-name/RCA  /rca          ext4   noatime,rw,barrier=0                                    wait
        + /dev/block/platform/sdhci-tegra.3/by-name/RFS  /rfs          ext4   noatime,rw,barrier=0                                    wait
        + /dev/block/platform/sdhci-tegra.3/by-name/DLG  /devlog       ext4   nosuid,nodev,barrier=0                                  defaults
        + /dev/block/platform/sdhci-tegra.3/by-name/UDA  /xtradata     ext4   noatime,nosuid,nodev,nomblk_io_submit,errors=panic      wait
        + /dev/block/platform/sdhci-tegra.3/by-name/ISD  /data         ext4   noatime,nosuid,nodev,nomblk_io_submit,errors=panic      wait,encryptable=/dev/block/platform/sdhci-tegra.3/by-name/DUM

    cd boot
    repack_ramdisk ramdisk
    mkbootimg --kernel boot.img-kernel --ramdisk new-ramdisk.cpio.gz -o boot-newlayout.img
    boot-newlayout -> rom.zip/boot.img

NOTE: The "patch" below is not automatic. It must be "applied" by hand :)
 

Attachments

  • Sense5-2-NewLayout.patch.txt
    5.3 KB · Views: 915
Last edited:

chihliouma

Senior Member
Feb 3, 2008
1,711
133
Hi Teemo, thanks for the effort. The time of great change for HOX is coming eventually. OMNIROM seems new for me. Is it the same as SLIMLP ROM but with new layout or it's a totally new LP ROM ? One more question, will the other ROM makers follow this new layout as well ? Thanks.
 

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
Omnirom is Omnirom :)
This is the first preview of lollipop onOmni. Very young, but with potential.
I hope other ROMs will follow, Thömy did all the work on the design, I just made the recovery and the guide. So I assume CM will join.
Time will tell if there is a need for it. It's all up to the users.
 

lalit387

Senior Member
Jan 29, 2012
1,663
757
Delhi
Finally we got it.

Thanks buddy

Do we need new layout for Omni?
 
Last edited:

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
Would appreciate an old layout Omni compilation, if possible:p

Should be possible. Maybe @audahadi can point me to the latest good KitKat Omni build. It may take a while though, as I do have a lot of other stuff to look at. But if everything is setup and ready to pick from github, I can give it a try.
Of course audahadi is more than welcome to do it, if time and energy permit it :angel:
 
  • Like
Reactions: lalit387

chihliouma

Senior Member
Feb 3, 2008
1,711
133
Yes, absolutely ;)
Omni is PREview. No wifi yet. No update schedule at the moment, but seem stable and have some nice options.
Just thought we should have some options to start with. SlimLP should join soon.

Thanks Teemo for more information. But I guess wifi is critical for the ROM. Hope that can be resolved soon.
 

mattspew

Senior Member
Any ideas how long it will take to format?

I started it then realised there isn't a complete enough or stable enough ROM that supports the layout. I'm planning on going straight back to the original layout and reinstalling Resurrection Remix LP.

Can I just jump back to fastboot and restore the layout, or do I need to wait for this format the finish?
Or can I use any old ROM with this layout and it just won't use the extra space?
 
Last edited:

teemo

Senior Member
Nov 18, 2007
2,430
2,315
Kolding
Any ideas how long it will take to format?

I started it then realised there isn't a complete enough or stable enough ROM that supports the layout. I'm planning on going straight back to the original layout and reinstalling Resurrection Remix LP.

Can I just jump back to fastboot and restore the layout, or do I need to wait for this format the finish?
Or can I use any old ROM with this layout and it just won't use the extra space?

You cannot use the old ROM.

SlimKat 9.0 is very complete and works great on this layout. It is in the first post.

Formating only take a few seconds. Follow the guide exactly. If you forget to disconnect the USB cable, it will never finish.

Edit: yes, you can go to fastboot and install the old recovery, no problem.
 
Last edited:

mattspew

Senior Member
You cannot use the old ROM.

SlimKat 9.0 is very complete and works great on this layout. It is in the first post.

Formating only take a few seconds. Follow the guide exactly. If you forget to disconnect the USB cable, it will never finish.

Edit: yes, you can go to fastboot and install the old recovery, no problem.

Thanks, but I'm looking for a LP ROM that's a close to stock as possible, so I've restored the layout and reinstalled Resurrection Remix LP v5.3.3.
Yep, I'd forgotten to disconnect the USB cable.. Oooops.

I hope Resurrection Remix LP gets on board with the new layout, space is a HUGE issue with LP on HOX.
 

anto12

Senior Member
Aug 12, 2010
151
44
There may be a changelog for SlimLpBig? May be I will try on sunday :)

Thanks,

Sent from my One X using XDA Free mobile app
 

Top Liked Posts

  • There are no posts matching your filters.
  • 106
    New Storage Layout for HOX Endeavoru

    This New Layout will change the way your phones internal memory partitions are used.
    The primary goal is to get more space for your apps and data. The secondary goal is to be more compatible with new OS/software. This is obtained by using a layout similar to Nexus devices.

    Two years ago pabx showed us "How to switch to a big /data partition", but at that time very few of us actually needed it. It was experimental and good Linux skills was required.

    Almost one year ago Thömy proposed to use a new better storage layout for our device. We tried it and found it good (at least I did), but we were still happy with KitKat on Dalvik, so we didn't bother to publish it.

    Well, now we have Lollipop and ART. And memory suddently seem very limited.
    Move2SD is a must for many of us. And guess what...: Thömy refined the layout to be used for Android 5 and ... I have the pleasure to present this New Layout. So, here we go.


    Before starting the process of converting your HOX to the New Layout, please make sure you have plenty of time for this.
    Don't start if you are planning to use the phone in near future. Unforseen things can happen, so you may need some advice to get back on the right track.
    It is very hard to brick the HOX as HTC did a good job on securing it, but we all know, s... happens.
    Remember, xda is all about changes and no change is without risk.


    A word of warning: Although some error situations will be prevented, it was not possible to cover all situations.
    You CAN restore a backup from the wrong layout. And you may be able to loose data if you don't keep track of which layout you are using.
    It is YOUR responsability to keep track of your files.
    Good luck and have fun flashing.


    Enough talking, let's start.

    Requirements: HTC One X International. 50%+ battery. You know how to flash a recovery. You know how to flash ROM and boot.img.
    To upgrade, follow these simple steps or use the detailed guides below:

    Make sure your adb/fastboot is up to date and working.
    Make sure you can transfer files with MTP (test before you start the transformation).
    1. Backup everything in your phone that you want to keep. This will WIPE ALL!
    2. Boot to fastboot and Install a recovery made for the New Layout. twrp2811.BiG.img will do for a start.
    3. Disconnect the phone from PC (current recovery will fail the format process if you skip this step).
    4. Format Data. This will reformat your SD Card to be used for both app-data and user storage (new SD Card).
    5. Clean out all other partitions.
    6. Restart recovery and wait for two new drives to pop up on your PC.
    7. Copy a ROM with the New Layout to the Internal SD Card or the new 2GB Extra Data.
    8. Flash the ROM (and gapps) and reboot.
    9. Go here and press the Thanks button (or even better, the button above it).

    Going back to the old layout is easy:
    1. Boot to fastboot and Install an old Recovery.
    2. Change the file system of the SD Card back to FAT.
    3. Copy a ROM or a backup with old layout to SD Card. Mount USB Storage if you want to copy a backup - MTP may fail on very large files.
    4. Wipe/format everything except SD Card.
    5. Flash ROM or restore backup.
    6. Reboot to bootloader and Flash boot.img from ROM or the backup.
    7. Boot to your old system.

    Whats missing ? Let me know if you find something!
    Want pictures ? Look in the guides :)
    Want more ? Upload it....
    ... and so he did... thanks @dady000 for SlimBean!

    Adding New Layout to Legendary @pabx AOSP 4.2.2 >>>>>>DOWNLOAD<<<<<

    All my files are now copied/moved to >>>>> Android File Host
    22
    FAQ

    :confused:
    How do I create a backup of my Old Layout?
    Guide on BACKUP

    :confused:
    How do I switch to the New Layout?

    :confused:
    How do I get back to the Old Layout?
    Guide on Going Back to Normal Layout


    :confused:
    How difficult is it to switch to the New Layout?
    Awesome I will try the new layout.
    ... @teemo love the instruction for New big partition it is easy to follow and I don't thnk I can make a mistake unless I forget to backup my files to my computer. Thanks for the formatting over to new partition instructions.
    :confused:
    What if I update the ROM or if I change to a different ROM. Do I need to backup my pictures and music etc. first ?
    The SD Card is now a part of the /data partition. It is actually just a directory named - /data/media
    This "media" is the SD Card.
    When you flash a ROM, you can wipe Dalvik, System, Cache and Data. This will not touch the SD Card.
    When you select wipe Data in twrp, it does NOT format /data. It selectively delete everything on /data except /data/media
    To wipe the SD Card, you need to select Internal SD Card.
    prepare.png
    :confused:
    Show me the difference...

    Partitions on the Old Layout:
    Code:
    #p12: 1280MB  /system
    #p13:  320MB  /cache
    #p14:   25GB  sdcard
    #p15: 2196MB  /data
    Partitions on the New Layout:
    Code:
    #p12: 1280MB  /system
    #p13:  320MB  /cache
    #p14:   25GB* /data
    #p14:   25GB* /data/media = sdcard
    #p15: 2196MB  /xtradata
    * #p14 is 25GB that is shared between DATA and SDCARD
    :confused:
    Why can't we use Mass storage?

    The data we want to store on the bigger partition need to be protected. The FAT system used by current sdcard does not offer any kind of protection. Linux/Android use ext4 to secure your data. This mean you can use your phone for banking, pictures, videos and other private data without worrying too much.
    HTC have locked the partitions, so we cannot resize /data and sdcard.

    :confused:
    Can I restore from Old Layout to New Layout

    Thanks to @eyosen for reminding me of this. It can make life a little easier for us:
    You can restore DATA from the Old Layout to the New Layout. Do not restore the system.
    Make sure the data you restore is compatible with the ROM (system) you install. Most apps may restore and work perfect, but be prepared, that there might be issues. If an app is messed up, first try to clear the apps data via Settings-Apps-"BadApp".

    :confused:
    I can't see the drives on PC ... I have problems with Windows drivers:

    THIS guide has proven to be useful, thanks @bhushan11689

    :confused:
    I still have problems with Windows drivers when using twrp2834-BiG:

    Try the new twrp2851-BiG, it is more friendly :)
    :confused:
    I cannot download to sdcard,
    Pictures and Screenshot does not work,
    How can I access my sdcard?

    For all solutions below: Once you enter the command, you must WAIT.
    It can take a while, as the command will change ownership of all your files on the sdcard.
    On a fresh install it may only take a second. But if you restored a lot of files, be prepared to WAIT :)

    If you use MultiRom don't do this (I am not sure, but I think it will change ownership for your secondary ROMs)

    Originally Posted by Thunder07 I'd recommand
    Code:
    adb root
    adb shell chown -R media_rw:media_rw /data/media/0/
    If that didn't work, try this:
    - boot into the recovery
    - tap Advanced -> Terminal Command -> Select
    - write carefully:
    Code:
    chown -R media_rw:media_rw /data/media/0/
    tap Go and WAIT for the command to finish
    - tap Home and reboot system

    Or if you have Root Explorer or similar installed in android, you can:
    - From Root Explorer navigate to /data/media
    - long press the "0" folder and select Change owner
    - Set Owner and Group to "1023 - media_rw" and tick "Also set on all sub-folders and files"
    - hit OK and WAIT.


    ...to be updated...
    15
    ViperX FOR NEW LAYOUT

    Hi,here is the ViperX 4.1.1 for new layout made by me.
    Actually I didn't do anything special,just followed the instruction posted by teemo,so do not consider it my job ;)

    ViperX 4.1.1-NL

    Hope you enjoy it :p

    Edit:
    1-Flash kernel from this post,ignore the one inside the rom.

    2-I forgot to include extra keyboards added in latest viperX,if you need any,extract it from original ViperX zip (old layout) and copy your missing keyboard to system/app and reboot.don't forget to change permision before :cowboy:
    11
    MaximusHD

    With huge thanks to teemo, here is MaximusHD for New layout:

    1.) ROM
    2.) OTA 1
    3.) OTA 2
    4.) OTA 3

    (leave a feedback, please)
    9
    Can we modify sense roms to use this new layout in order to get more space for data ?
    Thanks for the reply teemo. So in order to boot a sense 5 ROM on this new layout, stuff has to be changed to get it to boot correct? Is it updater-script? Or is it totally impossible to boot a sense 5 ROM on the new layout?
    it's impossible to use sense on this new layout. if you want going back to sense then you need to revert back to "old layout" :D]
    Most changes are in the ramdisk and Sense developers can change that easily. But there's one change in a framework XML file. But I think it's possible to change that also by decompiling the framework.jar. Ask your favorite Sense developer what he/she thinks about the change. However there's a bit of uncertainty. There may be other places where Sense expects a separate SD card. Also the developer probably needs to add the AOSP sdcard daemon.

    Thanks @teemo for the great work... Now waiting CM to join the party.
    Hopefully today.

    I'd recommand
    Code:
    adb root
    adb shell chown -R media_rw:media_rw /data/media/0/
    We should solve this problem. Why doesn't the recovery mtp daemon enforce media_rw ownership? Or is it solved in a newer version?

    anyways, in your main post, you linked to Thomy's patch, where he uses the old data as /cache, and releasetools.py isnt fully updated and so forth,
    but you use the old /cache still, either way, you should make it clear in the 1st post which way everyone should use.
    I've updated the patchset.