karan
karan

Reputation: 8853

Logcat doesn't show anything

I was working on my Android application and using Eclipse to build it and displaying some values in Android Logcat.

Everything was working fine, but suddenly now when I run my application, Logcat does not shows anything. I tried to run my other application, but still it remains blank.

What is reason for this behavior, how can I get it back working again?

Upvotes: 19

Views: 22972

Answers (6)

Sravani
Sravani

Reputation: 528

When LogCat doesn't show up the Log.i() or any information:

Try:

  1. Check for the target set properly.

  2. Go to your sdk folder-->platform-tools

    press the Ctrl+Shift and mouse right click at the empty place and select open command window here to open command window.

    Now enter the following two commands to kill the adb and re-start it.

    adb kill-server

    adb start-server

  3. And then finally restart your eclipse.

I have faced the same problem. This worked perfectly.

Upvotes: 2

scottt
scottt

Reputation: 8371

While restarting the DB server from the command-line works great, there's an alternative methodto reset ADB from within Eclipse. Open the DDMS perspective, click on the dropdown menu in the Devices tab's toolbar, and select the "Reset adb" menu item. Device dropdown menu

Upvotes: 2

beheshtraya
beheshtraya

Reputation: 61

I had the same problem. It's because the Proxifier is running on my machine. You cannot use this tool in eclips when you have running network proxy, port scanning and this kind of programs.

Upvotes: 0

Jorge Casariego
Jorge Casariego

Reputation: 22212

It happened to me as well but I think the problem is in the DDMS.

You can try the following:

  • Open DDMS perspective
  • Go to the Devices tab (If you have no open go to Windows -> Show Views -> Devices)
  • Click on the open emulator and you should see the log again

Upvotes: 4

Michal
Michal

Reputation: 6683

Sometimes this problem occurs when you run on your PC two instances of Eclipse, for example on different workspaces. So, to avoid repeating problem you should use only one instance of eclipse.

To repair logging you should do following steps:

  1. Unplug the device
  2. Close all Eclipse windows
  3. Restart adb in command line: adb kill-server and than adb start-server
  4. Run again Eclipse and connect device

Sometimes help other method. Go to Eclipse Window > Perspective > DDMS and than from Device sub-window choose Reset adb

Upvotes: 7

Ahmad
Ahmad

Reputation: 72553

Try this:

On Linux or Mac OS X:

./adb kill-server
./adb start-server

On Windows:

adb kill-server
adb start-server

This will restart the adb and everything should work fine.

Upvotes: 27

Related Questions