FORUMS
Remove All Ads from XDA

[Guide] Fix adb - device is offline error

68 posts
Thanks Meter: 48
 
By Illidan Pornrage, Member on 23rd April 2013, 06:32 PM
Post Reply Email Thread
With the new secure adb I had an issue:

(I was transferring data to a new harddrive and in the process

I deleted my /home/me/.android/ (somewhere in \Users\me\AppData\ on windows) folder because I thought I didnt need anything in it.

Then I wanted to pull some files from my CM10.1 nightly device per adb.
It said: "error: device offline" when trying to access it.

Now, the computers adb key was gone with the userdata folder of the sdk (the .android folder) and access was denied. But somehow whatever manages the authorization questions thought that this computer was still trusted and did not ask for a new authorization.

To fix that I did the following:

delete the computers adb key: rm /data/misc/adb/adb_key on device

(I have no idea if in case of multiple authorized computers the additional keys are in a new line of the file or if they are in new files. I have only 1 computer.)

stop all adb processes "killall adb" in linuxoids and "taskkill /IM adb.exe" in windows or simply the taskmanager in both.

restart the phone

toggle usb debugging off and on

connect

use adb

click authorize

works


In my case it was even nastier because my sdk userdata folder ~/.android (on small ssd) was a symlink to /data/home/me/.android (on a huge drive for the emulators, android-sources and stuff)
and the symlink pointed to a nonexisting path which prevented saving any sdk settings.
On deleting the symlink or recreating the folder it should work.
The Following 38 Users Say Thank You to Illidan Pornrage For This Useful Post: [ View ] Gift Illidan Pornrage Ad-Free
 
 
23rd April 2013, 06:44 PM |#2  
Member
Thanks Meter: 10
 
More
Thanks. Very useful!
10th June 2013, 09:13 AM |#3  
-Happy Feet-'s Avatar
Senior Member
Flag Flieden/Hessen
Thanks Meter: 179
 
Donate to Me
More
for me and the HTC One X it wont work.....
10th June 2013, 03:54 PM |#4  
Illidan Pornrage's Avatar
OP Member
Thanks Meter: 48
 
More
Quote:
Originally Posted by -Happy Feet-

for me and the HTC One X it wont work.....

Did work previously?
maybe restart the adbd on the phone.
Can you test in Recovery, Cwm has an extra button for restarting.
Maybe Stock too.
21st July 2013, 08:44 PM |#5  
Junior Member
Thanks Meter: 0
 
More
Quote:
Originally Posted by Illidan Pornrage

With the new secure adb I had an issue:

(I was transferring data to a new harddrive and in the process

I deleted my /home/me/.android/ (somewhere in \Users\me\AppData\ on windows) folder because I thought I didnt need anything in it.

Then I wanted to pull some files from my CM10.1 nightly device per adb.
It said: "error: device offline" when trying to access it.

Now, the computers adb key was gone with the userdata folder of the sdk (the .android folder) and access was denied. But somehow whatever manages the authorization questions thought that this computer was still trusted and did not ask for a new authorization.

To fix that I did the following:

delete the computers adb key: rm /data/misc/adb/adb_key on device

(I have no idea if in case of multiple authorized computers the additional keys are in a new line of the file or if they are in new files. I have only 1 computer.)

stop all adb processes "killall adb" in linuxoids and "taskkill /IM adb.exe" in windows or simply the taskmanager in both.

restart the phone

toggle usb debugging off and on

connect

use adb

click authorize

works


In my case it was even nastier because my sdk userdata folder ~/.android (on small ssd) was a symlink to /data/home/me/.android (on a huge drive for the emulators, android-sources and stuff)
and the symlink pointed to a nonexisting path which prevented saving any sdk settings.
On deleting the symlink or recreating the folder it should work.

Fraid it didn't work. End up with various errors and randomly appearing devices. Plus, the original error reappears eventually. Please help!
22nd July 2013, 03:43 PM |#6  
Illidan Pornrage's Avatar
OP Member
Thanks Meter: 48
 
More
If you give me some Info around the issue, like what you intended to do and if it worked previously, I could help you.
The Following User Says Thank You to Illidan Pornrage For This Useful Post: [ View ] Gift Illidan Pornrage Ad-Free
9th August 2013, 08:17 PM |#7  
Junior Member
Thanks Meter: 22
 
More
Thumbs up FIX adb offline problem
When you connect a device running Android 4.2.2 or higher to your computer, the system shows a dialog asking whether to accept an RSA key that allows debugging through this computer.
This security mechanism protects user devices because it ensures that USB debugging and other adb commands cannot be executed unless you're able to unlock the device and acknowledge the dialog.
This requires that you have adb version 1.0.31 (available with SDK Platform-tools r16.0.1 and higher) in order to debug on a device running Android 4.2.2 or higher.

If you haven't this pop-up mesage in your device, there is the solution :

1) Install SDK in your PC
It may asks you to install JAVA, if so, do it.

2) make sure that your adb is 1.0.31 or upper, to know the version, tape : adb version in your commande window
------------------------------------

