Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
View Poll Results: Is this thread noob-friendly for taking logcat?
Yes 3 100.00%
No 0 0%
May or May not be 0 0%
Voters: 3. You may not vote on this poll

Post Reply

[GUIDE][NOOB-FRIENDLY] How to take logcat

OP Niku-Droid

6th June 2014, 07:38 AM   |  #1  
OP Member
Thanks Meter: 16
 
41 posts
Join Date:Joined: May 2014
More
So,
SGS users, here is my another thread, for guys, who want to help devs of our sgs community.

Devs asking you to get a logcat and give?? Yes it helps a lot for devs if you give logcat to solve problem. So dont wait till devs ask you to get a logcat! Just give them a logcat when you tell them this/that doesnt work. This way theirs and yours time will be saved and unnecessary posts will be avoided.
Now i will give you simple steps to do it. There are two main ways to do a logcat, 1. within android device, and 2. through adb using PC.
WITHIN ANDROID DEVICE METHOD:
  • 1. Logcat within android device can be done in one of two ways, through a Logcat app: Difficulty --> Very Easy
    Here are two good apps: aLogcat or Catlog
    Both of these programs can dump their logs to a text file, which is very useful for debugging. Or, you can do it in terminal emulator (same rules as running through adb(see below))

  • 2. Through Terminal method: Difficulty --> Almost Easy
  • Install Android Terminal Emulator app from Play Store..
  • Open terminal app you just installed..
  • Enter these commands:
  • After every command press ENTER/SUBMIT button
    Code:
    su
  • then accept the superuser popup message[it comes only first time if you select checkbox "remember the choice"]
    Code:
    logcat -v long > /sdcard/test.log
    Or use this command:

    The -v long puts the text in a nice format that is more easily readable. The *:W will search for all warnings, errors, and fatals, while the *:S will silence everything else.
    So essentially, u will have a .txt file that has a log of all warnings and up, nothing else, and it'll look pretty too!
    Code:
    logcat -v long *:W*:S > /sdcard/filename.txt
  • now press home button to minimize the terminal..
  • and do the task which is giving problems/ whichever task log you need to give to dev..
  • then drag the notification bar..
  • select terminal app in it..
  • now press and hold "Volume down button" and touch c button on keyboard.
  • This will stop the command..
  • now use this command twice
    Code:
    exit
  • Now app will get closed. go to sdcard to find test.log file.. upload it to here so that dev can access it..

Thank you for reading it with patience hope you can get logcat now..


Note: if you are stuck in boot and want to take logcat.. READ LOGCAT FROM ADB METHOD BELOW.. the above one is simple method for these tasks for eg.. if you are having some force close of app/lag etc.. then after entering second command press enter and then use home button to minimize terminal.. dont worry it will take log.. now open that app and once it gives force close then click on it and then open terminal again and press volume down button + c to terminate command.. then use exit command two times... done.. now go to sdcard and find a.txt file


From PC[i.e, ADB] LOGCAT METHOD :Difficulty --> Medium

There is an advantage here. As doing this way, you can start using logcat when your device boots. There are 2 ways here again..

PREPARATION:
  • In your android device, go to settings --> applications --> development -->
  • Check USB Debugging
  • Make sure your device driver is already installed otherwise install kies software which will install drivers too.. Get kies from This LINK
  • You need to download this ADB.zip file i made to your system.. Download link
  • Extract the ADB.zip file from any applications like IZarc/7Zip/winzip/winrar.

ADB USAGE INSTRUCTIONS:
  • Then go to Android folder.. inside that you should find 3 files.. Now open a command prompt or terminal in that path..(wherever you extracted it.. use cd command)
    Then inside that path.. type
    Code:
    adb logcat > filename.txt
    Or
    Code:
    logcat -v long > /sdcard/test.log
    Or
    Code:
    logcat -v long *:W*:S > /sdcard/filename.txt
  • Now perform tasks in android device of which you need to give logcat for the devs. Then use CTRL+C to end the command.
  • Now find the filename.txt inside the Android folder which has logcat. Upload this file and give link to dev..

The full list of options that can be used with logcat command is as follows:
  • V Verbose (lowest priority)
  • D Debug
  • I Info (default priority)
  • W Warning
  • E Error
  • F Fatal
  • S Silent (highest priority, on which nothing is ever printed)

You can replace the *:W with any other letter from above to get more info.
Last edited by Niku-Droid; 6th June 2014 at 12:56 PM.
The Following 2 Users Say Thank You to Niku-Droid For This Useful Post: [ View ]
6th June 2014, 07:45 AM   |  #2  
OP Member
Thanks Meter: 16
 
41 posts
Join Date:Joined: May 2014
More
CREDITS
CRESITS ;
I) @Niku-Droid
II)www.google.com
III) XDA Threads, as this information is taken up from threads of XDA only

Oh! I missed someone, Send me a PM
Last edited by Niku-Droid; 6th June 2014 at 12:57 PM.
6th June 2014, 11:33 AM   |  #3  
T3snake's Avatar
Senior Member
Flag Vadodara
Thanks Meter: 497
 
949 posts
Join Date:Joined: Dec 2013
More
hmn nice thread
most guides are user friendlyy if the ppl read a few sentences
just like all other threads the self aclaimed noobs will just ignore this thread and when asked for logcats theyll just post how to take logcat when they can just type that up at google or had read here


also im not able to take logcat at boot can u post up how to do that

Sent from my GT-S5282 using Tapatalk
6th June 2014, 12:54 PM   |  #4  
OP Member
Thanks Meter: 16
 
41 posts
Join Date:Joined: May 2014
More
Smile
Quote:
Originally Posted by T3snake

hmn nice thread
most guides are user friendlyy if the ppl read a few sentences
just like all other threads the self aclaimed noobs will just ignore this thread and when asked for logcats theyll just post how to take logcat when they can just type that up at google or had read here


also im not able to take logcat at boot can u post up how to do that

Sent from my GT-S5282 using Tapatalk

hmm... dont worry bro, we will give them link to this thread when they ask this silly question n hv u tried taking logcat using adb, i m sure that it can take logcat as soon as device is booted
6th June 2014, 06:34 PM   |  #5  
T3snake's Avatar
Senior Member
Flag Vadodara
Thanks Meter: 497
 
949 posts
Join Date:Joined: Dec 2013
More
Quote:
Originally Posted by Niku-Droid

hmm... dont worry bro, we will give them link to this thread when they ask this silly question n hv u tried taking logcat using adb, i m sure that it can take logcat as soon as device is booted

of course i used adb
i want to take logcat while star is booting
but device doesnt show in adb until the booting is complete
Post Reply Subscribe to Thread

Tags
galaxy star, how to take logcat, niku-droid, root galaxy star
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes