View Single Post
  #2   (View Single Post)  
Old 23rd December 2013
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

"Hang" when using X can be difficult to diagnose. If there has been a kernel panic, you would have the same symptoms. The default is to enter the ddb(4) kernel debugger, and when running X this cannot be seen. If the keyboard is active in ddb -- and it may not be --, you can blindly type ddb commands such as ddb> boot crash to force a kernel core dump and reboot. Along with having a keyboard connection to ddb without being able to see ddb, you'll need to have sufficient default swap space to hold a kernel core dump, which means it should be larger than your physical RAM. You won't know if your boot crash command is working unless you can monitor disk I/O. Writing a kernel core dump to swap takes time.

You can disable ddb so that you can avoid blind typing, and automatically obtain a kernel dump. See crash(8) as well.

If the MacbookAir has a 9-pin serial port, with a null-modem cable you could set up another computer as a serial console. This has two advantages:
  1. If there is a kernel panic, you can actually see it.
  2. If there is a real hang, you can force the kernel to enter ddb. See ddb(4).
Reply With Quote