5,598,657 Members 39,313 Now Online
XDA Developers Android and Mobile Development Forum

[Q] writing 'bootloader'... FAILED (remote: (Unknown error code))

Tip us?
 
brad3626
Old
#1  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Question [Q] writing 'bootloader'... FAILED (remote: (Unknown error code))

My N7 "2012" kept freezing, so I put it in bootloader and tried to do a recovery mode reset to stock. It froze during the process.
Now, the only thing I can do is get it into bootloader mode manually by holding the buttons. It frezes if I choose any of the options from the bootloader screen including restarting the bootloader from the bootloader screen without holding power and volume.
I have tried the Nexus Root Toolkit a bunch of times with the "flash stock + unroot (soft bricked)" feature, testing different factory builds and the best results are below:

Flash Stock + Unroot...
------------------------------------------------------------------


erasing 'boot'...
OKAY [ 2.526s]
finished. total time: 2.526s
******** Did you mean to fastboot format this partition?
erasing 'cache'...
OKAY [ 0.200s]
finished. total time: 0.200s
erasing 'recovery'...
OKAY [ 0.016s]
finished. total time: 0.016s
******** Did you mean to fastboot format this partition?
erasing 'system'...
OKAY [ 0.015s]
finished. total time: 0.015s
******** Did you mean to fastboot format this partition?
erasing 'userdata'...
OKAY [ 0.015s]
finished. total time: 0.015s

sending 'bootloader' (2100 KB)...
OKAY [ 0.264s]
writing 'bootloader'...
FAILED (remote: (Unknown error code))

finished. total time: 0.402s
rebooting into bootloader...
OKAY [ 0.020s]
finished. total time: 0.021s

< waiting for device >
PLEASE HELP! Keep in mind that I am a newb to messing with this stuff.
I have read forums and tried things that people suggested to others in similar situations, but I am pretty lost at this point. Keep in mind that my device is almost certainly wiped and definitely will not boot the OS.
 
Erovia
Old
#2  
Erovia's Avatar
Senior Member
Thanks Meter 213
Posts: 709
Join Date: Sep 2012
Is your N7 the Wi-Fi or the 3G variant?
What was the name of the factory image you were trying to flash?
Phone: Nexus 4
ROM: ParanoidAndroid 4+
Kernel: hells-Core
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Tablet: Nexus 7
ROM: SlimKat 4+
Kernel: LeanKernel
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Phone: Motorola Milestone A853 ROM: CyanogenMod 9.1.0d Recovery: Open Recovery MiniMod by -FuFu-
The Following User Says Thank You to Erovia For This Useful Post: [ Click to Expand ]
 
adomol
Old
(Last edited by adomol; 13th February 2014 at 11:00 AM.)
#3  
adomol's Avatar
Senior Member
Thanks Meter 52
Posts: 181
Join Date: Jan 2014
Quote:
Originally Posted by brad3626 View Post
My N7 "2012" kept freezing, so I put it in bootloader and tried to do a recovery mode reset to stock. It froze during the process.
Now, the only thing I can do is get it into bootloader mode manually by holding the buttons. It frezes if I choose any of the options from the bootloader screen including restarting the bootloader from the bootloader screen without holding power and volume.
I have tried the Nexus Root Toolkit a bunch of times with the "flash stock + unroot (soft bricked)" feature, testing different factory builds and the best results are below:

PLEASE HELP! Keep in mind that I am a newb to messing with this stuff.
I have read forums and tried things that people suggested to others in similar situations, but I am pretty lost at this point. Keep in mind that my device is almost certainly wiped and definitely will not boot the OS.

After doing a bit of research, I've found out that there is a BAD version of the N7 2012 bootloader 4.23 floating around. The unsettling thing is that it's being supplied with a couple of the factory images that come straight from from the Google android devolpers page online. Anyway to make a long story short, I would try flashing the working version of the bootloader first off, then go from there with a factory reset. You can download the the working bootloader (bootloader-grouper-4.23.img) HERE --> h t t p : / / g o o . g l / q A D S A z (sorry about the spaces in the url, I'm new to the forum and can't post links yet, just delete the spaces)

