06-15-2011
How to setup kernel debugger in RHEL 6.0
Hi, I face up a terrible problem that is for me setting up kdb or any other kernel debugger.
Little background:
I am writing linux kernel driver in C and ASM on host (real) machine that is Linux RHEL 6.0.
I run (I mean debug using printk's) that driver on virtual machine: QEMU, RHEL 6.0 (v 2.6.32-71.el6.x86_64).
I need to watch and modify registers, stack, and memory (because of ASM code).
I found some tutorials, but no one is good for me, because everytime I cannot do some steps.
I have never compiled kernel and generally speaking I am linux beginner
.
Could you help me with some steps?
___
for example this tutorial:
Inside the Linux kernel debugger
I successfully downloaded, unzpied two files (kdb-v4.4-2.6.33-common-1, kdb-v4.4-2.6.33-x86-1).
Unfortunately I even do not have folder /usr/src/linux ^_^.
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
hi ,
does anybody know about where to get kernel debugger for linux kernel version 2.6.11.
I found it in oss.sgi.com.But there i have to download through ftp,which is not enabled here.
So can anybody tell where can i get kdb(kernel debugger)through http.
thanks in advance
sriram (0 Replies)
Discussion started by: sriram.ec
0 Replies
2. UNIX for Advanced & Expert Users
hi,
I want to have a debugger for my kernel and
I am using kernel-2.6.11 n i am having patches
kdb-v4.4-2.6.11-common-1.bz2
kdb-v4.4-2.6.11-i386-1.bz2.
I applied both.
I did make menuconfig with options
CONFIG_KDB n CONFIG_FRAME_POINTER being set.
when i tried to compile kernel. I got an... (0 Replies)
Discussion started by: sriram.ec
0 Replies
3. UNIX for Dummies Questions & Answers
I am trying to Install RHEL AS 4 on x86 pc, through VNC and got the below error, Am not pretty sure as how to resolve this. Can some one guide me through the process, or what might be missing....
Have Installed RHEL, many a times but cudnt find this out...
Wud appreciate an early reply ......... (0 Replies)
Discussion started by: Crazy_murli
0 Replies
4. UNIX for Advanced & Expert Users
Hi all,
I need some help in compiling a new kernel. I am using RHEL 5 with kernel version 2.6.18.
I have downloaded a kernel from link http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.20.6.tar.bz2
1. cd /usr/src
2. wget -c http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.20.tar.bz2
3.... (1 Reply)
Discussion started by: vikas027
1 Replies
5. Red Hat
Hi, I need some help. I installed RHEL AS 4 u5 x86_64 (vendor requirement) on a Dell Blade 1855. I have a daughter board that will give it a HBA port. I can't install the daughter card until the Qlogic driver is loaded. I can't install the Qlogic driver sine the kernel src is not there.
So I... (0 Replies)
Discussion started by: BFLO
0 Replies
6. Red Hat
Hello,
Is there a way to force a kernel panic in RHEL 5.4 in such a way that
the machine reboots after the panic.
Thanks,
Kanna (1 Reply)
Discussion started by: kanna_geekworkz
1 Replies
7. IP Networking
Can someone here please help and walk me through what I need to do to setup
my network so that I can start an oracle listener ?
I am connected through a router (netgear) and everytime I start my machine the ip address changes because of DHCP (I think). There are so many parameters that I do... (5 Replies)
Discussion started by: jxh461
5 Replies
8. Programming
GNU insight debugger is not available now a days and it is required to debug/inspect
assembly code as written in the book Assembly Language Programming step by step in Linux so my question is; is there any alternative to insight that I can use instead of insight in which I can get the same... (5 Replies)
Discussion started by: vectrum
5 Replies
9. Red Hat
Hi all,
Im studying rhcsa as of now, so yum installation and dependencies are messing me to not workit out.
i have dual os, win 7 & rhel 6.
i have tried this installation of vsftpd package with rhel 6 dvd in VM rhel 6 in win 7 as well as host rhel 6.still the same issue.
below error... (6 Replies)
Discussion started by: redhatlbug
6 Replies
10. IP Networking
Could someone tell me how to setup VPN for RHEL5 so that i can connect remotely from another location. (1 Reply)
Discussion started by: kartheekm56
1 Replies
LEARN ABOUT CENTOS
textdump
TEXTDUMP(4) BSD Kernel Interfaces Manual TEXTDUMP(4)
NAME
textdump -- textdump kernel dumping facility
SYNOPSIS
options KDB
options DDB
DESCRIPTION
The textdump facility allows the capture of kernel debugging information to disk in a human-readable rather than the machine-readable form
normally used with kernel memory dumps and minidumps. This representation, while less complete in that it does not capture full kernel
state, can provide debugging information in a more compact, portable, and persistent form than a traditional dump. By combining textdump
with other ddb(4) facilities, such as scripting and output capture, detailed bug information can be captured in a fully automated manner.
FORMAT
textdump data is stored in a dump partition in the same style as a regular memory dump, and will be automatically extracted by savecore(8) if
present on boot.
textdump files are stored in the tar(5) format, and consist of one or more text files, each storing a particular type of debugging output.
The following parts may be present:
ddb.txt Captured ddb(4) output, if the capture facility has been used. May be disabled by clearing the debug.ddb.textdump.do_ddb
sysctl.
config.txt Kernel configuration, if has been compiled into the kernel. May be disabled by clearing the debug.ddb.textdump.do_config
sysctl.
msgbuf.txt Kernel message buffer, including recent console output if the capture facility has been used. May be disabled by clearing the
debug.ddb.textdump.do_msgbuf sysctl.
panic.txt Kernel panic string, if the kernel panicked before the dump was generated. May be disabled by clearing the
debug.ddb.textdump.do_panic sysctl.
version.txt Kernel version string. My be disabled by clearing the debug.ddb.textdump.do_version sysctl.
Kernel textdumps may be extracted using tar(1).
CONFIGURATION
The textdump facility is enabled as part of the kernel debugger using options KDB and options DDB. By default, kernel dumps generated on
panic or via explicit requests for a dump will be regular memory dumps; however, by using the textdump set command in ddb(4), or by setting
the debug.ddb.textdump.pending sysctl to 1 using sysctl(8), it is possible to request that the next dump be a textdump.
If at the ddb(4) command line, the commands textdump set, textdump status, and textdump unset may be used to set, query, and clear the
textdump pending flag.
As with regular kernel dumps, a dump partition must be automatically or manually configured using dumpon(8).
EXAMPLES
In the following example, the script kdb.enter.panic will run when the kernel debugger is entered as a result of a panic, enable output cap-
ture, dump several useful pieces of debugging information, and then invoke panic in order to force a kernel dump to be written out followed
by a reboot:
script kdb.enter.panic=textdump set; capture on; show allpcpu; bt;
ps; alltrace; show alllock; call doadump; reset
In the following example, the script kdb.enter.witness will run when the kernel debugger is entered as a result of a witness violation,
printing lock-related information for the user:
script kdb.enter.witness=show locks
These scripts may also be configured using the ddb(8) utility.
SEE ALSO
tar(1), ddb(4), tar(5), ddb(8), dumpon(8), savecore(8), sysctl(8)
HISTORY
The textdump facility first appeared in FreeBSD 7.1.
AUTHORS
The textdump facility was created by Robert N. M. Watson.
BSD
December 24, 2008 BSD