Unable to debug device: lge-nexus #14

Open
gsingh93 opened this Issue May 19, 2013 · 40 comments

Comments

Projects
None yet
@gsingh93

The ViewServer class isn't working on my device. I keep getting the following error:

12:16:52 E/ViewServerDevice: Unable to debug device: lge-nexus_4-04848005ded98f1f
12:16:52 E/hierarchyviewer: Missing forwarded port for 04848005ded98f1f
12:16:52 E/hierarchyviewer: Unable to get view server version from device 04848005ded98f1f
12:16:52 E/hierarchyviewer: Missing forwarded port for 04848005ded98f1f
12:16:52 E/hierarchyviewer: Unable to get view server protocol version from device 04848005ded98f1f

@JarrodBoyes

This comment has been minimized.

Show comment
Hide comment
@JarrodBoyes

JarrodBoyes May 30, 2013

I'm having a similar issue since the most recent update to the Android SDK / tools:

[2013-05-31 09:15:38 - hierarchyviewer]Unable to get view server version from device 0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Unable to get view server protocol version from device 0146B0000D00D015
[2013-05-31 09:15:38 - ViewServerDevice]Unable to debug device: samsung-galaxy_nexus-0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Missing forwarded port for 0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Unable to get the focused window from device 0146B0000D00D015

I'm having a similar issue since the most recent update to the Android SDK / tools:

[2013-05-31 09:15:38 - hierarchyviewer]Unable to get view server version from device 0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Unable to get view server protocol version from device 0146B0000D00D015
[2013-05-31 09:15:38 - ViewServerDevice]Unable to debug device: samsung-galaxy_nexus-0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Missing forwarded port for 0146B0000D00D015
[2013-05-31 09:15:38 - hierarchyviewer]Unable to get the focused window from device 0146B0000D00D015

@mrunaln

This comment has been minimized.

Show comment
Hide comment
@mrunaln

mrunaln Aug 7, 2013

I am seeing a very similar issue...

01:45:06 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803
01:45:06 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:06 E/hierarchyviewer: Unable to get the focused window from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server version from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server protocol version from device 015d262e2d3bf803
01:45:27 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803

Was anyone able to get it working?

mrunaln commented Aug 7, 2013

I am seeing a very similar issue...

01:45:06 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803
01:45:06 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:06 E/hierarchyviewer: Unable to get the focused window from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server version from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server protocol version from device 015d262e2d3bf803
01:45:27 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803

Was anyone able to get it working?

@MorrisonCole

This comment has been minimized.

Show comment
Hide comment
@MorrisonCole

MorrisonCole Aug 8, 2013

Almost certainly related to 4.3.3. I'm getting a similar error on my updated devices, but the same app is working on 4.3.2.

Almost certainly related to 4.3.3. I'm getting a similar error on my updated devices, but the same app is working on 4.3.2.

@Rao27

This comment has been minimized.

Show comment
Hide comment
@Rao27

Rao27 Aug 15, 2013

I am having same problem in my eclipse. I am getting same message when i launch any AVD or when i attach any android device. Does anyone know how to solve this issue? And Does anyone know what is the reason behind this? And I think because of this application is not getting launched in my device. Eclipse is showing that launching (100%) but no app launch in device.

Rao27 commented Aug 15, 2013

I am having same problem in my eclipse. I am getting same message when i launch any AVD or when i attach any android device. Does anyone know how to solve this issue? And Does anyone know what is the reason behind this? And I think because of this application is not getting launched in my device. Eclipse is showing that launching (100%) but no app launch in device.

@david-sabata

This comment has been minimized.

Show comment
Hide comment
@david-sabata

david-sabata Sep 30, 2013

Same problem here. Nexus 4 running stock Android 4.3

Same problem here. Nexus 4 running stock Android 4.3

@JefStat

This comment has been minimized.

Show comment
Hide comment
@JefStat

JefStat Oct 30, 2013

