How to check crash logs in XCODE in iphone sdk - ios5

i'm new to the iPhone application development, when i'm running my application in device application is crashing and giving following log in organizer
here is the log report :
Incident Identifier: 23B91310-BCEC-497B-821A-8CF8E709ACF7
CrashReporter Key: 3202fd13cd0c5e4ab0706615fabf36ebc9396206
Hardware Model: iPod4,1
OS Version: iPhone OS 4.3.5 (8L1)
Kernel Version: Darwin Kernel Version 11.0.0: Sat Jul 9 00:59:43 PDT 2011; root:xnu- 1735.47~1/RELEASE_ARM_S5L8930X
Date: 2012-08-22 10:45:15 +0530
Time since snapshot: 54 ms
Free pages: 588
Wired pages: 16800
Purgeable pages: 38
Largest process: BJS
Processes
Name UUID Count resident pages
BJS <312d3dae46e433f9982c26738e40060b> 36928 (jettisoned) (active)
debugserver <919dbac91c0e3133a517d6c7a99e667e> 184
SCHelper <f8cf7ee034ac3991a79d8c78e435c1e7> 131
Preferences <cbdecd3d02e031e48e9675235a51306c> 1045 (jettisoned)
springboardservi <5ab19f16a3973514b6d7d62201d6abde> 309
syslog_relay <344c7c41bec5360aae33f4fd412ea95f> 94
notification_pro <698dca6c4cba390a8017315bd25f18f8> 112
syslog_relay <344c7c41bec5360aae33f4fd412ea95f> 97
notification_pro <698dca6c4cba390a8017315bd25f18f8> 108
ptpd <6072e173aed83310b9b7589a70a24b0b> 580
talkmeim <eb62d6230d5f304f9819c6aebc2d2298> 1141 (jettisoned)
lsd <3fafa485b73836acb973d50feabd963a> 248
notifyd <9966082842de313a8e05a001c783faf4> 126
BTServer <01550e9527353eecae41ebee0f889603> 308
CommCenter <7d9446365b4836968ae361626ef8f939> 271
misd <8f94228bddf8342994baf5ca9af1154d> 154
SpringBoard <5c55c6fba0843b0e924e116413b8c9d4> 4143 (active)
accessoryd <d30e340e36df356bbde3347a6ed1ef87> 148
apsd <47ffc9ce9f84371588bd3f937aaa20bb> 285
configd <a6d457fca42732d9ba809d03a2b3e3ae> 401
fairplayd.N81 <144f0ff89c123fa5a1cfa40da72fb024> 165
imagent <9e0b26bad4a538a5b0e5e5ee7eeeb7be> 234
locationd <9088e845dcbe37d890c8758655bf34c6> 685
mDNSResponder <caf94711b8093dc5bc5736306f8ae818> 198
mediaremoted <21af791e80823c9f90f0be2b77a3d885> 199
mediaserverd <c731263114c33a07aef7bccdcf667271> 643
lockdownd <1c7f2b41744c35dc92f679e90a73e240> 268
syslogd <d81669e7bdb93f9b9012020beac826f4> 100
usbethernetshari <25130d2f9a0334e3ae28780250343144> 105
launchd <e2d41e07a0743a089eadbae765709c82> 84
**End**
can any one pls help how to track the log report.