After that you every thing will be OK
The Following 21 Users Say Thank You to nouvelle_adr For This Useful Post: [ View ] Gift nouvelle_adr Ad-Free
2nd September 2013, 11:59 PM |#8  
MadMan29729's Avatar
Member
Flag Richburg
Thanks Meter: 26
 
Donate to Me
More
Thumbs up this solved my problem
problem was i had ran this command

sudo apt-get install android-tools-adb

which installed Android Debug Bridge version 1.0.29 in /usr/bin

the system was using this by default even tho i added the platform-tools directory with the newest adb (Android Debug Bridge version 1.0.31) to my environment path.

This solved this problem (running old adb) on LinuxMint:

Method 1:

sudo apt-get remove android-tools-adb

Method 2: (if the first doesn't work)

unplug device
adb kill-server
adb version
Android Debug Bridge version 1.0.29
cd to android sdk dir
cd /home/XXX/adt-bundle-linux-x86_64/sdk/platform-tools/
copy new adb to /usr/bin
sudo cp adb /usr/bin/
adb version
Android Debug Bridge version 1.0.31
adb kill-server
adb devices
daemon not running. starting it now on port 5037 *
daemon started successfully * List of devices attached
plug in the device, and on the device dialog about RSA appeared
accept on device
adb devices

hope this helps...

credit for this solution goes to CoPLaS @ this URL
http://stackoverflow.com/questions/1...version-1-0-29
The Following 15 Users Say Thank You to MadMan29729 For This Useful Post: [ View ] Gift MadMan29729 Ad-Free
8th September 2013, 09:45 AM |#9  
Senior Member
Thanks Meter: 105
 
More
I've ADB problem in bootloader mode: devices not found, list empty. It works fine with phone in normal mode

I've upgraded to adb .31, upgraded drivers but no solution, BTW fastboot devices corectly displays device

Any help ?

Thanks
9th September 2013, 03:53 AM |#10  
MadMan29729's Avatar
Member
Flag Richburg
Thanks Meter: 26
 
Donate to Me
More
Quote:
Originally Posted by ciano865

I've ADB problem in bootloader mode: devices not found, list empty. It works fine with phone in normal mode

I've upgraded to adb .31, upgraded drivers but no solution, BTW fastboot devices corectly displays device

Any help ?

Thanks

as far as I know adb doesn't work in bootloader mode.
The Following 2 Users Say Thank You to MadMan29729 For This Useful Post: [ View ] Gift MadMan29729 Ad-Free
9th September 2013, 11:30 AM |#11  
Senior Member
Thanks Meter: 105
 
More
Quote:
Originally Posted by MadMan29729

as far as I know adb doesn't work in bootloader mode.

How can I push file to phone it doesn't boot ?
Post Reply Subscribe to Thread

Tags
adb

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes