Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
4
Question by The_Main_Character · Sep 25, 2015 at 02:41 PM · androidunity 5buildmobileandroid build

Unity android Unable to forward network traffic to device

Tried building to phone for testing today and am getting this error: alt text and the 2 console error reports:

 CommandInvokationFailure: Unable to forward network traffic to device. Please make sure the Android SDK is installed and is properly configured in the Editor. See the Console for more details. 
 D:/androidsdk/platform-tools\adb.exe -s "4f0c7edb" forward "tcp:54999" "localabstract:Unity-com.maincharacter.test"
 
 stderr[
 error: cannot bind to socket: No error
 error: cannot bind to socket: No error
 ]
 stdout[
 
 ]
 UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
 UnityEditor.Android.ADB.RunInternal (System.String[] command, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
 UnityEditor.Android.ADB.Run (System.String[] command, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
 UnityEditor.Android.AndroidDevice.Exec (System.String[] command, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
 UnityEditor.Android.AndroidDevice.Forward (System.String pc, System.String device, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit)
 UnityEditor.Android.PostProcessAndroidPlayer.UploadAndStartPlayer (System.String manifestName, System.String stagingArea, UnityEditor.Android.AndroidDevice device, System.String packageName, Boolean developmentPlayer, Boolean retryUpload)
 UnityEditor.Android.PostProcessAndroidPlayer.PostProcessInternal (BuildTarget target, System.String stagingAreaData, System.String stagingArea, System.String playerPackage, System.String installPath, System.String companyName, System.String productName, BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry)
 UnityEditor.Android.PostProcessAndroidPlayer.PostProcess (BuildTarget target, System.String stagingAreaData, System.String stagingArea, System.String playerPackage, System.String installPath, System.String companyName, System.String productName, BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry)
 UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()

and:

 Error building Player: CommandInvokationFailure: Unable to forward network traffic to device. Please make sure the Android SDK is installed and is properly configured in the Editor. See the Console for more details. 
 D:/androidsdk/platform-tools\adb.exe -s "4f0c7edb" forward "tcp:54999" "localabstract:Unity-com.maincharacter.test"
 
 stderr[
 error: cannot bind to socket: No error
 error: cannot bind to socket: No error
 ]
 stdout[
 
 ]
 

I'm on Unity5 with android SDK rev 24.3.4. Any help here would be awesome. If you'll pardon the cliche, It was working fine yesterday.

err.png (33.3 kB)
Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image androidrobotfactory · May 16, 2017 at 12:18 AM 0
Share

I'm using Unity 2017.1.0xb3 on Linux. I'm getting the following error

CommandInvokationFailure: Unable to forward network traffic to device. Please make sure the Android SD$$anonymous$$ is installed and is properly configured in the Editor. See the Console for more details.

platform-tools/adb -s "DEVICE" forward "tcp:34999" "localabstract:Unity-com.package" stderr[ error: cannot bind listener: Address already in use ]

Unity is listening on port 34999. I've tried build settings, disable "Development Build" and "adb forward --remove-all" no effect. I'm using the latest android sdk tools (sdk-tools-linux-3859397.zip). I also tried tools_r25.2.5-linux.zip but got the same error.

Any idea's?

Thanks

7 Replies

· Add your reply
  • Sort: 
avatar image
6

Answer by aeroson · Oct 25, 2015 at 12:02 PM

Worked around it by disabling Development Build in Build Settings, Debug.Log* still works

alt text


doahep3.png (40.6 kB)
Comment
Add comment · Show 6 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Talimar · Nov 28, 2015 at 04:39 AM 1
Share

Worked for me too after this started happening in 5.2.3. What have they done....

avatar image christianstrang · Nov 28, 2015 at 01:36 PM 0
Share

Worked for me as well

avatar image darkoverlordofdata · Nov 28, 2015 at 05:27 PM 0
Share

Works here as well - version 5.1.0f3

avatar image jprocha101 · Feb 13, 2016 at 12:09 AM 1
Share

Same issue here, except that is not a fix. What if I want Development Build checked because I want to run the profiler?

avatar image Wicaodian · Jul 22, 2016 at 10:03 AM 0
Share

thank you it worked

Show more comments
avatar image
2

Answer by androidrobotfactory · May 17, 2017 at 07:22 AM

I'm using Unity 2017.1.0xb3 on Linux. I'm getting the following error

CommandInvokationFailure: Unable to forward network traffic to device. Please make sure the Android SDK is installed and is properly configured in the Editor. See the Console for more details.

platform-tools/adb -s "DEVICE" forward "tcp:34999" "localabstract:Unity-com.package" stderr[ error: cannot bind listener: Address already in use ]

Unity is listening on port 34999. I've tried build settings, disable "Development Build" and "adb forward --remove-all" no effect. I'm using the latest android sdk tools (sdk-tools-linux-3859397.zip). I also tried tools_r25.2.5-linux.zip but got the same error.

Any idea's?

Thanks

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image MikhailTm · May 26, 2017 at 01:14 PM 1
Share

I am having the same issue, could you solve it in the meantime?

avatar image
1

Answer by Xakiru · Sep 19, 2016 at 04:58 PM

Hi, Here is my fix :

Open Cmd with admin permissions and run this command:

netstat -a -o -n | find "54999"

This will show the id of the proccess let's say it shows :

TCP 0.0.0.0:54999 0.0.0.0:0 LISTENING 14824

Just write :

taskkill /F /PID 14824

To make sure everything is clean, you can run things manually before opening unity. :

adb forward --remove-all

adb -s "4f0c7edb" forward "tcp:54999" "localabstract:Unity-com.maincharacter.test"

I hope this helps someone. Thanks;
Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image huyakinemota · Dec 18, 2017 at 06:54 PM 0
Share

this process in my case was Unity itself :D

avatar image imfaraz101 · Apr 07, 2018 at 07:05 PM 0
Share

For me, it is not working.

avatar image AlienTechLAB imfaraz101 · Apr 07, 2018 at 09:49 PM 0
Share

Try this: https://youtu.be/bgYcJvL15$$anonymous$$o

avatar image imfaraz101 AlienTechLAB · Apr 07, 2018 at 10:02 PM 0
Share

I just restarted my phone and it worked.

avatar image
0

Answer by darkoverlordofdata · Oct 07, 2015 at 07:09 PM

I get the same issue runing on Linux Mint when I use 'Build And Run'. If I only do the build, it generates the apk. When I manually install that apk, it works perfectly. I am also able to run 'cordova run android' in the same environment, and it works. I don't think its the SDK, it appears to me that the install fails and throws an invalid error message.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by Thorny2000 · Jul 11, 2016 at 09:01 PM

I found updating to the latest JDK fixes the issue (and you can leave development build checked).

Remember to set the new path in Edit->Preferences->External Tools.

Also I found USB 3.0 ports won't work on my PC, has to be a USB 2.0. That is probably more down to the USB driver for my LG G3 though.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
  • 1
  • 2
  • ›

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

17 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Error Building Android Player : Win32 Exception 0 Answers

Android build error: unrecognized pixel format 264 0 Answers

Android Build Shows Background When Scene Transitions 0 Answers

Cannot build for Android (Failed to Move File) 1 Answer

Android input only works with remote 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges