I have recently bought Xperia M C1905 and of course, rooted it on the same day itself. But further customization such as unlocking the bootloader, installing CWM, etc seems to be a little difficult as it’s my first Sony smartphone and never dealt with a bootloader locked device. I’m having Galaxy S4 and things are pretty simple there. So, I started to search over the forums (XDA, definitely) and could see that the tutorials are scattered over various sections and I had to switch between various tabs on my Chrome to complete the procedures.
For all newbies out there, here’s the only guide you ever need to read about the Sony Xperia M. This tutorial is meant for bookmarking and reference. So, if you own an Xperia M and want to root, unlock the bootloader, install CWM, flash custom ROMs, and swap memory(increase internal memory), save this page. This is definitely gonna help you.
We will be going through these procedures in order to unleash the power of your charming Xperia M.
Disclaimer
Rooting and unlocking the bootloader of your phone voids the phone warranty. All these steps are risky enough to damage your phone. Rooting is my hobby and it’s not a big piece of guava for me. I followed all of these steps and successfully achieved root, unlocked the boot loader, installed CWM recovery, and even installed KitKat (not used now). So do it at your own risk and I will not be taking any responsibility for the malfunctioning of your creature. Beware!
1. Rooting Sony Xperia M C1905/1904
Rooting is the first step towards further customization of your phone. So we will be guiding you to root your Xperia M with the help of Framaroot. Let’s see how it can be done.
- Download and install Framaroot [link] on your phone.
- Now choose “Install SuperSu” and then choose Galdalf to exploit as shown below. Wait till it shows a success message. After getting root, reboot your phone.
- Now download and install the Busybox app [link] on your phone. In the busybox, choose the install directory as SYSTEM/XBIN. Now click Install and select Normal Install. After installation completes, just reboot your phone again.
- Your phone is now half rooted and you have basic root privileges to install root apps etc. But you can’t edit or modify your system files. If you try to do so, your phone will reboot at that instant. Now we’re going to fix that in the next step.
- Download the toot fixing file and extract it. Install Sony PC companion on your computer as it will install all necessary phone drivers. Also, turn on Android debugging from developer settings on your phone. Then in the extracted folder, find supersu.bat file after connecting your phone to the computer. If all drivers are installed properly, you will be detected by it and will give further instructions to proceed. Grant root permission on your phone while asking. Disconnect your phone after the success note.
- Now you have fixed the reboot issue by giving shell access to root requests.
2. Unlock the Bootloader of the Sony Xperia M
Unlocking the bootloader means breaking the manufacturer’s locks. Certain companies like Sony and HTC lock their phone with the bootloader. It’s essential to unlock the bootloader of your phone in order to modify your phone to the next level such as installing CWM, custom ROMs, etc.
- By unlocking the bootloader, you’re out of official Sony updates and supports. So do this step at your own risk and we will not be held responsible for any kind of damage in any manner. Caution. Also, bootloader unlocking will completely wipe your internal SD card. So better back up all your data.
- It’s highly recommended to back up your TA partition (In order to re-lock your bootloader in the future). Read the tutorial here to back up your TA partition.
- Download fastboot drivers and extract them on your computer.
- Now get your phone’s IMEI number by typing *#06# on the dial pad.
- Click here to go to Sony’s official bootloader unlocking portal and get your unique key via mail. For this, you have to provide your IMEI number by removing the last digit. You will get the key like this.
- After getting your bootloader key, open the fastboot folder from the extracted fastboot driver package.
- Being in the fastboot folder, open a command window there (by holding the shift key and right-clicking on white space). If you’re on Windows XP, you can’t do that in the above manner. Install this tool and right on on the fast boot folder to do so.
- Now switch off your phone and connect to the PC in fastboot mode. Press and hold the volume up key and connect the phone to the USB cable. [Make sure that you have installed the necessary drivers. Otherwise, it won’t work. ]
- If all are set as explained above, in the command window type fastboot.exe -i 0x0fce getvar version
- If you get a value of 0.5, you’re properly connected. Instead, if you’re getting <waiting for device>, install all the drivers again and restart your computer. Then do the same.
In the command window, type fastboot.exe -i 0x0fce oem unlock 0xKEY [Replace KEY with your unique key which you have got via mail]. Press enter and you’re done. Whoopie.
3. Installing CWM Recovery on Sony Xperia M
Now you have gained full root access and you are ready to install Clock Work Mod in order to flash custom kernels, ROMs, and scripts. Read through this section and we will be guiding you to install CWM in your Xperia M.
- Power off your Xperia M and connect to the computer by pressing and holding the volume up button along with it. The LED will turn blue in color. Release the button then.
- Download the CWM file [link] and extract it. Now copy the .img file from the folder and copy it to the fast boot folder.
- Again open the command window there and execute (replace boot_image_name.img with the name of .img file in the cwm folder)
fastboot flash boot boot_image_name.img
- Wait till it finishes the shell. Done.
NOTE : In case the shell can’t detect your phone, try this; Open command window in the fast boot folder. Now connect your phone in to the computer as said above. Execute the command. Got it?
You have now rooted, unlocked the bootloader, and installed the latest CWM recovery on your Xperia M. The next step is to check whether CWM is installed properly. For this,
- Reboot your phone and while displaying the SONY image, the LED will turn pink. Now press the volume up button and the LED will change to Cyan color. Bham!! CWM there. Enjoy.
4. Flashing Custom ROM in Xperia M
I know that you are eagerly waiting to update your ROM. As you have installed the CWM, you can easily flash any custom ROMs, say CM 11 on your phone. But remember one thing. Before directly flashing CM 11, extract the ROM folder and flash the boot.img file first with the help of fast boot (Similar to the installation of CWM. Copy the boot.img file to fast boot folder and open the command window there. Then execute fastboot flash boot boot.img . That’s all.
5. Swapping Internal Memory with SD Card in Xperia M C1905
We all know that Xperia M is a snappy phone. But the only thing that I feel bad about it is its low internal memory. It has got 4 GB memory inbuilt. But we could only avail around 2 GB. To get rid of this issue, you can swap your internal memory with an external SD card. Just go through this.
- Download the script and copy it to your phone’s memory. For example, copy to sdcard0/android/data.
- Download the script manager app from the Play Store. Now open the app, and choose browse as root.
- Load the text file from the folder tap it and open it as Script/Executable.
- After opening it, select the SU icon, boot icon and choose save. Now it will turn yellow in color. Switch off the phone and reboot. See the magic. Look at my storage info. (I have an Xperia M C1905 single SIM variant and I’m not sure about the Dual SIM version)
This is definitely a long post and I have covered almost all necessary guides together for customizing your Xperia M. Through this guide, I have detailed how to root, unlock the boot loader, install CWM, custom ROM, and swap internal memory with external SD card for Xperia M C1905/04.
Credits/Thanks: XDA Xperia M development portal, geeky devs out there, etc.
How to reverse the swapped memory (as shown in number 5) back to normal again?
how can i root my phone using mac? i have macbook pro so how to do it without windows?
You can root your your from the phone itself but further.unlocking needs computer access. Btw I will let you know once I find how to do it in mac.thanks
Hy bro can we directly swap our memory eithout installing cwm after rooting
Yes you can. Just install busybox and script manager
i tried doing this. It made my external memory the size of internal; BUT the internal memory hasnt been changed to the size of the external!! BOTH are only 2GB now! by default internal is 2 and external 14.8! whats wrong?
Just do this. REmove script manager and reboot. It will fix your current problem. Then apply the swapping method again. It will work.
Can I unlock the bootloader even when in the services menu says “Bootloader unlock allowed: no”?
Unfortunately no. If it says line that your phone does not support bootloader unlocking.
I am using a sony xperia m with CM 11[unofficial]. I tried to swap the memory like how u said but it did not work.. is there any other way.??
Yes, CM 11 has another method which I will be adding into this post ASAP.
i comented earlier,.. the swapping did not work… MY EXT CARD SAYS ITS 2 GB AND EVEN MY INT SAYS 2 GB AND ALL MY DATA IN THE EXT CARD HAS BEEN ERASED….
PLEASE HELP!!!!!
The swapping did not work… MY EXT CARD SAYS ITS 2 GB AND EVEN MY INT SAYS 2 GB AND ALL MY DATA IN THE EXT CARD HAS BEEN ERASED….
PLEASE HELP!!!!!
Just uninstall script manager and do the same again. It will work.
can i directly do the procedure of Swapping Internal Memory with SD Card in Xperia M C1905, on my phone without connecting my phone to computer? Thank you.
Swapping does not require computer.
Load the text file from the folder and long tap it and open as Script/Executable….
why it says error:selected file is directory 🙁
Strange issue. Could you please attach a screenshot of the issue?
Will it work on 4.3(JB) ?
I have already written a separate post for 4.3. Check out that.
The post was Awesome, Everything is listed out in the perfect way, thanks a lot for the excellent work….
Para desbloquear el gestor de arranque me aparece al final el siguiente error
FAILED remote comand not allowed
Are you getting this error on command? I didn’t get your language actually.
Error:
fail comand remot no permit
fastboot.exe -i 0x0fce oem unlock 0xKEY
ERROR:
FAILED remote comand not allowed
i tried only swapping after rooting using script manager but that code changed both memory to internal n now i have 2 gb only for both! i cant even access the other memory! please tell me how to revert it!
Just uninstall script manager.
By your method for unlocking bootloader my c1904 does not boot now.Its stuck on the boot animation
Hi Kartik,
Well, do one-thing:- flash the firm ware (again), then try this boot loader way. Hope it helps.
Thanks
Hi!
I used the Framaroot and send me this error: failed 🙁 try another exploi if available
And then i can´t do anything more… what can i do?
Hi Alice,
Could you tell us, which phone you are using?
how to install drivers??
i am stuck on
“Now switch off your phone and connect to the PC in fastboot mode. Press and hold volume up key and connect the phone in the USB cable. [Make sure that you have installed necessary drivers. Else it wont work. ]”
i have pc companion but i dont know how to install drivers
Perfect guide! Make sure you keep it updated in case of any changes in the future 🙂
Hi Sanjeet. Its great pleasure that you liked the post. Sure, we’ll definitely update the post with new additions whenever possible. Thanks for your valuable comment.
hello sir can you possibly help me….everything is successful up to the point when i run the supersu.bat file,the command promt window opens and it runs then it never detects the phone…i have usb debugging enabled,sony pc companion installed and sees the phone,(even prompt’s for an update),…i tried uninstalling the drivers and reinstalling the drivers,rebooting the phone,uninstalling and reinstalling sony pc companion
the only thing that happeneds is i get prompted to reinstall pc companion until i tick the box to never show me again…do you have any advice you can give me to get me past this problem…thank you
also after checking my bootloader is not able to be unlocked,(it is locked to the carrier 02),will your method still work even after i dialed
*#*#7378423#*#* /service info/configuration/rooting status
and the info told me NO
is it still possible do you know to unlock the bootloader
thank you
It won’t work either, sorry.
Swap method. Dint work for my experia m update
I ve done only snapping method everything go normal but d memory stays same for external n internal
Hi! Excelent post. I only have one question. Is it possible to swap memory as you indicated on step 5 WITHOUT unlocking the Bootloader of Sony Xperia M C1905?
Thanks
No. You have to unlock the bootloader in order to swap the memory. Thaaks.
My phone got stucked in Animation Screen after Unlocking Bootloader,
I used Sony Xperia M with 4.3 JellyBean
Can you give the solution to fix that problem ?
I’m Very Happy when i find this complete tutorial, but i’ll be more happy when you Give A solution when someone got Error when he Took a mistake Step
Regards.
Kevin and sorry for my bad english 🙂
Hi Kevin, all you have to do is this. I guess you have flash tools installed in your computer. If not, download the sony flash tool
(google it) and get the firmware of xperia m (also google it or get it from xda forum). Then just flash it. You can refer my Xperia M section to know how to flash a firmware using flash tool .Thanks and let me know if you want any more help.
Thanks sir, my phone was fixed 4 days ago, I and i was Get CWM Recovery, and i Do swapping, but I was get nothing, Can you tell me the problem sir ?
Thanks Before
HI Kevin,
You tried swapping and it didn’t worked, right?
Thanks,
Sayantan
Yeah, i used folder mount until now
Sorry for my bad english
Wow. You might be game freak then.
Framaroot showing error 5 how to solve this problem help me guys
Is your phone running on the stock 4.1 firmware or something else?
Android in 4.3
Build number
In 15.5.a.1.5
Please help me how to fix that problem
Android in 4.3
Build number
In 15.5.a.1.5
Please help me sir
How to fix this problem
Should i have to go to sony website and legally request code to unlock boot loader or is there any easy process?
Yep. You should. You won’t get the unique code anywhere else.
Your goddamn guide made my phone go bootloop after unlocking bootloader……
I don’t thing I have written any mistake. Even I’ve unlocked my M’s bootloader by this method and as you can see no one has got this problem.
I have the same problem. please tell me how to fix this.
wheather this will work on 4.3 jellybean.
–
Sir, I need some of ur valuable
suggessions… I unlocked the
bootloader of my sony xperia M
withour rooting the phone… now
my phn starts bt keep laging at
the xperia waves nd nevr starts
up… I went to sony services fr
help bt they told me that u tried to
modify ur software it wil charge u
a sum of rupees 4300 . sir, would
u please help me on this regard? i m using andoid versiom 4.3
Just download stock firmware and flash it via flash tool
Trying to unlock bootloadder but In command prompt it says waiting for device,tried on both windows and linux 🙁
Xperia M C1904 JB4.3
Did till the third step and now my phone just wouldnt boot up.
Xperia M C1904 JB 4.3
Could you see the Sony logo while starting up?
Excuze my ignorance but will this network unlock my phone. I have a c1905 and I need to unlock it . I heard that after rooting the android is unlockable via some app? can you give me a quick tip? … Thank You!
Sir, I flashed CWM successfully! Then, how do I flash the new rom? I tried to flash boot.img of the CM11 rom, by putting the device in fastboot mode and on my pc I opened a sony mobile flasher and flashed boot.img from the folder I extracted. Then, the CWM recovery mode isn’t opening! Where am I going wrong? Please help! I rooted the mobile, unlocked the boot loader! And should I keep my mobile rooted to flash a new ROM? Please reply, sir! I’m new to this! Please help me out! Thanks in advance!
Sir, I flashed CWM successfully! Then, how do I flash the new ROM? I tried to flash boot.img of the CM11 ROM, by putting the device in fastboot mode and on my pc I opened a sony mobile flasher and flashed boot.img from the folder I extracted. Then, the CWM recovery mode isn’t opening! Where am I going wrong? Please help! I rooted the mobile, unlocked the boot loader! And should I keep my mobile rooted to flash a new ROM? Another question is, my mobile’s internal storage and the firmware in it totally gets erased each time I flash CWM. Is this normal to happen? Please reply, sir! I’m new to this! Please help me out! Thanks in advance!
May be the boot.img you flashed doesn’t have cwm recovery. Did you try flashing other boot images?
I use cyanogenmod fxp kit kat 4.4.4 nightly on my xperia M single sim. tired the script with script manager. external memory also showed as 2gb . uninstalled smanager and then it went back to normal. how to swap correctly for my android version?
I get the error “command not allowed” when attempting to unlock boot loader. Xperia M c1904 on 4.1.2. Using terminal on ubuntu. Any solutions??
You’ve to download separate fast boot files for linux
Hi i installed cwm recovery
And now my phone’s led turns pink on bootup but i cant access recovery? I pressed volume up button bit that didnt worked!
The recovery doesn’t seem to be installed correctly. Could you try flashing it again ?
can i use the methode of Swapping Internal Memory with SD Card in Xperia M C1905 running android 4.3 build 15.4.a.1.9
Hii..
How can we swap memory directly without installing Cwm… On my Xperia m
Hey Dear !
I read your post thoroughly and i found step 5 useful for me.
As i have sony Xperia M ,so please guide me to apply the step 5 in my smart phone, as i’m also suffering from low internal memory storage.
perfect article…… simply follow wat the have said…. aws,
thanks a lot for your time and effort i also like you could not find anything on xda as stuff all over the place then things wasn’t working but came here and did everything step by step and everything worked. so i would just like to say thanks
my problem is failed: remote: command not allowed, how i can do it
Re-install adb in your PC.
Sidarth,
I have the an M-DUAL and have the same probem as Cooldudeachyut. After step 3 (Installing CWM Recovery on Sony Xperia M) I can bring my phone to the fastboot menu when the LED shines pink, but I cannot reboot the phone. It goes into a boot loop.
I am currently downloading the stock firmware from XDA-developers (http://forum.xda-developers.com/showthread.php?t=2703161). Hopefully I can flash this firmware and all ill be well.
I’ll update after my attempt … I was so hopeful when I got to the fastboot menu 🙁
Okay, after installing CWM Recovery with the proper caution now when turning on my phone it shows the SONY logo, the pink LED and then turns off. If I keep pressing the power button it just vibrates once or twice and won’t turn on. How to fix this? Will I need to reinstall the firmware over or do a factory reset? I don’t wanna do that again…
Hi,
Am unable to root my phone(c1904) using framaroot.apk, Error:- failed 🙁 Try another exploit if available (error #5)
I have rooted the phone using Towelroot.apk, now reboot fix is not working. Please help me.
Error
Sending the fixer.
=============================================
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
.
=============================================
Installing the rootfix.
=============================================
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
‘adb’ is not recognized as an internal or external command,
operable program or batch file.
at your device GRANT supersu access!
Press any key to continue after granting root access.
Press any key to continue . . .
I have an Xperia M c1904 with android 4.3 jelly bean and I’m not even able to pass through the first step, i keep getting an error message saying “Failed 🙁 … Try another exploit if avaible (error #5)”. What do I do?
I unlocked the bootloader as it showed “okay” in the command prompt but after rebooting the phone is stuck at boot from past 10mins. What should be done now? please help.
hi i have a custom rom on mine as i did it using your guide but now my problem is that i am trying to put a new cusrtom rom on my phone but i cant connect to fastboot anymore? i have a recovery that came with my custom rom but that is rubbish and i am trying to use cwm or something simcheersilar but cant connect into fastboot?
I have an Xperia M c1904 with android 4.3 jelly bean, I am unable to start my phone after unlocking the boot-loader(this is the second time I am facing this problem, first time I repaired it from service center), Why is this happening? I followed correct steps (I have Android studio Installed on my computer).I downloaded Sony Emma Flash tool, It is asking me a Username and Password.
Don’t Know what to do, please help me. If you can please provide the suitable Links to download the file
Thanks in advance , Merry X-mas
hey siddarth the guide was just the best I found on Google I have a question that can I flash stock rom of. C1905 to C1904 without unlocking bootloader.Quick reply is required.
Yes. You can.
dude .. after finis swaping instruction my Xm end up bootloop .. can u help me?
{HELP} dude .. after finis swaping instruction my Xm end up bootloop .. can u help me?
i ve unlocked the bootloader succesfully as my pc said.but my xperia m doesnt turn on!!!what can i do??please help!!!!
re-insert the battery. Could you see anything on the screen?
Hello Sidharth,
first of all Thank you.
I have unlocked my xperia m and flashed recovery.img and boot.img to it but installation breaks with error “failed ti find /misc partition” how can i create this partition, what size shouöd it have and what should it contain ?
in fastboot -h i found how to erase or format partitions (i didn’t) but not how to create.
too bad CM is down …
let me see