DDMS throwing ADB error since SDK API 9 upgrade
Asked Answered
L

3

6

I upgraded to Gingerbreak 2.3 SDK today and started receiving this error when I try to run DDMS:

Failed to get adb version: Cannot run program "adb": CreateProcess error=2, The system cannot find the file specified.

How can I fix this? Running Windows 7, 64bit.

Lenna answered 7/12, 2010 at 15:37 Comment(1)
Gingerbreak - that's just about the right title for it as far as I'm concerned - it's broken everything on my machine!Maddocks
L
15

It seems that adb.exe is now in the SDK's platform-tools folder. I had to add the platform-tools folder to my PATH in my Environment Variables.

Lenna answered 7/12, 2010 at 15:38 Comment(3)
Isn't the question about DDMS.bat ? How do you run it without using Eclipse's DDMS perspective ? It gives me the same error after API 9 update. EDIT : Oops. Bryan, you have asked the question. Didn't notice it. Will set the adb path and will let know if if fixes in my machine. [FIXED] Bryan's solution fixes it ! Add the android\platform-tools\ to PATH. In my case, it was C:\eclipse\android\platform-tools\Inexpungible
I've always ran DDMS by going to the Android SDK directory, Tools, DDMS.bat. The problem is they moved the adb.exe around so DDMS couldn't find it unless you add it globally.Lenna
Yup. I used to do the same thing. Eclipse's DDMS perspective seemed to work fine even after the update and \tools\ddms.bat did break. Thanks ! It's fixed now.Inexpungible
K
2

I tried to upgrade my perfectly working Android dev system yesterday with the new 2.3 SDK and associated ADT. After the upgrade, I couldn't get Eclipse to compile my project correctly, nor could I access the Android SDK and AVD Manager from Eclipse. Eclipse seems to have lost track of where the Android SDK was installed. I would give it the name of the folder, but then it could come back saying it couldn't find .../tools/adb.exe. Yes I know adb.exe moved. But notice that the error was looking for it in the old spot. It's like I didn't have the new ADT, but I checked and rechecked and I did. I'm thinking that the new ADT didn't install correctly for some reason, and/or I wasn't checking it's version properly.

When I searched around for a solution, everyone pointed out that adb moved and that the classpath needed to change. But there isn't really a relevant classpath in this situation. There is just a path to the Android SDK that needs to be set in Eclipse. I even tried the trick were I copied adb.exe back to the tools folder. At that point, Eclipse could find the Android SDK, but then some other problem that crept up so I gave up on that hole.

Anyway, I ended up blowing away my eclipse and Android SDK folders and starting over. Now it works fine. I'm sure there's a better solution, but I was sick of messing with it.

I'm now 2 for 4 on using Android SDK and AVD Manager to do an upgrade.

Hope this helps someone.

Update: Upon further review, I seem to have my stackoverflow topics mixed up since the OP never mentioned Eclipse.

Kariekaril answered 9/12, 2010 at 0:56 Comment(1)
I'd updated my Android-SDK using the Android tool and was having a similar problem. I had to update Eclipse's software packages via the Help Menu - Software Updates selection. I then chose to update the ADT package and the other Android related one after this the original error message had vanished.Wimble
L
0

I had the same problem and it works like this . First run adb.exe , after open ddms.bat

Lovash answered 24/1, 2013 at 14:22 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.