Can't attach using 2 Machine Debugging
Greeting, I've been having fits trying to get gdb to work in a 2 machine setup so I can interactively debug my KNE. I've read all the docs I can find (tn2063 and Hello Debugger [revved on 1Nov!]) but am still getting nowhere. I'm running "6.2 Darwin Kernel Version 6.2: Tue Nov 5 22:00:03 PST 2002; root:xnu/xnu-344.12.2.obj~1/RELEASE_PPC" on both a Tibook (dev) and a Pismo G3 (target). I've done the incantations to get the permanent arp entry and using file sharing copied the .sym file from kextload -s to the dev system and have set the boot-args to "debug=0xe". On the dev system I have: [Mikes-Tibook:~] cashwell% sudo arp -s 10.0.0.10 0:3:93:3:4b:92 [Mikes-Tibook:~] cashwell% arp -a ? (10.0.0.10) at 0:3:93:3:4b:92 permanent ? (224.0.0.251) at 1:0:5e:0:0:fb permanent ? (239.255.255.253) at 1:0:5e:7f:ff:fd permanent I then trigger the panic on the target. It spews text on the screen ending with the correct MAC and IP addresses and claims to be waiting for a remote debugger connection. Nothing else ever happens on the target's display. I then do the normal: [Mikes-Tibook:~] cashwell% gdb /mach_kernel ... (gdb) add-symbol-file com.company.kext.myshim.sym add symbol table from file "com. company.kext.myshim.sym" at (y or n) y Reading symbols from /Users/cashwell/com.company.kext.myshim.sym...done. (gdb) target remote-kdp (gdb) attach 10.0.0.10 and then get 10 repetitions of error messages: kdp_reply_wait: error from kdp_receive: receive timeout exceeded kdp_transaction (remote_connect): transation timed out kdp_transaction (remote_connect): re-sending transaction and kdp_transaction (remote_connect): host not responding; will retry unable to connect to host "10.0.0.10": receive timeout exceeded If I try it with a non-existent IP address it ends slightly differently: kdp_transmit_fd: sendto returns -1: Host is down (64) unable to connect to host "10.0.0.44": RR_IP_ERROR so it looks like the permanent route is having some effect. This is the first time I've needed to do 2 machine debugging for a very long time and I did just update to 10.2.2. Can anyone confirm that it still works? I saw a worrisome comment in an Apple doc for the meaning of the boot-arg flags. It says debug flag 0x10 is to "Make ddb (kdb) the default debugger (requires a custom kernel)." I don't have that flag set as the docs say to use 0xe. Yet the gdb command the docs say to use is "target remote-kdb". Which is right? One last datum, my target machine does have 2 ethernet interfaces active (one wired and one Airport). I need the latter so an app running on another platform can trigger the panic. But I'm using the wired interface for debugging (or trying to). Could having both enabled be messing things up even thought the panic spew lists the addresses of the wired interface? Wondering if it was the Pismo's Ethernet hardware I tried another TiBook as the target machine but it acted identically. Any ideas would be appreciated. Thanks, Mike _______________________________________________ darwin-kernel mailing list | darwin-kernel@lists.apple.com Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/darwin-kernel Do not post admin requests to the list. They will be ignored.
participants (1)
-
Michael Cashwell