BTW, its the same bootloader for N7 wifi OR 3G. md5 = df53028033c9eccf4fe5ba7bc198ce24

Here's how to install using fastboot:

1. Reboot To Your Bootloader On You Nexus 7 (Power off power button and volume down until you see bootloader screen)
2. Connect Your Nexus 7 To Your Computer
3. Open Up Command Prompt or terminal window (not sure if you are using windows/mac/linux)
4. CD to where you downloaded bootloader-grouper-4.23.img
5. Then type:
fastboot devices (to see if your N7 is connected correctly)
fastboot flash bootloader bootloader-grouper-4.23.img
fastboot reboot-bootloader

Then try the factory reset again.

If you don't have fastboot installed your computer you need it. Makes flashing your N7 a breeze... lock/unlock, custom recovery installs, going back to factory stock, all much more easy with fastboot.
You can get it from the android devolper site, h t t p : / / g o o . g l / 2 q p r for windows/mac/linux. All you need is the SDK tools, not the ADT bundle.
The Following User Says Thank You to adomol For This Useful Post: [ Click to Expand ]
 
brad3626
Old
(Last edited by brad3626; 13th February 2014 at 08:25 PM.)
#4  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by adomol View Post
After doing a bit of research, I've found out that there is a BAD version of the N7 2012 bootloader 4.23 floating around. The unsettling thing is that it's being supplied with a couple of the factory images that come straight from from the Google android devolpers page online. Anyway to make a long story short, I would try flashing the working version of the bootloader first off, then go from there with a factory reset. You can download the the working bootloader (bootloader-grouper-4.23.img) HERE --> h t t p : / / g o o . g l / q A D S A z (sorry about the spaces in the url, I'm new to the forum and can't post links yet, just delete the spaces)

BTW, its the same bootloader for N7 wifi OR 3G. md5 = df53028033c9eccf4fe5ba7bc198ce24

Here's how to install using fastboot:

1. Reboot To Your Bootloader On You Nexus 7 (Power off power button and volume down until you see bootloader screen)
2. Connect Your Nexus 7 To Your Computer
3. Open Up Command Prompt or terminal window (not sure if you are using windows/mac/linux)
4. CD to where you downloaded bootloader-grouper-4.23.img
5. Then type:
fastboot devices (to see if your N7 is connected correctly)
fastboot flash bootloader bootloader-grouper-4.23.img
fastboot reboot-bootloader

Then try the factory reset again.

If you don't have fastboot installed your computer you need it. Makes flashing your N7 a breeze... lock/unlock, custom recovery installs, going back to factory stock, all much more easy with fastboot.
You can get it from the android devolper site, h t t p : / / g o o . g l / 2 q p r for windows/mac/linux. All you need is the SDK tools, not the ADT bundle.
Thank you for the help, unfortunately, it did not work.
I followed the instructions above, but the Nexus displayed "neither up nor cac partitions found" over and over
While cmd displayed:
C:\Users\Brad>fastboot devices
XXX fastboot

C:\Users\Brad>fastboot flash bootloader bootloader-grouper-4.23.img
sending 'bootloader' (2100 KB)...
OKAY [ 0.281s]
writing 'bootloader'...
FAILED (remote: (Unknown error code))
finished. total time: 3.213s

C:\Users\Brad>fastboot devices
XXX fastboot

C:\Users\Brad>fastboot flash bootloader bootloader-grouper-4.23.img
sending 'bootloader' (2100 KB)...
OKAY [ 0.271s]
writing 'bootloader'...
FAILED (remote: (Unknown error code))
finished. total time: 3.205s
 
brad3626
Old
#5  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by Erovia View Post
Is your N7 the Wi-Fi or the 3G variant?
What was the name of the factory image you were trying to flash?
Wi-Fi
I have tried every one that the NRT offered.
 
Erovia
Old
#6  
Erovia's Avatar
Senior Member
Thanks Meter 213
Posts: 709
Join Date: Sep 2012
Just read this guide and download the latest factory image from here.

Good luck.
Phone: Nexus 4
ROM: ParanoidAndroid 4+
Kernel: hells-Core
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Tablet: Nexus 7
ROM: SlimKat 4+
Kernel: LeanKernel
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Phone: Motorola Milestone A853 ROM: CyanogenMod 9.1.0d Recovery: Open Recovery MiniMod by -FuFu-
The Following User Says Thank You to Erovia For This Useful Post: [ Click to Expand ]
 
brad3626
Old
#7  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by Erovia View Post
Just read this guide and download the latest factory image from here.

Good luck.
I read that guide.
But that guide seems to be written with the assumption that the device can boot into the OS
No ADB device is found because I can only boot into bootloader.
 
Erovia
Old
#8  
Erovia's Avatar
Senior Member
Thanks Meter 213
Posts: 709
Join Date: Sep 2012
That part is only for the driver installation. You can skip to the "Extract the Factory Image" part and follow it from there.
Phone: Nexus 4
ROM: ParanoidAndroid 4+
Kernel: hells-Core
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Tablet: Nexus 7
ROM: SlimKat 4+
Kernel: LeanKernel
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Phone: Motorola Milestone A853 ROM: CyanogenMod 9.1.0d Recovery: Open Recovery MiniMod by -FuFu-
The Following User Says Thank You to Erovia For This Useful Post: [ Click to Expand ]
 
brad3626
Old
(Last edited by brad3626; 13th February 2014 at 08:26 PM.)
#9  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by Erovia View Post
That part is only for the driver installation. You can skip to the "Extract the Factory Image" part and follow it from there.
Following from "Extract the Factory Image" part, this is what I am getting:

C:\Users\Brad>cd \Users\brad\AppData\Local\Android\android-sdk\platform-tools

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot devices
XXX fastboot

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>adb reboot-bootlo
ader
error: device not found

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot oem unlo
ck
...
FAILED (command write failed (Unknown error))
finished. total time: 0.590s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot erase bo
ot
erasing 'boot'...
FAILED (command write failed (Invalid argument))
finished. total time: 0.017s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot erase ca
che
erasing 'cache'...
FAILED (command write failed (Invalid argument))
finished. total time: 0.017s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot erase re
covery
erasing 'recovery'...
FAILED (command write failed (Invalid argument))
finished. total time: 0.022s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot erase sy
stem
erasing 'system'...
FAILED (command write failed (Invalid argument))
finished. total time: 0.017s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot erase us
erdata
erasing 'userdata'...
FAILED (command write failed (Invalid argument))
finished. total time: 0.018s

C:\Users\Brad\AppData\Local\Android\android-sdk\platform-tools>fastboot flash bo
otloader bootloader-grouper-4.23.img
error: cannot load 'bootloader-grouper-4.23.img': Invalid argument
 
Erovia
Old
#10  
Erovia's Avatar
Senior Member
Thanks Meter 213
Posts: 709
Join Date: Sep 2012
On the bootloader screen is your bootloader shown as "locked" or "unlocked" ?
Phone: Nexus 4
ROM: ParanoidAndroid 4+
Kernel: hells-Core
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Tablet: Nexus 7
ROM: SlimKat 4+
Kernel: LeanKernel
Recovery: MultiROM
--------------------------------------------------------------------------------------------------------------------------
Phone: Motorola Milestone A853 ROM: CyanogenMod 9.1.0d Recovery: Open Recovery MiniMod by -FuFu-

The Following User Says Thank You to Erovia For This Useful Post: [ Click to Expand ]
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes