the other day i was editing a layout when suddendly eclipse freeze for a long time and when it came back I couldn't run the application nor edit the layout anymore. I reboot my PC and I was able again to run the app but the LogCat doesn't work anymore.
This are some screens:
Can somebody tell me what is happening ?
Open CMD and write adb -d logcat <your package name>:<log level> *:S. If you don't get any logs maybe your Android SDK is somehow broken or damaged and try reinstalling it.
Related
I'm very new to Android Studio. I have been using it on Windows but the machine was too old to run any of the emulators so I installed it (via Ubuntu Software store) on a laptop running Unbuntu 18.04.
It all seems to work OK except the Logcat does not show anything. Sometimes, after cold starting the emulator, I get some output to the Logcat but then it just halts and nothing I do (see below) causes it to output anything else.
I cannot get ANY output when running an app.
I have searched extensively here and via Google and tried the following:
restarted the Studio
restarted logcat
killed and restarted adb
invalidate caches and restart AS
deleting and recreating AVDs
use logcat via AS built in terminal and external shell :
./adb -s emulator-5554 logcat
and get:
Unable to open log device '/dev/log/main': No such file or directory
NB: When using an attached phone e.g. Moto G. the logcat works fine. I get all the system output and the app output works as expected.
Thanks in advance
2019-12-14 UPDATE: when the emulator is running it shows the active processes (see screenshot) in the drop down, including my app but NO entries. Not sure if this gives anyone a clue? It is clearly communicating with the emulator in some way.
2019-12-16 UPDATE: Started in from scratch. Installed MX Linux 19 and fresh Studio install. Created new AVD. EXACTLY THE SAME!!! This is so ridiculous. Anyone, please?
sometimes you might be trying to use a gun to kill a fly. For a try, ensure that the emulator you have run is actually selected in logcat like in this screen shot
.
when trying to run adb devices no output is shown at all not even a empty list. The terminal waits as if it is going to load, but then it just creates a new line prompt as if I hadn't given the adb command.
No no devices found is displayed or any indication that the bridge is running, literally nothing is displayed.
When trying to open the uiautomatorview I receive this error E/adb: Unable to detect adb version, adb output:
Solutions I have already tried:
checking system variables
changing the directory to run out of platform-tools directly
checked port 5037 for other processes
replacing the adb.exe
uninstalled and re installed android studios
replacing just the SDK tools and platform tools
uninstalled and reinstalled java
Please can someone help?
I've run into this problem at least a few times already, every time I just turned off and on my mac again and it started to work again. I don't know why it happens though.
And I know it's not the perfect solution, but it worked, so I just thought I'm gonna share it with the others.
By the way restarting the mac didn't solve the problem, only turning it off and on again.
I'm struggling a bit with Logcat. The phone disconnects from LogCat with the message "Device Disconnected" every time I push a button changing intents in my program.
What can cause this? And Why? Could it be my code throwing a error disconnecting LogCat? Or is this a LogCat issue?
I'v tried to restart eclipse, and stop the adb.exe process with no luck.
: E/(): Device disconnected
There may be some sync problem in DDMS. Just restart the eclipse it will work fine.
This is a real problem in Eclipse DDMS. If you run adb logcat at the same time that Eclipse shows "device disconnected" you will most likely still see logcat output (this is what happens in my case). Only real explanation I can see is that DDMS has a bug.
My solution? Switch to IntelliJ. It doesn't have the same problem, or any similar problems that Eclipse DDMS has connecting to devices which are recognized by adb.
Here is commented a solution that works for me, Clear Log:
LogCat Stops Running in Eclipse Needs Restart
I restarted my device, closed eclipse, used a command prompt opened at android-sdk/platform-tools to run adb kill-server, reopened eclipse, and then used that same command prompt to run adb logcat.
My problem was then fixed, though I'm not sure which step fixed it.
Just Type This Command In Terminal
adb devices
u should see this log:
List of devices attached
adb server version (40) doesn't match this client (36); killing...
* daemon started successfully *
FA57NY900383 device
And Run Again, Your application starts to run on your device
So I resolved the issue. I'm not sure what part did the trick, but I noticed javaw.exe was running on the computer even though eclipse was closed. So I forced closed this one, unfortunately I also re-installed my Jelly Bean ROM. So I'm not sure what exactly did the trick. I bet it was the phone though.
I had this same problem where it kept saying "Device Disconnected" when I could clearly hit Debug and select my phone, but for some reason I was expecting the LogCat to already be going.
But it will not be going if the phone is locked (facepalm).. After unlocking it seems fine.
Hope this helps someone else that doesn't realize their phone is locked when trying to debug / use LogCat.
I am using Eclipse 4.2.1 (Juno).
My Android Virtual Device Manager does not launch. I press on the button and literally nothing happens (no error message).
I've tried reinstalling the Android SDK, ADT and Eclipse but nothing helps to fix this issue.
Any ideas on how to fix this issue?
I ran into the same problem when relocating my entire developement directory. Deleting the folder and relaunching Eclipse resolved it.
Had the same problem. After several reinstalls, restarts and what not, I finally figured it out:
open cmd, run android avd from sdk\tools folder. You'll probably get an exception that you can google, which is already better than no response at all...
This is what I got:
java.lang.NullPointerException
at com.android.sdklib.internal.avd.AvdInfo.getDeviceName(AvdInfo.java:158)
What did the trick for me was deleting the folder C:\Users\<User>\.android\avd.
In this case reinstalling will help
get the android development package from developers site.....
and you can try by running in a new User Account in your PC
some times it workss!!!
all the best!
Close Eclipse
Kill adb through command line with command adb kill-server
Now start task manager and kill adb process also from there if running from the process tab
Now start your adb again from command line with adb start-server
-Now start your Eclipse again and run your application
Try!!
In my case this was a problem with old /tmp/android-username/emulator-* files.
I found it out by running manually my predefined arm AVD named "Test"
$ cd adt-bundle-linux-x86_64-20130522/sdk/tools
$ ./emulator64-arm -avd Test
NAND: could not write file /tmp/android-username/emulator-gKbQ19, File exists
Removing old emulator files from /tmp/android-username resolved the problem.
rm /tmp/android-username/emulator-*
few days before when i was trying to run my apps the following type of error used to occur
[2011-02-24 20:33:41 - FlashCard] Installation error: INSTALL_FAILED_INSUFFICIENT_STORAGE
[2011-02-24 20:33:41 - FlashCard] Please check logcat output for more details.
[2011-02-24 20:33:41 - FlashCard] Launch canceled!
i used to close the eclipse or shut down my system, then it gets cleared.
Later it happens to occur often, i got a suggestion from stack overflow to enter command
adb start-server and adb kill-server in run cmd, the idea worked only for two days.
Right from today morning i am trying to run all my apps and the same error continues.
The adb server idea is not working, i have tried updating my eclipse too.
i am posting this just to get an idea about this problem, as i am new to android development and java.
if anyone have any solution or idea pls share it.
Please follow below link for the solution
Solution to INSTALL_FAILED_INSUFFICIENT_STORAGE error on Android
and top of this try to clear other application's data from the setting->application->manage application
Have you tried freeing up space on your device/emulator by uninstalling apps?