yashsingh1/xdaforums huggingface dataset:
[Sony Xperia S, Acro S, Ion] SystemR89:
It could brick your device, anyway a flash from bootloader should recover your phone.

I'll add a notice!

Sure, you simply need an adb shell and you have to push your rom back at the end.

You are absolutely right, fixed!

thanks!

Custom ROMs usually doesn't overwrite partition table so you can flash without problem almost any ROM

I think that's possible, anyway I haven't tested it
[Sony Xperia S, Acro S, Ion] airwolf1544:
Great :)

I think the partition size is one of the biggest show-stopper for android L (Art-Runtime needs more space).

Is it possible to backup the files using cwm or twrp before and restore after the repartition job?

BIG THX
[Sony Xperia S, Acro S, Ion] SystemR89:
Technically yes, I tried backup-restore system from TWRP but it has failed during restore.

You could tar your data partition, pull the archive, resize partitions, push archive back then restore data.
[Sony Xperia S, Acro S, Ion] zahid5h:
guys plz help i got stouk in to this what iam doing wrong:confused::confused::confused::confused::crying::crying:

~ # ←[6n(ADB SHELL) umount /sdcard

(ADB SHELL) umount /sdcard

/sbin/sh: syntax error: unexpected word

what dose this mean

The partition table has been altered.

Calling ioctl() to re-read partition table

fdisk: WARNING: rereading partition table failed, kernel still uses old table: D

evice or resource busy

~ # ←[6n
[Sony Xperia S, Acro S, Ion] airwolf1544:
Please tell what you exactly have done!

You connected the phone via "adb shell"? And then on ADB Promt you typed "umount /sdcard"?
[Sony Xperia S, Acro S, Ion] zahid5h:
my bad i have done it every thing now is okey i have new 7g internal memory

big thanks to the OP you are purely genius................ marvalles work.....keep on ....this is main blowwwing
[Sony Xperia S, Acro S, Ion] not anonymous:
Sorry for asking.Do we really have to use linux os instead of windows?
[Sony Xperia S, Acro S, Ion] airwolf1544:
I dont think so... you only need ADB .. one time for shell.. one time for push.. no need for linux i think. am i right?
[Sony Xperia S, Acro S, Ion] not anonymous:
i think so.have u tried this method? did it really worked?
[Sony Xperia S, Acro S, Ion] airwolf1544:
Nope

Gesendet von meinem Xperia S mit Tapatalk
[Sony Xperia S, Acro S, Ion] zahid5h:
I DID AND ITS WORKINGGGGGGGGGGGGGGGGG FLAWLESSLY :highfive::highfive:

EDIT I USE WINDOWS...........

GIVE ME THANKS IF I HELP YOU
[Sony Xperia S, Acro S, Ion] not anonymous:
sir, where can i get the shell script and the push thingy?
[Sony Xperia S, Acro S, Ion] airwolf1544:
You only need ADB from the Android SDK. Its easy to find.

Gesendet von meinem Xperia S mit Tapatalk
[Sony Xperia S, Acro S, Ion] zuifon:
How do you do step 13.Flash ROM and gapps ?

I can't install any .zip with the recovery because resizing the partitions broke a file needed by the recovery to install .zip
[Sony Xperia S, Acro S, Ion] heavens dragon:
can we format all 32gb for data and can still use it for storing our data like pics, vids etc like in Nexus phones?
[Sony Xperia S, Acro S, Ion] dape16:
Thanks, it's working great. Bought you a beer! :)
[Sony Xperia S, Acro S, Ion] do_nny:
can you tell me how to do that ,bro ??

I cannot use adb shell on twrp recovery n after uninstall the driver when the device is connected to PC on TWRP ,, can you help me ??

Im using XSL .. that the cause ??

sorry for my bad english .. thank you ..
[Sony Xperia S, Acro S, Ion] mickybart:
I just re-partitioned my device and I have try to don't wipe /data but it's not working when you restart Android. (in fact I have expected to increase the /data partition but to do a resize2fs after the reboot. resize2fs permit to increase an ext4 filesystem online and offline without data lost. The device trigger an alert about encryption and mount a temporary /data).

So on your case you can do something else to be sure to have a ROM available :

run TWRP

wipe /system (yes it's not a problem because when you flash a ROM /system is generally formatted to be clean before files copy)

mount /system

copy your ROM and gapps on /system

umount everything

follow all the steps of the post #1 but stop when you have to copy ROM and gapps from adb

=> wipe only /sdcard and /data as mentioned

mount /system

copy ROM and gapps to /sdcard (replace adb push step)

umount /system

continue with the procedure by flashing ROM and gapps

with that procedure you are sure to always have a ROM and gapps available EXCEPT if you do a mistake on the start point for /data and /sdcard that overlap and so erase or corrupt /system. The tutorial is well done and you shouldn't have any issue if you read it carefully .

EDIT:

Sorry I have made a shortcut with mount/umount

to mount : select the checkbox on TWRP

to umount : unselect the checkbox
[Sony Xperia S, Acro S, Ion] Lunatiic:
Somehow my sdcard is not mounting. Tried to use recovery but it doesn't mount.. When I press "wipe Internal Sdcard" I get an error:

Tried to mount through adb shell but I get:

I'm out of ideas, any thoughts?
[Sony Xperia S, Acro S, Ion] m1st3r1:
flash stock ftf with flashtool.. repeat everything.. and make sure you unmount everything before doing the fdisk commands (you can umount it via twrp menu, uncheck all of them)
[Sony Xperia S, Acro S, Ion] Lunatiic:
Already been trying for almost 6 hours.. Tried it about 8 times.

Already tried to manually unmount everything on TWRP (unchecked only /sdcard one time, unchecked both /cache and /sdcard another time), but I keep getting the same result. Even tried to switch the adb tool, tried both Android SDK and Minimal ADB. Tried different TWRP versions ( 2.6 and 2.8.0.1 ), tried different USB ports, tried to start the fdisk commands with everything wiped first. I'm all out of ideas..
[Sony Xperia S, Acro S, Ion] m1st3r1:
you must unmount/uncheck everything in twrp's mount setting,, now, read carefully for what shown (and what you typed) in cmd, take screenshot if necessary.. especially with the command "fdisk w" , as error will shown up here, if any.
[Sony Xperia S, Acro S, Ion] Lunatiic:
/system and /data were already unchecked. But I get what you said, everything was unchecked this last time I tried, but still the same result. Screenshots attatched.

PS: I've used

(ADB SHELL) fdisk /dev/block/mmcblk0
(ADB SHELL/fdisk) p

again, after using the

(ADB SHELL/fdisk) w

to check the current partition table, and I didn't notice anything unusual.
[Sony Xperia S, Acro S, Ion] m1st3r1:
there's warning message after you type w. it shouldn't be there,

if that warning shows up, (afaik, maybe there's other way, but it was the way i done this) the only thing you can do is revert from beginning (ie: reflash ftf, use default setting from flashtool so it will flash partition code), reboot to fastboot then flash any kernel (boot.img) that has built-in twrp (not kernel that use recovery in fota-partition), like cm11 kernel or others. redo the steps.
[Sony Xperia S, Acro S, Ion] Lunatiic:
I've seen other posts saying that it didn't interfer with the repartitioning so I didn't care.. But ok, should I use the DoomKernel v6? Or would I have problems using CWM instead of TWRP?

EDIT

Tried to do it using Doomkernel v6 (CWM) but didn't succeed. Still getting mounting error in recovery. Since I wiped /system and /sdcard isn't mouting, I tried to use adb sideload and flashed myrom.zip, but still didn't work. The interesting fact is, I tried to do the procedure twice, as soon as I finished first and I got that same warning from before, I Immediately started again and used umount /cache right in the beggning. The second time I didn't get that warning and /data was mounting correctly on recovery.. After using adb sideload, like I mentioned, I managed to boot the ROM without the Encryption error. When I open settings through the notification drawer, and under Storage I can see I have 7.49GB os space. but still no sdcard available, making the ROM kinda useless.. So, I still have to figure out WHY /sdcard is not mouting.. Or I should just give up and live on for next couple of months with 10 apps installed.. :(
[Sony Xperia S, Acro S, Ion] genecis:
Hey guys!

Whenever I connect my XS booted in TWRP to my computer (running Windows 8.1), ADB cannot detect it. And nothing shows up in Device Manager as well :(

What's weird is when I have booted to system and connect again (same USB cable and port), it is detected by ADB and "Sony sa0103 ADB Interface Driver" also shows up in Device Manager.

I've tried it using Windows XP too without success.

To anyone using Windows and who has completed the procedure: when you guys connect the device in TWRP to the computer, what exactly shows up in Device Manager?

Edit: [MENTION=5099490]zahid5h[/MENTION] and [MENTION=4961422]Lunatiic[/MENTION] I see you'll are using Windows as well. Can you guys help me?
[Sony Xperia S, Acro S, Ion] Lunatiic:
I also had this problem. You have to disable windows 8/8.1 driver signature verification and then install the drivers. Follow this guide, it's for windows 8 but works on 8.1 too.. at least worked for me.

http://www.howtogeek.com/167723/how...8.1-so-that-you-can-install-unsigned-drivers/

Install the correct and latest adb and fastboot drivers, connect the phone, and adb shell will recognize your phone.
[Sony Xperia S, Acro S, Ion] vishals16:
While in TWRP it shows as in the screenshot atttached.
[Sony Xperia S, Acro S, Ion] mirhl:
It shouldn't be "composite device" afaik.

There are three drivers inside the sys provided by android sdk, check thr other one
[Sony Xperia S, Acro S, Ion] vishals16:
I installed the google usb driver. That is why it shows up like this. I have access to adb in twrp so I don't face any problem.
[Sony Xperia S, Acro S, Ion] sonypro:
can someone make a video showing how to do it? am still newbie at sdk stuff and this operation is very dangerous, thanks
[Sony Xperia S, Acro S, Ion] kandangwa:
yeah, someone who already performed this partition successfully needs to make a youtube tutorial for christ sake cause i'm really loving the pure aosp rom from billchen1977 but sadly there isn't enough internal storage :crying::crying::crying:
[Sony Xperia S, Acro S, Ion] mariovp:
Xperia Acro S

Is it possible to do this on an Xperia Acro S?

Has anyone tried?
[Sony Xperia S, Acro S, Ion] mirhl:
You should check partitions names first perhaps.

Type df or cat /proc/partitions[/] in terminal emulator or adb shell to check them
[Sony Xperia S, Acro S, Ion] StarChaserX:
Did you check if ADB is able to recognize your device. Try the command

adb devices

If it shows the serial number of your device then the device is recognized by ADB.
[Sony Xperia S, Acro S, Ion] mironkraft:
Can I do this with locked bootloader?

Thanks
[Sony Xperia S, Acro S, Ion] kandangwa:
mine shows up like this

and doesn't recognise device

can you have a look [MENTION=5225941]vishals16[/MENTION] ?
[Sony Xperia S, Acro S, Ion] vishals16:
Update driver on right click is not working?

Did you install all the drivers provided in flashtool folder?
[Sony Xperia S, Acro S, Ion] kandangwa:
i only selected the "usbdrivers" folders and managed to install these drivers
[Sony Xperia S, Acro S, Ion] mirhl:
Ideally bootloader just flash for kernel signature..

So yes, even though I wouldn't know how locked bl recovery would behave then
[Sony Xperia S, Acro S, Ion] SysGhost:
Nice one.

I simply made a full backup with TWRP, and used adb pull to copy the backup from the internal storage to my computer.

Once partition 14 and 15 has been resized, I simply pushed the /sdcard/TWRP folder back again.

It is important that one reboots the device straight after partition table has been rewritten (Quitting fdisk). Otherwise the kernel will still use the old partition table (in memory), and can cause corruption when one tries to format the partitions.

Simply reboot back into recovery, and the kernel will now use the new partition table, and one can safely format and write data to the partitions.

One do not need to reflash the ROM. one only need to restore data on sdcard and data, if one just follow these steps.
[Sony Xperia S, Acro S, Ion] kandangwa:
i rebooted xs into recovery and following showed up in cmd

am i good to continue with data partition?
[Sony Xperia S, Acro S, Ion] vishals16:
Yes.....You are good to go.

Remember to unmount in twrp in step 3 so that you don't face any problem.
[Sony Xperia S, Acro S, Ion] kandangwa:
what are the steps to unmount in twrp?
[Sony Xperia S, Acro S, Ion] vishals16:
When you are on step 3 in the process. Instead of typing umount /sdcard, go to mount in twrp and uncheck everything (tick means that the partition is mounted so untick everything). Then just follow the process as given. :)
[Sony Xperia S, Acro S, Ion] kandangwa:
[*]Create new sd partition

(ADB SHELL/fdisk) n
(First cylinder) -> you have to indicate the stop cylinder of partition 14 read in step 8 +1. If you read 292945 as stop cylinder you have to write 292946.
(Last cylinder) -> just press enter
what is the stop cylinder?
[Sony Xperia S, Acro S, Ion] kandangwa:
sorry i typed wrong

"(First cylinder) -> you have to indicate the stop cylinder of partition 14 read in step 8 +1. If you read 292945 as stop cylinder you have to write 292946." what is the first stop cylinder read in partition 14?

and how do i wipe data and sd card to format for new partition mentioned in step 11?
[Sony Xperia S, Acro S, Ion] vishals16:
If you are creating a 8gb partition as specified in the tutorial. The stop cylinder will be the same as mentioned (292945). For the start cylinder of partition 15, indicate it as 292946( which is 292945+1) as mentioned.

You can wipe data and sdcard in twrp->wipe->advanced wipe. Select each and wipe.
[Sony Xperia S, Acro S, Ion] kandangwa:
i am performing 4 GB partition. and i don't know the first stop cylinder. can you have a look at the attachment and tell me what is the first stop cylinder
[Sony Xperia S, Acro S, Ion] vishals16:
I did a 4gb partition. It should be 167945 (stop cylinder of partition 14). So type 167946 for the start cylinder of partition 15.

Or you can print the partition table again after creating partition 14 (type command p), and look for yourself.
[Sony Xperia S, Acro S, Ion] kandangwa:
(Last cylinder) -> +8192M (this will create a 8gB partition)

while creating 4 gb partition how much value did you put in the last cylinder?

mine showed up the following cylinder after putting (Last cylinder) -> +4000M (this will create a 8gB partition)" and entered p and entered "165016" as "first cylinder" and then showed "1:unknown command

what am i doing wrong?can you have a look at attachment

do i have to flash stock rom and perform again or can i just redo the process?
[Sony Xperia S, Acro S, Ion] vishals16:
It should be +4096M. You can redo the process. You don't have to flash again. Just need twrp.
[Sony Xperia S, Acro S, Ion] kandangwa:
thanks a lot [MENTION=5225941]vishals16[/MENTION] and SystemR89 too

enjoying my new 5 gb partition :cowboy::cowboy:
[Sony Xperia S, Acro S, Ion] gsmith413:
pls help

pls help i am trying to re partition and i have a problem

i have checked everywhere and cant find exact solutions

my problem- whenever i connect usb cable to pc after booting into recovery(twrp) windows 8 detects it for a moment and then disconnects and keep on disconnecting again and again

( i have updated android sdk,plugins too

checked for adb driver update(its up to date)

antivirus if disabled,

pc companion is also disabled)

i did open command prompt at C:\Flashtool\x10flasher_lib

and executed "adb shell"

it gives following errors

1-adb server is out of date. killing(but it is now gone,i guess after sdk update)

2-error:device not found(still existing)

although when the device is connected normally switched on mode then executing adb shell the device is detected and the attached image shows the status.pl check out the attachment

pls help
[Sony Xperia S, Acro S, Ion] kandangwa:
did you install google usb driver from sdk manager?

if you have installed it, while you are in twrp manager connect your device through usb.

open device manager. it should show xperia s with exclamation mark. right click on it and press update driver software>browse my computer for driver software>let me pick from a list of device driver and choose android adb interface. install it.

then you should see android adb interface without any exclamation mark. then you are good to go.
[Sony Xperia S, Acro S, Ion] gsmith413:
atta

I am not able to connect my device

whenever i connect usb cable to pc after booting into recovery(twrp) windows 8 detects it for a moment and then disconnects and keep on disconnecting again and again

although last time it got connected it showed usb mass storage with exclamation under usb devices (device manager) as exclamation but not xperia s with exclamation

dont know what is the prob exactly???

edit:

find the attachment when the device is connected
[Sony Xperia S, Acro S, Ion] gsmith413:
pls confirm ...

can anybody please confirm if i have succesfully partitioned my xperia s by taking the look at last msg from the logcat attached below..

for step 11."wipe" data and sdcard to format your new partitions----i went to advanced wipe and checked data and internal storage is it correct?

although i cannot flash the naosp b16

my steps after partition and data wiper were:-

1-reboot into recovery once again

2-C:\Flashtool\x10flasher_lib>adb push .nAOSProm.prop /sdcard/

0 KB/s (15 bytes in 1.000s)

3-C:\Flashtool\x10flasher_lib>adb push nAOSProm-5.0-b16.zip /sdcard/

3942 KB/s (214599855 bytes in 53.153s)

4-C:\Flashtool\x10flasher_lib>adb push boot-b16-nocma.zip /sdcard/

2958 KB/s (20543105 bytes in 6.780s)

C:\Flashtool\x10flasher_lib>adb push pa_gapps-modular-nano-5.0.1-RC2-20150125a-s

igned.zip /sdcard/

3813 KB/s (122044730 bytes in 31.250s)

5- i then flashed boot.img of nAosp b16 via

adb reboot bootloader

fastboot flash boot boot.img

6-i once again wiped system ,data,cache

7-tried to flash nAOSP b16 by mickybart and failed..pls find the attached image and pls help to go ahead
[Sony Xperia S, Acro S, Ion] vishals16:
Yeah..you re-partitioned it alright.

Try not wiping after flashing the boot.img from the rom. Just wipe them before flashing the kernel.

And unmount everything except the sdcard when you are flashing the rom. That might help

:)
[Sony Xperia S, Acro S, Ion] gsmith413:
thanks

i found the same solution online any way thank you very much...i have just flashed b16 and micro apps for test..

althought i have a question

if i want to flash the full package of gapps then can i flash by simply going back to twrp and flash zip or ??
[Sony Xperia S, Acro S, Ion] vishals16:
Yeah, just go to twrp and flash them. Then just wipe cache and dalvik cache and reboot. Should work
[Sony Xperia S, Acro S, Ion] gsmith413:
successful

hello all,i am glad to say that i have did my partition and have succesfully updated nAOSP from b10 to b16 with micro gapps .

thankyou every one for your support.

special thanks to developers ...
[Sony Xperia S, Acro S, Ion] sonypro:
this could be done on windows right?
[Sony Xperia S, Acro S, Ion] vishals16:
Yes, ofcourse. :)
[Sony Xperia S, Acro S, Ion] mirhl:
[MENTION=5089807]sonypro[/MENTION]

You can even do it inside twrp recovery
[Sony Xperia S, Acro S, Ion] luigi0824:
sorry noob here

how to get a shell :eek:
[Sony Xperia S, Acro S, Ion] darknessmc:
You must have adb then open cmd in that folder contains adb and type:

adb shell
[Sony Xperia S, Acro S, Ion] sonypro:
omg really? how?
[Sony Xperia S, Acro S, Ion] luigi0824:
Sorry for being such a noob!

Please post a tutorial with video or screenshot! I dont understand anything! I already have the requirements but I cant pass step 2 :confused:
[Sony Xperia S, Acro S, Ion] Darth Inferno:
friend what is that you don't understand ? may be i can help you

do this is really easy

you just need follow the tutorial, I recommend to you when you boot on twrp go to Mount and uncheck all the partitions with this you can skip the step three and continue to the step 4 and all that you need is copy the command an follow the instruction and that's it
[Sony Xperia S, Acro S, Ion] luigi0824:
My god so complicated

how do I do step 4 open fdisk? I've tried to google it out but nothing came out helpful f#*k
[Sony Xperia S, Acro S, Ion] PunchUp:
fdisk /dev/block/mmcblk0
[Sony Xperia S, Acro S, Ion] Darth Inferno:
as [MENTION=5444464]PunchUp[/MENTION] said just write fdisk /dev/block/mmcblk0, and then press enter, write p press enter, print the partitions table because you will some information from there, in that order you just follow the instructions is really easy
[Sony Xperia S, Acro S, Ion] luigi0824:
Where do I gonna write it?:eek::confused::(
[Sony Xperia S, Acro S, Ion] Darth Inferno:
What a question!,........... friend, do you understand that you need get installed adb on your pc? and do you need open a terminal in the location where you have installed adb?, on the terminal window that you gonna open, is the place where you need write the command lines
[Sony Xperia S, Acro S, Ion] StarChaserX:
If you don't understand it... don't do it

I think before you try something that can potentially soft brick your phone, you should get a basic understanding.

Being a noob is never a problem, but, please try to learn a few things on the way and try them only when you understand what and how.

This tutorial provides helpful instructions on how to repartition the internal storage. If you are confused about how to get an ADB shell and how to run commands on terminal, please check these topics out first and understand the standard disclaimer.

Cheers

SC
[Sony Xperia S, Acro S, Ion] Sidz93:
Please help i have an error at step 10 when i want to write changes! :crying: :crying:

My internal SDcard is now at 0 MB :crying:
[Sony Xperia S, Acro S, Ion] StarChaserX:
In your recovery, please check if you have 'Cache' still mounted. Usually the device busy message is shown when a partition is mounted.

Dismount the mounted partition (usually Cache) and rewrite the partition table.

Cheers

SC
[Sony Xperia S, Acro S, Ion] Sidz93:
Not working same error my phone is bricked? :crying:

---------- Post added at 08:18 PM ---------- Previous post was at 07:38 PM ----------

Is the version of TWRP (2.8.4.1) have an impact ?
[Sony Xperia S, Acro S, Ion] Darth Inferno:
Ok friend dont be afraid, just flash the stock rom with flashtool and you can begin again,

for do not get that error at the end, when boot into TWRP in step 2 go to mount uncheck all partitions and skip step 3 and you dont have problems

---------- Post added at 03:30 PM ---------- Previous post was at 03:27 PM ----------

I dont think so, i did with TWRP 2.8.5.0
[Sony Xperia S, Acro S, Ion] Sidz93:
That was the version of TWRP! I was trying with 2.8.5.0 nd i'ts working ! Thanks for ur help bro! ;) :D
[Sony Xperia S, Acro S, Ion] ibtihaaz:
Adb shell

hi .. i am using win7 64 bit ...

i have a problem when typing adb shell in my cmd promp....i do have a folder with adb.exe and fastboot.exe when i type fastboot devices .. it shows my device but when i do adb devices it shows me nothing. once it said adb server outdated or something and killing...

how to get pass this .. Oh also when i plug my phone in my pc in twrp .. it detects the device .. like i can here the notification a lot of time and it keeps doing this all the time ..

I think i have an outdated driver for me XPeriaS .. what drivers r you guys using ???
[Sony Xperia S, Acro S, Ion] KreenTW:
help me, please.

now I got sd card 0 mb. And can't mount system, cache, data, sd card.

What shoud I do to recover my phone？

[IMG="xperia s sd card cant mount"]http://i.imgur.com/uc2hrqy.png[/IMG]
[Sony Xperia S, Acro S, Ion] moe18:
As said in a few post above, flash stock ROM (ftf) with flashtool and everything will be normal again