I get it partially working if I ran HierarchyViewer after I was at the screen with the view I wanted to see. I can inspect a screen shot but load view hierarchy is disabled. I tried on a 4.2.2 Samsung and have the same issue with Load View Hierarchy disabled.

JefStat commented Oct 30, 2013

I get it partially working if I ran HierarchyViewer after I was at the screen with the view I wanted to see. I can inspect a screen shot but load view hierarchy is disabled. I tried on a 4.2.2 Samsung and have the same issue with Load View Hierarchy disabled.

@Sheikh-Aman

This comment has been minimized.

Show comment
Hide comment
@Sheikh-Aman

Sheikh-Aman Dec 8, 2013

Same here..
Galaxy Nexus with 4.3.3
Hoping either Romain or Jake sees it..

Same here..
Galaxy Nexus with 4.3.3
Hoping either Romain or Jake sees it..

@timtrueman

This comment has been minimized.

Show comment
Hide comment
@timtrueman

timtrueman Dec 11, 2013

I'm still seeing this issue too, on a Nexus 5 running 4.4.2.

I'm still seeing this issue too, on a Nexus 5 running 4.4.2.

@vanshu

This comment has been minimized.

Show comment
Hide comment
@vanshu

vanshu Dec 11, 2013

Anybody try root the device already? my nexus5 works well because it's rooted device, however my galaxy nexus (not root) not working with same problem ,is this reason cause the error?

vanshu commented Dec 11, 2013

Anybody try root the device already? my nexus5 works well because it's rooted device, however my galaxy nexus (not root) not working with same problem ,is this reason cause the error?

@izBasit

This comment has been minimized.

Show comment
Hide comment
@izBasit

izBasit Dec 23, 2013

Unable to connect my Samsung Galaxy Tab 2. Running 4.1.2.

izBasit commented Dec 23, 2013

Unable to connect my Samsung Galaxy Tab 2. Running 4.1.2.

@romainguy

This comment has been minimized.

Show comment
Hide comment
@romainguy

romainguy Dec 25, 2013

Owner

Make sure you have the INTERNET permission declared in your manifest.

Owner

romainguy commented Dec 25, 2013

Make sure you have the INTERNET permission declared in your manifest.

@timtrueman

This comment has been minimized.

Show comment
Hide comment
@timtrueman

timtrueman Dec 27, 2013

Hmm, I have that set in my manifest but it does not work for me…

Hmm, I have that set in my manifest but it does not work for me…

@rohandhruva

This comment has been minimized.

Show comment
Hide comment
@rohandhruva

rohandhruva Jan 22, 2014

I'm seeing the same on my Moto X: the app definitely has ViewServer, but Hierarchy Viewer shows

[2014-01-21 18:12:28 - ViewServerDevice]Unable to debug device: motorola-xt1058-T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Missing forwarded port for T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Unable to get view server version from device T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Missing forwarded port for T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Unable to get view server protocol version from device T062202O9K
[2014-01-21 18:26:31 - ViewServerDevice]Unable to debug device: motorola-xt1058-T062202O9K

I'm seeing the same on my Moto X: the app definitely has ViewServer, but Hierarchy Viewer shows

[2014-01-21 18:12:28 - ViewServerDevice]Unable to debug device: motorola-xt1058-T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Missing forwarded port for T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Unable to get view server version from device T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Missing forwarded port for T062202O9K
[2014-01-21 18:26:31 - hierarchyviewer]Unable to get view server protocol version from device T062202O9K
[2014-01-21 18:26:31 - ViewServerDevice]Unable to debug device: motorola-xt1058-T062202O9K
@xtrawurst

This comment has been minimized.

Show comment
Hide comment
@xtrawurst

xtrawurst Jan 30, 2014

Seeing the same problem on a Nexus 7, running 4.4.2. I do have the INTERNET permission in my manifest. Do I have to import the project as a library or can I just use the java file as a standalone class?
Update: Tried it as a proper library in the ADT scheme of things. Still no luck. Would really like to inspect my view hierarchy. Any fix in sight?

Seeing the same problem on a Nexus 7, running 4.4.2. I do have the INTERNET permission in my manifest. Do I have to import the project as a library or can I just use the java file as a standalone class?
Update: Tried it as a proper library in the ADT scheme of things. Still no luck. Would really like to inspect my view hierarchy. Any fix in sight?

@drindt

This comment has been minimized.

Show comment
Hide comment
@drindt

drindt Feb 19, 2014

I got exactly the same issue on the nexus 7 with latest 4.4.2, sometimes this get fixed by reconnect the usb cable and killing adb. I was unable to find the issue to solve this properly.

drindt commented Feb 19, 2014

I got exactly the same issue on the nexus 7 with latest 4.4.2, sometimes this get fixed by reconnect the usb cable and killing adb. I was unable to find the issue to solve this properly.

@KOHOH1992

This comment has been minimized.

Show comment
Hide comment
@KOHOH1992

KOHOH1992 Feb 28, 2014

same Problem on Nexus7 with 4.4.2 .But when i run in an Android Virtual Device it's working.

same Problem on Nexus7 with 4.4.2 .But when i run in an Android Virtual Device it's working.

@Takhion

This comment has been minimized.

Show comment
Hide comment
@Takhion

Takhion Mar 20, 2014

Same here with ANY nexus device, rooted or not, running 4.3 or 4.4... :(

Takhion commented Mar 20, 2014

Same here with ANY nexus device, rooted or not, running 4.3 or 4.4... :(

@ivanbartsov

This comment has been minimized.

Show comment
Hide comment
@ivanbartsov

ivanbartsov Mar 20, 2014

Same issue, Nexus 7 4.4.2

Same issue, Nexus 7 4.4.2

@gturedi

This comment has been minimized.

Show comment
Hide comment
@gturedi

gturedi Apr 7, 2014

got same issue galaxy s4, android 4.4.2

gturedi commented Apr 7, 2014

got same issue galaxy s4, android 4.4.2

@mars3142

This comment has been minimized.

Show comment
Hide comment
@mars3142

mars3142 Apr 22, 2014

Same issue on Nexus 10 (Android 4.4.2).

Same issue on Nexus 10 (Android 4.4.2).

@lukesleeman

This comment has been minimized.

Show comment
Hide comment
@lukesleeman

lukesleeman Apr 29, 2014

Yep, same issue on a Nexus 7 with 4.4.2 . It definitely seems that something in the update broke it ....

Yep, same issue on a Nexus 7 with 4.4.2 . It definitely seems that something in the update broke it ....

@kierans

This comment has been minimized.

Show comment
Hide comment
@kierans

kierans May 1, 2014

I was able to get it working by changing BUILD_TYPE_USER => "userdebug"

Genymotion Samsung S3

kierans commented May 1, 2014

I was able to get it working by changing BUILD_TYPE_USER => "userdebug"

Genymotion Samsung S3

@romainguy

This comment has been minimized.

Show comment
Hide comment
@romainguy

romainguy May 1, 2014

Owner

Android 4.4 has an improved version of the system ViewServer which should work on consumer devices. Your app needs to be in debug mode for it to work. This means there is no need to use this version of ViewServer on 4.4 devices.

Owner

romainguy commented May 1, 2014

Android 4.4 has an improved version of the system ViewServer which should work on consumer devices. Your app needs to be in debug mode for it to work. This means there is no need to use this version of ViewServer on 4.4 devices.

@kierans

This comment has been minimized.

Show comment
Hide comment
@kierans

kierans May 1, 2014

I'm having to debug a rendering issue on an older device (4.1.1)

kierans commented May 1, 2014

I'm having to debug a rendering issue on an older device (4.1.1)

@SleeplessByte

This comment has been minimized.

Show comment
Hide comment
@SleeplessByte

SleeplessByte Jul 3, 2014

@romainguy I'm on 4.4.4. (ART) and I still get the

[2014-07-02 17:42:52 - hierarchyviewer]Missing forwarded port for DEVICEID
[2014-07-02 17:42:52 - hierarchyviewer]Unable to get view server protocol version from device DEVICEID
[2014-07-02 17:42:52 - ViewServerDevice]Unable to debug device: lge-nexus_4-DEVICEID

@romainguy I'm on 4.4.4. (ART) and I still get the

[2014-07-02 17:42:52 - hierarchyviewer]Missing forwarded port for DEVICEID
[2014-07-02 17:42:52 - hierarchyviewer]Unable to get view server protocol version from device DEVICEID
[2014-07-02 17:42:52 - ViewServerDevice]Unable to debug device: lge-nexus_4-DEVICEID
@FullPatrickJoin

This comment has been minimized.

Show comment
Hide comment
@FullPatrickJoin

FullPatrickJoin Oct 3, 2014

Same with Samsung Galaxy S4 and 4.4.2

Same with Samsung Galaxy S4 and 4.4.2

@gjritter

This comment has been minimized.

Show comment
Hide comment
@gjritter

gjritter Feb 5, 2015

I'm also not able to connect to my Nexus 4 or Nexus 5 using hierarchyviewer. I get similar messages to those posted by others on this thread:

[2015-02-05 11:30:16 - hierarchyviewer]Missing forwarded port for 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Unable to get view server version from device 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Missing forwarded port for 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Unable to get view server protocol version from device 06410bc10ae53800
[2015-02-05 11:30:16 - ViewServerDevice]Unable to debug device: lge-nexus_5-06410bc10ae53800

I'm running Android 4.4.4 on both, running an app that's in debug mode. @romainguy you mentioned that Android 4.4 has an improved version of the system ViewServer that should work on consumer devices; is there information anywhere on how to use/enable this? I'm having no luck tracking down any information about this.

gjritter commented Feb 5, 2015

I'm also not able to connect to my Nexus 4 or Nexus 5 using hierarchyviewer. I get similar messages to those posted by others on this thread:

[2015-02-05 11:30:16 - hierarchyviewer]Missing forwarded port for 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Unable to get view server version from device 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Missing forwarded port for 06410bc10ae53800
[2015-02-05 11:30:16 - hierarchyviewer]Unable to get view server protocol version from device 06410bc10ae53800
[2015-02-05 11:30:16 - ViewServerDevice]Unable to debug device: lge-nexus_5-06410bc10ae53800

I'm running Android 4.4.4 on both, running an app that's in debug mode. @romainguy you mentioned that Android 4.4 has an improved version of the system ViewServer that should work on consumer devices; is there information anywhere on how to use/enable this? I'm having no luck tracking down any information about this.

@ozodrukh

This comment has been minimized.

Show comment
Hide comment
@ozodrukh

ozodrukh Feb 21, 2015

I'm solved issue, try to close Android Studio window
run adb kill-server, adb start-server
and launch monitor work to me

I'm solved issue, try to close Android Studio window
run adb kill-server, adb start-server
and launch monitor work to me

@boiledwater

This comment has been minimized.

Show comment
Hide comment
@boiledwater

boiledwater Mar 10, 2015

I have similar issue...
01:45:06 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803
01:45:06 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:06 E/hierarchyviewer: Unable to get the focused window from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server version from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server protocol version from device 015d262e2d3bf803
01:45:27 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803

It is fixed according 'romainguy' comment.
Make sure you have the INTERNET permission declared in your manifest.

I have similar issue...
01:45:06 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803
01:45:06 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:06 E/hierarchyviewer: Unable to get the focused window from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server version from device 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Missing forwarded port for 015d262e2d3bf803
01:45:27 E/hierarchyviewer: Unable to get view server protocol version from device 015d262e2d3bf803
01:45:27 E/ViewServerDevice: Unable to debug device: asus-nexus_7-015d262e2d3bf803

It is fixed according 'romainguy' comment.
Make sure you have the INTERNET permission declared in your manifest.

@RPetrov

This comment has been minimized.

Show comment
Hide comment
@RPetrov

RPetrov Apr 17, 2015

I had the same problem, but i run monitor with environment:
~/work/android-sdk/tools$ ANDROID_HVPROTO=ddm monitor
And it works for me.

RPetrov commented Apr 17, 2015

I had the same problem, but i run monitor with environment:
~/work/android-sdk/tools$ ANDROID_HVPROTO=ddm monitor
And it works for me.

@frakc

This comment has been minimized.

Show comment
Hide comment
@frakc

frakc Apr 23, 2015

ozodrukh tip worked for me

frakc commented Apr 23, 2015

ozodrukh tip worked for me

@rafaelsm

This comment has been minimized.

Show comment
Hide comment
@rafaelsm

rafaelsm Apr 28, 2015

ozodrukh tip worked for me too.
Thanks!

ozodrukh tip worked for me too.
Thanks!

@ocampesato

This comment has been minimized.

Show comment
Hide comment
@ocampesato

ocampesato May 3, 2015

Nexus 7 2 (2012) with Android 5.1: problem solved with RPetrov tip (thanks!)

Nexus 7 2 (2012) with Android 5.1: problem solved with RPetrov tip (thanks!)

@nurne

This comment has been minimized.

Show comment
Hide comment
@nurne

nurne Jun 30, 2015

solution by @RPetrov worked for me!
ANDROID_HVPROTO=ddm sh monitor
Thanks!

nurne commented Jun 30, 2015

solution by @RPetrov worked for me!
ANDROID_HVPROTO=ddm sh monitor
Thanks!

@DASAR

This comment has been minimized.

Show comment
Hide comment
@DASAR

DASAR Jul 9, 2015

Thanks @RPetrov

ANDROID_HVPROTO=ddm monitor

working.

DASAR commented Jul 9, 2015

Thanks @RPetrov

ANDROID_HVPROTO=ddm monitor

working.

@JanKokalj

This comment has been minimized.

Show comment
Hide comment
@JanKokalj

JanKokalj Aug 10, 2015

ANDROID_HVPROTO=ddm sh monitor
worked for me

ANDROID_HVPROTO=ddm sh monitor
worked for me

@Kening

This comment has been minimized.

Show comment
Hide comment

Kening commented Nov 19, 2015

BTW, this ANDROID_HVPROTO solution is documented here:

http://developer.android.com/tools/performance/hierarchy-viewer/setup.html

@jemshit

This comment has been minimized.

Show comment
Hide comment
@jemshit

jemshit Jan 25, 2016

OK, made this work by opening app in Debug mode, then opening Monitor from Terminal (not from AStudio). But t does not show draw performance indicators (colourful dots)

jemshit commented Jan 25, 2016

OK, made this work by opening app in Debug mode, then opening Monitor from Terminal (not from AStudio). But t does not show draw performance indicators (colourful dots)

@milosmns

This comment has been minimized.

Show comment
Hide comment
@milosmns

milosmns May 5, 2016

Yeah, restarting ADB as root (Linux, Mac), closing Android Studio, and doing a clean install fixed it for me. I think it's related to the debug port which Studio takes away from everyone, so closing Studio alone would probably work.

milosmns commented May 5, 2016

Yeah, restarting ADB as root (Linux, Mac), closing Android Studio, and doing a clean install fixed it for me. I think it's related to the debug port which Studio takes away from everyone, so closing Studio alone would probably work.

@maolion

This comment has been minimized.

Show comment
Hide comment
@maolion

maolion Aug 30, 2016

Thanks @RPetrov

ANDROID_HVPROTO=ddm monitor

working. MAC OSX

maolion commented Aug 30, 2016

Thanks @RPetrov

ANDROID_HVPROTO=ddm monitor

working. MAC OSX

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment