Linux kgdb命令,linuxkgdb命令

來源:互聯網
上載者:User

Linux kgdb命令,linuxkgdb命令

一、簡介

kgdb是一種源碼級的Linux核心調試器。使用kgdb調試核心時,需要結合gdb一起使用,使用他們可以對核心進行單步調試,設定斷點,觀察變數、寄存器的值等與應用調試相關的功能。然而也有其限制條件,將在接下來kgdb調試器原理來講述,本文僅簡單介紹使用Kgbd的流程。

https://kgdb.wiki.kernel.org/index.php/Main_Page

 

二、安裝配置

1)開啟kgdb與kdb配置選項,重新編譯核心

https://www.kernel.org/pub/linux/kernel/people/jwessel/kdb/CompilingAKernel.html#CompileKGDB
http://blog.chinaunix.net/uid-23366077-id-4711134.html
http://www.cnblogs.com/274914765qq/p/4978999.html

2)啟動項設定,分別對server和client的開機檔案:/boot/grub/grub.conf,做如下修改

server:

kgdboc=ttyS1,115200

client:

kgdboc=ttyS1,115200 kgdbwait

3)串口設定

http://www.goupteam.com/tech-expand/1259.html
https://www.vmware.com/support/ws5/doc/ws_devices_serial_2vms.html

 

三、使用執行個體

1)核心調試

http://blog.chinaunix.net/uid-20672257-id-2936794.html

2)模組調試

http://blog.chinaunix.net/uid-20672257-id-2936794.html
http://www.linuxidc.com/Linux/2013-01/77969.htm

 

四、常見問題

1)kdb與kgdb模式相互切換

http://www.zeuux.com/blog/content/3736/

 

 

參考:http://blog.chinaunix.net/uid-25538637-id-261329.html

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.