This isn't an application crash, so much as application termination: iOS has a mechanism called Jetsam (or, officially, memory status) which "jettisons" (i.e. throws out) the largest process (in terms of memory) when physical memory is low. This is a necessary measure because iOS has no swap. In your log, which is generated by jetsam, you can see a list of all the processes which were active, and BJS - which has been thrown out. The format is :
Incident Identifier: Automatically generated GUID for Apple
CrashReporter Key: Hash, probably of GUID
Hardware Model: i-Device stepping (4,1 is 4th gen iPod in your case)
OS Version: Version of iOS
Kernel Version: Kernel version, as per uname -a
Date: ... figure this one out
Time since snapshot: How much time has passed - the snapshot may be "dated"
Free pages: How many free pages of RAM remain. Page = 4k
Wired pages: How many resident pages
Purgeable pages: How many pages MAY be freed, if all else fails
Largest process: The culprit
Processes
Name UUID Count resident pages
BJS <312d3dae46e433f9982c26738e40060b> 36928 (jettisoned) (active)
Table, as per column header, where (jettisoned) implies jetsam killed you. (active) implies you were the foreground app.
Hope this helps, (if it doesn't - comment or ask me directly)

Related

bootloader lock failure standard unlocking commands not working thinking its hash failure or sst key corrupted

I do not know why but when y friend gets inebriated she like to hook her phone up to a PC and play with it. she has a basic knowledge of ADB and fastboot commmand and i verified with her what was thrown. When she went to re-lock the bootloader it did not with thisI did. she downloaded Google minimal sdk tools to get the updated ADB and Fastboot then went all the way and got mfastboot from Motorola to insure parsing for flashing. All of these fastboot packages were also tested on Mac and Linux Ubuntu, on Windows 8.1 Pro N Update 1 and Windows 7 Professional N SP2 (all x64). Resulted in the same errors. She is super thorough and I only taught here how to manually erase and flash no scripts or tool kits.
fastboot oem lock
and it returned.
(bootloader) FAIL: Please run fastboot oem lock begin first!
(bootloader) sst lock failure!
FAILED (remote failure)
finished. total time: 0.014s
Then tried again, then again, and then yep again. At this this point she either read the log and followed it. personally though I think based on the point she starts playing with phones it more likely she started to panic because she needs the bootloader locked for work and started attempting to flash.
fastboot oem lock begin
and it returned.
M:\SHAMU\FACTORY IMAGE\shamu-lmy47z>fastboot oem lock begin
...
(bootloader) Ready to flash signed images
OKAY [ 0.121s]
finished. total time: 0.123s
FACTORY IMAGE\shamu-lmy47z>fastboot flash boot boot.img
target reported max download size of 536870912 bytes
sending 'boot' (7731 KB)...
OKAY [ 0.252s]
writing 'boot'...
(bootloader) Preflash validation failed
FAILED (remote failure)
finished. total time: 0.271s
Then the bootloader log stated
cmd: oem lock
hab check failed for boot
failed to validate boot image
upon flashing boot.img the Bootloader Logs lists "Mismatched partition size (boot)".
intresting sometimes it returns
fastboot oem lock begin
...
(bootloader) Ready to flash signed images
OKAY [ 0.121s]
finished. total time: 0.123s
fastboot flash boot boot.img
target reported max download size of 536870912 bytes
sending 'boot' (7731 KB)...
OKAY [ 0.252s]
writing 'boot'...
(bootloader) Preflash validation failed
FAILED (remote failure)
finished. total time: 0.271s
I logged the partitions to see if they are zeroed out indicating bad emmc but they are not.
cat /proc/partitions
cat /proc/partitions
major minor #blocks name
179 0 61079552 mmcblk0
179 1 114688 mmcblk0p1
179 2 16384 mmcblk0p2
179 3 384 mmcblk0p3
179 4 56 mmcblk0p4
179 5 16 mmcblk0p5
179 6 32 mmcblk0p6
179 7 1024 mmcblk0p7
179 8 256 mmcblk0p8
179 9 512 mmcblk0p9
179 10 500 mmcblk0p10
179 11 4156 mmcblk0p11
179 12 384 mmcblk0p12
179 13 1024 mmcblk0p13
179 14 256 mmcblk0p14
179 15 512 mmcblk0p15
179 16 500 mmcblk0p16
179 17 4 mmcblk0p17
179 18 512 mmcblk0p18
179 19 1024 mmcblk0p19
179 20 1024 mmcblk0p20
179 21 1024 mmcblk0p21
179 22 1024 mmcblk0p22
179 23 16384 mmcblk0p23
179 24 16384 mmcblk0p24
179 25 2048 mmcblk0p25
179 26 32768 mmcblk0p26
179 27 256 mmcblk0p27
179 28 32 mmcblk0p28
179 29 128 mmcblk0p29
179 30 8192 mmcblk0p30
179 31 1024 mmcblk0p31
259 0 2528 mmcblk0p32
259 1 1 mmcblk0p33
259 2 8 mmcblk0p34
259 3 16400 mmcblk0p35
259 4 9088 mmcblk0p36
259 5 16384 mmcblk0p37
259 6 262144 mmcblk0p38
259 7 65536 mmcblk0p39
259 8 1024 mmcblk0p40
259 9 2097152 mmcblk0p41
259 10 58351488 mmcblk0p42
179 32 4096 mmcblk0rpmb
254 0 58351488 dm-0
Ive asked for log or the total process to see the full warning, error, and failure message but she is super far on business. From what I do have and what literature i have started to crack. I am starting to believe from all my research and learnng about the android boot proccess. Maybe there is a missing or corrupted key in the SST table which is I beleieved called the bigtable to google. or a hash password failure when locking the bootloader security down or i could be way off please let me know. What I do not know how to investigate or disprove this issue to move on. Would I be able to get confirmation through a stack trace for missing or corrupted coding. So then it can be a puzzle thats solved. Honestly though this has become a puzzle that begs to be solved not an emergency thanks.
You should try "fastboot flashing lock" command instead.

iOS app crash due to Exception 0xdeadfeed !! whats the reason of 0xdeadfeed?

Incident Identifier: 59F8A919-279A-4C9E-9B58-FFFE9C01F9E9
CrashReporter Key: 73755578964009d66f989a2277500f68dc02d973
Hardware Model: iPod4,1
OS Version: iPhone OS 5.1.1 (9B206)
Kernel version: Darwin Kernel Version 11.0.0: Sun Apr 8 21:51:26 PDT 2012;
root:xnu-1878.11.10~1/RELEASE_ARM_S5L8930X
Date: 2013-02-12 11:47:12 +0500
Exception Code: 0xdeadfeed
Reason: Timeout waiting for service to spawn
Thermal Level: -1
Thermal Sensors: failed to load sensor values
Frontmost process PID: 7751
Frontmost process PID: 51
Jetsam Level: 28
Free Pages: 1642
Active Pages: 9820
Inactive Pages: 5087
Purgeable Pages: 4327
Wired Pages: 14299
Speculative Pages: 297
Throttled Pages: 32563
Busy Buffer Count: 0
Process 0 info:
resident memory bytes: 32129024
page faults: 694
page-ins: 0
copy-on-write faults: 0
user time in task: 136936.597192 seconds
system time in task: 0.000000 seconds
//Whats the reason of:-
Exception Code: 0xdeadfeed

Help me analyze dump file

Customers are reporting problems almost every day on about the same hours. This app is running on 2 nodes. It is Metastorm BPM platform and it's calling our code.
In some dumps I noticed very long running threads (~50 minutes) but not in all of them. Administrators are also telling me that just before users report problems memory usage goes up. Then everything slows down to the point they can't work and admins have to restart platforms on both nodes. My first thought was deadlocks (long running threads) but didn't manage to confirm that. !syncblk isn't returning anything. Then I looked at memory usage. I noticed a lot of dynamic assemblies so thought maybe assemblies leak. But it looks it's not that. I have received dump from day where everything was working fine and number of dynamic assemblies is similar. So maybe memory leak I thought. But also cannot confirm that. !dumpheap -stat shows memory usage grows but I haven't found anything interesting with !gcroot. But there is one thing I don't know what it is. Threadpool Completion Port. There's a lot of them. So maybe sth is waiting on sth? Here is data I can give You so far that will fit in this post. Could You suggest anything that could help diagnose this situation?
Users not reporting problems:
Node1 Node2
Size of dump: 638MB 646MB
DynamicAssemblies 259 265
GC Heaps: 37MB 35MB
Loader Heaps: 11MB 11MB
Node1:
Number of Timers: 12
CPU utilization 2%
Worker Thread: Total: 5 Running: 0 Idle: 5 MaxLimit: 2000 MinLimit: 200
Completion Port Thread:Total: 2 Free: 2 MaxFree: 16 CurrentLimit: 4 MaxLimit: 1000 MinLimit: 8
!dumpheap -stat (biggest)
0x793041d0 32,664 2,563,292 System.Object[]
0x79332b9c 23,072 3,485,624 System.Int32[]
0x79330a00 46,823 3,530,664 System.String
0x79333470 22,549 4,049,536 System.Byte[]
Node2:
Number of Timers: 12
CPU utilization 0%
Worker Thread: Total: 7 Running: 0 Idle: 7 MaxLimit: 2000 MinLimit: 200
Completion Port Thread:Total: 3 Free: 1 MaxFree: 16 CurrentLimit: 5 MaxLimit: 1000 MinLimit: 8
!dumpheap -stat
0x793041d0 30,678 2,537,272 System.Object[]
0x79332b9c 21,589 3,298,488 System.Int32[]
0x79333470 21,825 3,680,000 System.Byte[]
0x79330a00 46,938 5,446,576 System.String
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Users start to report problems:
Node1 Node2
Size of dump: 662MB 655MB
DynamicAssemblies 236 235
GC Heaps: 159MB 113MB
Loader Heaps: 10MB 10MB
Node1:
Work Request in Queue: 0
Number of Timers: 14
CPU utilization 20%
Worker Thread: Total: 7 Running: 0 Idle: 7 MaxLimit: 2000 MinLimit: 200
Completion Port Thread:Total: 48 Free: 1 MaxFree: 16 CurrentLimit: 49 MaxLimit: 1000 MinLimit: 8
!dumpheap -stat
0x7932a208 88,974 3,914,856 System.Threading.ReaderWriterLock
0x79333054 71,397 3,998,232 System.Collections.Hashtable
0x24f70350 319,053 5,104,848 Our.Class
0x79332b9c 53,190 6,821,588 System.Int32[]
0x79333470 52,693 6,883,120 System.Byte[]
0x79333150 72,900 11,081,328 System.Collections.Hashtable+bucket[]
0x793041d0 247,011 26,229,980 System.Object[]
0x79330a00 644,807 34,144,396 System.String
Node2:
Work Request in Queue: 1
Number of Timers: 17
CPU utilization 17%
Worker Thread: Total: 6 Running: 0 Idle: 6 MaxLimit: 2000 MinLimit: 200
Completion Port Thread:Total: 48 Free: 2 MaxFree: 16 CurrentLimit: 49 MaxLimit: 1000 MinLimit: 8
!dumpheap -stat
0x7932a208 76,425 3,362,700 System.Threading.ReaderWriterLock
0x79332b9c 42,417 5,695,492 System.Int32[]
0x79333150 41,172 6,451,368 System.Collections.Hashtable+bucket[]
0x79333470 44,052 6,792,004 System.Byte[]
0x793041d0 175,973 18,573,780 System.Object[]
0x79330a00 397,361 21,489,204 System.String
Edit:
I downloaded debugdiag and let it analyze my dumps. Here is part of output:
The following threads in process_name name_of_dump.dmp are making a COM call to thread 193 within the same process which in turn is waiting on data to be returned from another server via WinSock.
The call to WinSock originated from 0x0107b03b and is destined for port xxxx at IP address xxx.xxx.xxx.xxx
( 18 76 172 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 210 211 212 213 214 215 216 217 218 224 225 226 227 228 229 231 232 233 236 239 )
14,79% of threads blocked
And the recommendation is:
Several threads making calls to the same STA thread can cause a performance bottleneck due to serialization. Server side COM servers are recommended to be thread aware and follow MTA guidelines when multiple threads are sharing the same object instance.
I checked using windbg what thread 193 does. It is calling our code. Our code is calling some Metastorm engine code and it hangs on some remoting call. But !runaway shows it is hanging for 8 seconds. So not that long. So I checked what are those waiting threads. All except thread 18 are:
System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32, UInt32, System.Threading.NativeOverlapped*) I could understand one, but why so many of them. Is it specific to business process modeling engine we're using or is it something typical? I guess it's taking threads that could be used by other clients and that's why the slowdown reported by users. Are those threads Completion Port Threads I asked about before? Can I do anything more to diagnose or did I found our code to be the cause?
From the looks of the output most of the memory is not on the .net heaps (only 35 MB out of ~650) so if you are looking at the .net heaps I think you are looking in the wrong place. The memory is probably either in assemblies or in native memory if you are using some native component for file transfers or similar. You would want to use Debug Diag to monitor that.
It is hard to say if you are leaking dynamic assemblies without looking at the pattern of growth so I would suggest for that that you look at perfmon and #current assemblies to see if it keeps growing over time, if it does then you would have to investigate that further by looking at what the dynamic assemblies are with !dda

App Crashed Because of Low Memory

How can I setup my app to handle low memory situations? What are best practices?
Incident Identifier: 8BFDA96C-1019-4316-A278-CB86CC67172A
CrashReporter Key: 1657e021ecba3a19c5ed9f0cff62947a426a2bc2
Hardware Model: iPhone3,1
OS Version: iPhone OS 4.1 (8B117)
Date: 2010-09-28 00:00:12 -0700
Time since snapshot: 864 ms
Free pages: 1103
Wired pages: 20977
Purgeable pages: 0
Largest process: SpringBoard
Processes
Name UUID Count resident pages
securityd <3dcc6e23849cb3ee197720700284156d> 231
Reeder <dcb69039fa5b4426b3db9f9920054f3e> 9384
CNN <2da9830626fc69a5885dbb599e7e3910> 5803
Dropbox <2ed4326c3936d079605d309c05d2a7e3> 4340
Evernote <7519f2ea10cad2abbf13ad33177aa69e> 2610
TripIt <37c12bdfbecbf6af9933592e7fae98bd> 2111
MobileMusicPlaye <02ed082c795446617957bbae8974a2c8> 1619
dataaccessd <40c418e18e9bbd950ef7e3fb593645de> 681
Stocks <55e537a6739e58dc068e1436930213ba> 1169
Campfire <15b6957c18195a7fd06c6a3b3f6e0c76> 809
MobileTimer <98640aaee653fc9188652d6cdab13d67> 985 (jettisoned)
BTServer <ce7c062b4df09b835c77a6086b7ef0d8> 349
StockTwits <e8ad700990fe71025d9aeba2dd984cfa> 3482 (jettisoned)
MobileSafari <67a5ebc3754e0ce1e482760c7e56f9c5> 3641 (jettisoned)
mediaremoted <507d59f44f735d6e2855b23a6275557a> 184
Twitter <62edb7ce453c603ad1b8b3bdcbc4910b> 10862
Facebook <ae1fa9da7f8951ffbf693bbd0ed36aaf> 8217
calaccessd <90c4c48a02f0dbf0d1adaad27b8d5945> 526
GV Mobile Plus <179e36b7f3ae7f1f9b784308e1e20f78> 3612
Preferences <9123dcc666c97bb1d63a5921968c8b34> 1662
MobileSMS <bbe1ba067afb113c7be6a7f2e7542da8> 2095
mediaserverd <3ebe3a043c2dba96b70d8ede30bcb6ab> 2178
debugserver <2cd82985d402f2c9daf1b379c72dfd9b> 68
debugserver <2cd82985d402f2c9daf1b379c72dfd9b> 69
SCHelper <30ca097cbb6306cf66157da7fd4de07c> 113
MobileMail <215c71d2434ce352d04786b93cda5340> 5754
MobilePhone <b50b6283b8c52a51fb9e48ee5c909b80> 2859
MobileStorageMou <bd2184fe17b3c9ccbadd9120bd669c99> 101
imagent <4ef86a68405738280f19e5fbc0af56db> 288
lsd <4fb2cf7b5475b39b2c56d9588821eb45> 152
notifyd <ab40010781bef81228df18acf1acdbb2> 171
CommCenter <a8a6257faa2a5213f0a2f5c763f9acfe> 841
SpringBoard <983033e585706c1c6c99eed85cd8dbdb> 18145 (active)
accessoryd <b99ccd1b099c015edb93e8d1cbf03e36> 85
apsd <f031a0e787d8840097a4812fb1c89f5e> 235
awd_ice3 <b598d42ac4fdd950ac5c2c9a1835f70e> 170
configd <b2b3af98743381e759dd5b17115a0378> 449
fairplayd.N90 <3ae05b3bbcb034b0d4d4712e8fc19f99> 80
locationd <963c5d93cfaf1b1139045b1658ecfc26> 935
mDNSResponder <68dc311f118d171ede7b91f43c323b7d> 202
lockdownd <bfeda752b819f06f4828e112d3ca695c> 341
syslogd <60e8005a73e76d6ee81a8b45a9443a16> 84
launchd <b15ff1a8f2f37c3b0df0343899757b17> 104
**End**
handle -didReceiveMemoryWarning in your controllers and run your code through analyzer.
work with NSZombieEnabled, this link might be helpful
http://www.frogameleon.com/blog/last-night-an-iphone-zombie-nszombieenabled-saved-my-life
Try to run your application with Leaks (Run->Run with Performance Tools->Leaks), and see if you can find any leaks.
You should always release stuff you're not using anymore to reduce your memory-footprint.
See this question: iPhone Development - Memory limitation for iphone application

Memory problem on iPhone 3G/2G, sdk 3.0

I encountered a crash in my game, here's the crash log (it's a stress test):
PID RPRVT RSHRD RSIZE Command
1 340K 224K 436K launchd
14 124K 160K 216K update
15 568K 164K 620K syslogd
16 792K 612K 1.16M lockdownd
17 2.22M 664K 3.04M mediaserverd
18 296K 160K 440K mDNSResponder
20 540K 568K 1.25M iapd
21 248K 236K 456K fairplayd
22 640K 168K 1012K configd
23 6.42M 6.73M 9.14M SpringBoard
26 660K 212K 1.01M CommCenter
27 308K 164K 620K BTServer
28 19.1M 692K 19.9M TQServer
29 232K 188K 284K notifyd
1830 368K 596K 672K ptpd
1833 140K 164K 280K afcd
1835 148K 164K 288K afcd
1837 140K 160K 260K notification_pro
1848 3.83M 4.89M 4.76M MobileMusicPlaye
1855 19.7M 7.65M 23.6M MyGame ****
1856 616K 5.25M 2.27M MobilePhone
1857 292K 240K 1.25M ReportCrash
The RSIZE of MyGame is only 23.6MB, but the "Memory status: 11" indicate that the program recieves a shutdown command from OS due to memory problem.
So if the memory problem is not caused by my program, is there any way to ignore the shutdown command post from OS?
And from the iPhone develop guide, the OS will terminate a bg process which enconters a memory problem. But the SpringBoard is not terminated. So I think there should be a method to turn the memory management off in program.
You can't ignore the memory warning. The best you can do is try to free up some memory and hope your app doesn't get killed.
See this discussion for some insight.